TravelDocument

public struct TravelDocument

A structure representing a Travel Document, which includes information parsed from the Machine Readable Zone (MRZ).

See also

MRZ and TDType
  • The type of the travel document (TD).

    Declaration

    Swift

    public private(set) var type: TDType { get }
  • mrz

    The Machine Readable Zone (MRZ) data parsed from the document.

    Declaration

    Swift

    public private(set) var mrz: MRZ { get }
  • Initialize a TravelDocument instance with the provided MRZ data.

    Throws

    An error if the travel document type is not recognized.

    Declaration

    Swift

    internal init(data: [UInt8]) throws

    Parameters

    data

    The MRZ data in the form of an array of bytes.