DocumentPickerCoordinatorDelegate

public protocol DocumentPickerCoordinatorDelegate : AnyObject

The CameraViewControllerDelegate protocol defines methods that allow you to handle picked documents from both Gallery and Files Explorer.

Note

Component API only.
  • Called when a user picks one or several files from either the gallery or the files explorer. The completion might provide errors that must be handled here before dismissing the pickers. It only applies to the GalleryCoordinator since on one side it is not possible to handle the dismissal of UIDocumentPickerViewController and on the other side the Drag&Drop is not done in a separate view.

    Declaration

    Swift

    func documentPicker(_ coordinator: DocumentPickerCoordinator, didPick documents: [GiniVisionDocument])

    Parameters

    coordinator

    DocumentPickerCoordinator where the documents were imported.

    documents

    One or several documents imported.

    from

    Picker used (either gallery, files explorer or drag&drop).

    validationHandler

    DocumentValidationHandler block used to check if there is an issue with the captured documents. The handler has an inner completion block that is executed once the picker has been dismissed when there are no errors.