Class SessionParameters


  • public class SessionParameters
    extends java.lang.Object
    Parameters required by session activities
    Since:
    2.0.0
    • Constructor Detail

      • SessionParameters

        public SessionParameters​(@NonNull
                                 VerID verID,
                                 @NonNull
                                 VerIDSessionSettings sessionSettings,
                                 @NonNull
                                 CameraLocation cameraLocation,
                                 @NonNull
                                 java.util.function.Function<android.content.Context,​V> sessionViewFactory,
                                 @NonNull
                                 IStringTranslator stringTranslator,
                                 @NonNull
                                 SessionFunctions sessionFunctions)
        Constructor
        Type Parameters:
        V - Session view type
        Parameters:
        verID - Instance of VerID to use for face detetion, recognition and user management
        sessionSettings - Session settings
        cameraLocation - Camera location
        sessionViewFactory - Session view factory
        stringTranslator - String translator
        sessionFunctions - Session functions
        Since:
        2.0.0
    • Method Detail

      • getVerID

        public VerID getVerID()
      • getSessionViewFactory

        public <V extends android.view.View & ISessionView> java.util.function.Function<android.content.Context,​V> getSessionViewFactory()
      • setSessionFailureDialogFactory

        public void setSessionFailureDialogFactory​(SessionFailureDialogFactory sessionFailureDialogFactory)
      • setFaceDetectionResultObserver

        public void setFaceDetectionResultObserver​(androidx.lifecycle.Observer<FaceDetectionResult> faceDetectionResultObserver)
      • setFaceCaptureObserver

        public void setFaceCaptureObserver​(androidx.lifecycle.Observer<FaceCapture> faceCaptureObserver)
      • setSessionResultObserver

        public void setSessionResultObserver​(androidx.lifecycle.Observer<VerIDSessionResult> sessionResultObserver)
      • getFaceDetectionResultObserver

        public java.util.Optional<androidx.lifecycle.Observer<FaceDetectionResult>> getFaceDetectionResultObserver()
      • getFaceCaptureObserver

        public java.util.Optional<androidx.lifecycle.Observer<FaceCapture>> getFaceCaptureObserver()
      • getSessionResultObserver

        public java.util.Optional<androidx.lifecycle.Observer<VerIDSessionResult>> getSessionResultObserver()
      • getImageIteratorFactory

        public java.util.function.Function<android.content.Context,​IImageIterator> getImageIteratorFactory()
      • setImageIteratorFactory

        public void setImageIteratorFactory​(@NonNull
                                            java.util.function.Function<android.content.Context,​IImageIterator> imageIteratorFactory)
      • getResultIntentSupplier

        public java.util.function.BiFunction<VerIDSessionResult,​android.app.Activity,​android.content.Intent> getResultIntentSupplier()
      • getTipsIntentSupplier

        public java.util.function.Function<android.app.Activity,​android.content.Intent> getTipsIntentSupplier()
      • setResultIntentSupplier

        public void setResultIntentSupplier​(java.util.function.BiFunction<VerIDSessionResult,​android.app.Activity,​android.content.Intent> resultIntentSupplier)
      • setTipsIntentSupplier

        public void setTipsIntentSupplier​(java.util.function.Function<android.app.Activity,​android.content.Intent> tipsIntentSupplier)
      • getOnSessionFinishedRunnable

        public java.util.Optional<java.lang.Runnable> getOnSessionFinishedRunnable()
      • setOnSessionFinishedRunnable

        public void setOnSessionFinishedRunnable​(java.lang.Runnable onSessionFinishedRunnable)
      • getOnSessionCancelledRunnable

        public java.util.Optional<java.lang.Runnable> getOnSessionCancelledRunnable()
      • setOnSessionCancelledRunnable

        public void setOnSessionCancelledRunnable​(java.lang.Runnable onSessionCancelledRunnable)
      • getSessionResultDisplayIndicator

        public java.util.function.Function<VerIDSessionResult,​java.lang.Boolean> getSessionResultDisplayIndicator()
      • setSessionResultDisplayIndicator

        public void setSessionResultDisplayIndicator​(java.util.function.Function<VerIDSessionResult,​java.lang.Boolean> sessionResultDisplayIndicator)
      • shouldRetryOnFailure

        public java.util.Optional<java.util.function.Function<VerIDSessionException,​java.lang.Boolean>> shouldRetryOnFailure()
      • shouldRetryOnFailure

        public void shouldRetryOnFailure​(java.util.function.Function<VerIDSessionException,​java.lang.Boolean> shouldRetryOnFailure)
      • getTextSpeaker

        public java.util.Optional<ITextSpeaker> getTextSpeaker()
      • setTextSpeaker

        public void setTextSpeaker​(ITextSpeaker textSpeaker)
      • getMinImageArea

        public int getMinImageArea()
      • setMinImageArea

        public void setMinImageArea​(int minImageArea)