copyWith method
MobileScannerState
copyWith({
- int? availableCameras,
- CameraFacing? cameraDirection,
- MobileScannerException? error,
- bool? isInitialized,
- bool? isRunning,
- Size? size,
- TorchState? torchState,
- double? zoomScale,
Create a copy of this state with the given parameters.
Implementation
MobileScannerState copyWith({
int? availableCameras,
CameraFacing? cameraDirection,
MobileScannerException? error,
bool? isInitialized,
bool? isRunning,
Size? size,
TorchState? torchState,
double? zoomScale,
}) {
return MobileScannerState(
availableCameras: availableCameras ?? this.availableCameras,
cameraDirection: cameraDirection ?? this.cameraDirection,
error: error,
isInitialized: isInitialized ?? this.isInitialized,
isRunning: isRunning ?? this.isRunning,
size: size ?? this.size,
torchState: torchState ?? this.torchState,
zoomScale: zoomScale ?? this.zoomScale,
);
}