ResultParser class abstract
Abstract interface for all result parsers (MRZ, VIN, Aadhaar, PAN, etc.).
Standardizes the parse input/output contract across all document-specific parsers in the framework, enabling:
- Consistent error handling
- Pluggable parser registration
- Unified confidence scoring
- Structured validation results
Constructors
Properties
-
additionalModes
→ Set<
ScanMode> -
Additional scan modes this parser can also handle as fallback.
no setter
- hashCode → int
-
The hash code for this object.
no setterinherited
- mode → ScanMode
-
The primary scan mode this parser handles.
no setter
- name → String
-
Human-readable name of this parser (e.g., 'MRZ Passport Parser').
no setter
- runtimeType → Type
-
A representation of the runtime type of the object.
no setterinherited
Methods
-
canParse(
String rawText) → bool - Whether this parser can attempt to parse the given raw text.
-
noSuchMethod(
Invocation invocation) → dynamic -
Invoked when a nonexistent method or property is accessed.
inherited
-
parse(
String rawText) → ScanResult - Parses raw text or payload into a structured ScanResult.
-
toString(
) → String -
A string representation of this object.
inherited
-
validate(
ScanResult result) → ParserValidation - Validates an already-parsed result and returns detailed validation info.
Operators
-
operator ==(
Object other) → bool -
The equality operator.
inherited