MobileScannerState class
This class represents the current state of a MobileScannerController.
Constructors
- MobileScannerState({required int? availableCameras, required CameraFacing cameraDirection, required CameraLensType cameraLensType, required bool isInitialized, required bool isStarting, required bool isRunning, required Size size, required TorchState torchState, required double zoomScale, required DeviceOrientation deviceOrientation, MobileScannerException? error})
-
Create a new MobileScannerState instance.
const
- MobileScannerState.uninitialized()
-
Create a new MobileScannerState instance that is uninitialized.
const
Properties
- availableCameras → int?
-
The number of available cameras.
final
- cameraDirection → CameraFacing
-
The facing direction of the camera.
final
- cameraLensType → CameraLensType
-
The lens type of the camera.
final
- deviceOrientation → DeviceOrientation
-
The current device UI orientation.
final
- error → MobileScannerException?
-
The error that occurred while setting up or using the camera.
final
- hasCameraPermission → bool
-
Whether permission to access the camera was granted.
no setter
- hashCode → int
-
The hash code for this object.
no setterinherited
- isInitialized → bool
-
Whether the mobile scanner has initialized successfully.
final
- isRunning → bool
-
Whether the mobile scanner is currently running.
final
- isStarting → bool
-
Whether the mobile scanner is currently in the process of starting.
final
- runtimeType → Type
-
A representation of the runtime type of the object.
no setterinherited
- size → Size
-
The size of the camera output.
final
- torchState → TorchState
-
The current state of the flashlight of the camera.
final
- zoomScale → double
-
The current zoom scale of the camera.
final
Methods
-
copyWith(
{int? availableCameras, CameraFacing? cameraDirection, CameraLensType? cameraLensType, MobileScannerException? error, bool? isInitialized, bool? isStarting, bool? isRunning, Size? size, TorchState? torchState, DeviceOrientation? deviceOrientation, double? zoomScale}) → MobileScannerState - Create a copy of this state with the given parameters.
-
noSuchMethod(
Invocation invocation) → dynamic -
Invoked when a nonexistent method or property is accessed.
inherited
-
toString(
) → String -
A string representation of this object.
inherited
Operators
-
operator ==(
Object other) → bool -
The equality operator.
inherited