CameraManager.AvailabilityCallback.OnCameraRemoved(String) Method
Definition
Important
Some information relates to prerelease product that may be substantially modified before it’s released. Microsoft makes no warranties, express or implied, with respect to the information provided here.
A camera device has been physically removed or is no longer available to the system.
[Android.Runtime.Register("onCameraRemoved", "(Ljava/lang/String;)V", "GetOnCameraRemoved_Ljava_lang_String_Handler", ApiSince=37)]
public virtual void OnCameraRemoved(string cameraId);
[<Android.Runtime.Register("onCameraRemoved", "(Ljava/lang/String;)V", "GetOnCameraRemoved_Ljava_lang_String_Handler", ApiSince=37)>]
abstract member OnCameraRemoved : string -> unit
override this.OnCameraRemoved : string -> unit
Parameters
- cameraId
- String
The unique identifier of the camera that has been removed.
- Attributes
Remarks
A camera device has been physically removed or is no longer available to the system.
This callback is invoked when a previously available camera, such as a removable external camera, is disconnected. The camera ID will no longer be included in the list returned by CameraManager.getCameraIdList() and any attempt to open it will result in an IllegalArgumentException.
If an application has an active CameraDevice instance for the removed camera that the client did not close, then the application will receive a disconnection error.
When a camera is removed, onCameraUnavailable(String) will be invoked for the given cameraId before this callback is triggered.
Android reference for android.hardware.camera2.CameraManager.AvailabilityCallback.onCameraRemoved.
Portions of this page are modifications based on work created and shared by the Android Open Source Project and used according to terms described in the Creative Commons 2.5 Attribution License.