getModel method

DocumentModel getModel()

Gets the AI model used to detect the MRZ. Hint: Default value is MrzDetector2A.

return AI model used to detect the MRZ. throws DocumentException An error has occurred during Document Library execution.

Implementation

DocumentModel getModel() {
  Pointer<Int32> pModel = calloc();
  try {
    var err = documentSDK.id3DocumentMrzReader_GetModel(_pHandle.value, pModel);
    if (err != DocumentError.success.value) {
      throw DocumentException(err);
    }
    final vModel = DocumentModelX.fromValue(pModel.value);
    return vModel;
  } finally {
    calloc.free(pModel);
  }
}