MRZ constructor

MRZ(
  1. GenericDocument document
)

Implementation

MRZ(GenericDocument document) : super(document) {
  /// Unknown
  unknown = document
      .fieldByTypeName("Unknown")
      ?.let((field) => TextFieldWrapper(field));

  /// Document number
  documentNumber = document
      .fieldByTypeName("DocumentNumber")
      ?.let((field) => TextFieldWrapper(field));

  /// Issuing authority
  issuingAuthority = document
      .fieldByTypeName("IssuingAuthority")
      ?.let((field) => TextFieldWrapper(field));

  /// Office of issuance
  officeOfIssuance = document
      .fieldByTypeName("OfficeOfIssuance")
      ?.let((field) => ValidatedTextFieldWrapper(field));

  /// Date of issuance
  dateOfIssuance = document
      .fieldByTypeName("DateOfIssuance")
      ?.let((field) => ValidatedTextFieldWrapper(field));

  /// Given names
  givenNames = document
      .fieldByTypeName("GivenNames")!
      .let((field) => TextFieldWrapper(field));

  /// Surname
  surname = document
      .fieldByTypeName("Surname")!
      .let((field) => TextFieldWrapper(field));

  /// Nationality
  nationality = document
      .fieldByTypeName("Nationality")!
      .let((field) => TextFieldWrapper(field));

  /// Birth date
  birthDate = document
      .fieldByTypeName("BirthDate")!
      .let((field) => TextFieldWrapper(field));

  /// Gender
  gender = document
      .fieldByTypeName("Gender")
      ?.let((field) => TextFieldWrapper(field));

  /// Expiry date
  expiryDate = document
      .fieldByTypeName("ExpiryDate")
      ?.let((field) => ValidatedTextFieldWrapper(field));

  /// Personal number
  personalNumber = document
      .fieldByTypeName("PersonalNumber")
      ?.let((field) => ValidatedTextFieldWrapper(field));

  /// Travel document type
  travelDocType = document
      .fieldByTypeName("TravelDocType")
      ?.let((field) => TextFieldWrapper(field));

  /// Travel document type variant
  travelDocTypeVariant = document
      .fieldByTypeName("TravelDocTypeVariant")
      ?.let((field) => TextFieldWrapper(field));

  /// Optional 1
  optional1 = document
      .fieldByTypeName("Optional1")
      ?.let((field) => ValidatedTextFieldWrapper(field));

  /// Optional 2
  optional2 = document
      .fieldByTypeName("Optional2")
      ?.let((field) => ValidatedTextFieldWrapper(field));

  /// Document type code
  documentTypeCode = document
      .fieldByTypeName("DocumentTypeCode")
      ?.let((field) => TextFieldWrapper(field));

  /// PIN code
  pinCode = document
      .fieldByTypeName("PINCode")
      ?.let((field) => TextFieldWrapper(field));

  /// Language code
  languageCode = document
      .fieldByTypeName("LanguageCode")
      ?.let((field) => TextFieldWrapper(field));

  /// Version number
  versionNumber = document
      .fieldByTypeName("VersionNumber")
      ?.let((field) => TextFieldWrapper(field));

  /// Check digit document number
  checkDigitDocumentNumber = document
      .fieldByTypeName("CheckDigitDocumentNumber")
      ?.let((field) => ValidatedTextFieldWrapper(field));

  /// Check digit birth date
  checkDigitBirthDate = document
      .fieldByTypeName("CheckDigitBirthDate")
      ?.let((field) => ValidatedTextFieldWrapper(field));

  /// Check digit expiry date
  checkDigitExpiryDate = document
      .fieldByTypeName("CheckDigitExpiryDate")
      ?.let((field) => ValidatedTextFieldWrapper(field));

  /// Check digit personal number
  checkDigitPersonalNumber = document
      .fieldByTypeName("CheckDigitPersonalNumber")
      ?.let((field) => ValidatedTextFieldWrapper(field));

  /// Check  digit general
  checkDigitGeneral = document
      .fieldByTypeName("CheckDigitGeneral")
      ?.let((field) => ValidatedTextFieldWrapper(field));
}