stop method
Stop the camera.
After calling this method, the camera can be restarted using start.
Does nothing if the camera is already stopped.
Implementation
Future<void> stop() async {
if (_stop()) {
// Stopping releases the platform camera session,
// so that another controller can start it.
// Pausing does not, as a paused session is resumed by its own owner.
if (identical(_platformSessionOwner, this)) {
_platformSessionOwner = null;
}
await MobileScannerPlatform.instance.stop();
}
}