parseMRVB

fun parseMRVB(input: String, referenceTime: Instant = Clock.System.now()): ParseResult

Parses an MRZ string as an MRV-B (Type-B visa) MRZ: 2 lines of 36 characters.

Splits input on \n, \r\n, or \r, drops leading empty lines, and trims trailing whitespace. Lowercase letters count as outside the MRZ alphabet. An MRV-B has no composite check digit.

Return

ParseResult.Success or ParseResult.PartialSuccess with the document, or ParseResult.Failure with MrzInvalidLength if the line count or a line length does not fit, or MrzCharacterSetViolation for the first character outside A-Z, 0-9, and <.

Parameters

input

the MRZ text.

referenceTime

the instant that picks the century of two-digit years and sets the date warnings. Defaults to the current time.


fun parseMRVB(@ObjCName(name = "lines") input: List<String>, referenceTime: Instant = Clock.System.now()): ParseResult

Parses pre-split lines as an MRV-B (Type-B visa) MRZ: 2 lines of 36 characters.

Uses input as given. Reports and returns the same as parseMRVB with a string.

Return

the parse result, as for parseMRVB with a string.

Parameters

input

the MRZ lines, one element per line.

referenceTime

the instant that picks the century of two-digit years and sets the date warnings. Defaults to the current time.