LivenessCheckController class
Controller for managing liveness check camera operations.
This controller allows external control over camera initialization, disposal, and state management for the liveness check screen.
Example:
final controller = LivenessCheckController();
LivenessCheckScreen(
controller: controller,
config: LivenessCheckConfig(...),
)
// Later, manually control camera
controller.initializeCamera();
controller.disposeCamera();
- Inheritance
-
- Object
- ChangeNotifier
- LivenessCheckController
Constructors
Properties
- hashCode → int
-
The hash code for this object.
no setterinherited
- hasListeners → bool
-
Whether any listeners are currently registered.
no setterinherited
- isInitialized → bool
-
Gets the current camera initialization status.
no setter
- isPaused → bool
-
Gets the current pause status.
no setter
- runtimeType → Type
-
A representation of the runtime type of the object.
no setterinherited
Methods
-
addListener(
VoidCallback listener) → void -
Register a closure to be called when the object changes.
inherited
-
dispose(
) → void -
Discards any resources used by the object. After this is called, the
object is not in a usable state and should be discarded (calls to
addListener will throw after the object is disposed).
override
-
disposeCamera(
) → Future< void> - Disposes the camera and releases all resources.
-
initializeCamera(
) → Future< void> - Initializes the camera for liveness detection.
-
noSuchMethod(
Invocation invocation) → dynamic -
Invoked when a nonexistent method or property is accessed.
inherited
-
notifyListeners(
) → void -
Call all the registered listeners.
inherited
-
pauseDetection(
) → Future< void> - Pauses camera preview and face detection.
-
registerDisposeCallback(
VoidCallback callback) → void - Internal method to register camera disposal callback. Called by LivenessCheckScreen only.
-
registerInitializeCallback(
VoidCallback callback) → void - Internal method to register camera initialization callback. Called by LivenessCheckScreen only.
-
registerPauseCallback(
Future< void> callback()) → void - Internal method to register pause detection callback. Called by LivenessCheckScreen only.
-
registerResetCallback(
VoidCallback callback) → void - Internal method to register state reset callback. Called by LivenessCheckScreen only.
-
registerResumeCallback(
Future< void> callback()) → void - Internal method to register resume detection callback. Called by LivenessCheckScreen only.
-
removeListener(
VoidCallback listener) → void -
Remove a previously registered closure from the list of closures that are
notified when the object changes.
inherited
-
resetState(
) → void - Resets the liveness check state.
-
resumeDetection(
) → Future< void> - Resumes camera preview and face detection.
-
setInitialized(
bool value) → void - Internal method to set initialization status. Called by LivenessCheckScreen only.
-
setPaused(
bool value) → void - Internal method to set pause status. Called by LivenessCheckScreen only.
-
toString(
) → String -
A string representation of this object.
inherited
Operators
-
operator ==(
Object other) → bool -
The equality operator.
inherited