Factory method, which parses the MRZ and returns appropriate record class. @param mrz MRZ to parse. @return record class.
(String mrz)
| 261 | * @return record class. |
| 262 | */ |
| 263 | public static MrzRecord parse(String mrz) { |
| 264 | final MrzRecord result = MrzFormat.get(mrz).newRecord(); |
| 265 | result.fromMrz(mrz); |
| 266 | return result; |
| 267 | } |
| 268 | |
| 269 | |
| 270 | private static final Map<String, String> EXPAND_CHARACTERS = new HashMap<String, String>(); |