mapRules top-level property

Implementation

final Map<TypeIdentification, ValidationRule> mapRules = {
  TypeIdentification.dni: ValidationRule(
    pattern: r'^\d{10}$',
    errorMessage:
        'Invalid identification: must be exactly 10 digits and contain only numbers.',
  ),
  TypeIdentification.ruc: ValidationRule(
    pattern: r'^\d{13}$',
    errorMessage:
        'Invalid identification: must be exactly 13 digits and contain only numbers.',
  ),
  TypeIdentification.rucPersonNatural: ValidationRule(
    pattern: r'^\d{13}$',
    errorMessage:
        'Invalid identification: must be exactly 13 digits and contain only numbers.',
  ),
  TypeIdentification.rucPublicSociety: ValidationRule(
    pattern: r'^\d{13}$',
    errorMessage:
        'Invalid identification: must be exactly 13 digits and contain only numbers.',
  ),
  TypeIdentification.rucSocietyPrivate: ValidationRule(
    pattern: r'^\d{13}$',
    errorMessage:
        'Invalid identification: must be exactly 13 digits and contain only numbers.',
  ),
};