AppOpsManager.IOnOpChangedListener.OnOpChanged2 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.
Similar to #onOpChanged(String, String, int)
but includes the device for which
the op mode has changed.
[Android.Runtime.Register("onOpChanged", "(Ljava/lang/String;Ljava/lang/String;ILjava/lang/String;)V", "GetOnOpChanged2_Ljava_lang_String_Ljava_lang_String_ILjava_lang_String_Handler:Android.App.AppOpsManager/IOnOpChangedListener, Mono.Android, Version=0.0.0.0, Culture=neutral, PublicKeyToken=null", ApiSince=35)]
public virtual void OnOpChanged2 (string op, string packageName, int userId, string persistentDeviceId);
[<Android.Runtime.Register("onOpChanged", "(Ljava/lang/String;Ljava/lang/String;ILjava/lang/String;)V", "GetOnOpChanged2_Ljava_lang_String_Ljava_lang_String_ILjava_lang_String_Handler:Android.App.AppOpsManager/IOnOpChangedListener, Mono.Android, Version=0.0.0.0, Culture=neutral, PublicKeyToken=null", ApiSince=35)>]
abstract member OnOpChanged2 : string * string * int * string -> unit
override this.OnOpChanged2 : string * string * int * string -> unit
Parameters
- op
- String
The Op that changed.
- packageName
- String
Package of the app whose Op changed.
- userId
- Int32
User id of the app whose Op changed.
- persistentDeviceId
- String
persistent device id whose Op changed.
- Attributes
Remarks
Similar to #onOpChanged(String, String, int)
but includes the device for which the op mode has changed.
Implement this method if callbacks are required on all devices. If not implemented explicitly, the default implementation will notify for op changes on the default device VirtualDeviceManager#PERSISTENT_DEVICE_ID_DEFAULT
only.
If implemented, #onOpChanged(String, String, int)
will not be called automatically.
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.