Share via


AppOpsManager.NoteProxyOp Method

Definition

Overloads

NoteProxyOp(String, String, Int32, String, String)

Make note of an application performing an operation on behalf of another application when handling an IPC.

NoteProxyOp(String, String)

This member is deprecated.

NoteProxyOp(String, String, Int32, String, String)

Make note of an application performing an operation on behalf of another application when handling an IPC.

[Android.Runtime.Register("noteProxyOp", "(Ljava/lang/String;Ljava/lang/String;ILjava/lang/String;Ljava/lang/String;)I", "GetNoteProxyOp_Ljava_lang_String_Ljava_lang_String_ILjava_lang_String_Ljava_lang_String_Handler", ApiSince=30)]
public virtual Android.App.AppOpsManagerMode NoteProxyOp (string op, string? proxiedPackageName, int proxiedUid, string? proxiedAttributionTag, string? message);
[<Android.Runtime.Register("noteProxyOp", "(Ljava/lang/String;Ljava/lang/String;ILjava/lang/String;Ljava/lang/String;)I", "GetNoteProxyOp_Ljava_lang_String_Ljava_lang_String_ILjava_lang_String_Ljava_lang_String_Handler", ApiSince=30)>]
abstract member NoteProxyOp : string * string * int * string * string -> Android.App.AppOpsManagerMode
override this.NoteProxyOp : string * string * int * string * string -> Android.App.AppOpsManagerMode

Parameters

op
String

The operation to note. One of the OPSTR_* constants.

proxiedPackageName
String

The name of the application calling into the proxy application.

proxiedUid
Int32

The uid of the proxied application

proxiedAttributionTag
String

The proxied Context#createAttributionContext attribution tag or null for default attribution

message
String

A message describing the reason the op was noted

Returns

Returns #MODE_ALLOWED if the operation is allowed, or #MODE_IGNORED if it is not allowed and should be silently ignored (without causing the app to crash).

Attributes

Remarks

Make note of an application performing an operation on behalf of another application when handling an IPC. This function will verify that the calling uid and proxied package name match, and if not, return #MODE_IGNORED. If this call succeeds, the last execution time of the operation for the proxied app and your app will be updated to the current time.

Java documentation for android.app.AppOpsManager.noteProxyOp(java.lang.String, java.lang.String, int, java.lang.String, java.lang.String).

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.

Applies to

NoteProxyOp(String, String)

This member is deprecated.

[Android.Runtime.Register("noteProxyOp", "(Ljava/lang/String;Ljava/lang/String;)I", "GetNoteProxyOp_Ljava_lang_String_Ljava_lang_String_Handler", ApiSince=23)]
public virtual Android.App.AppOpsManagerMode NoteProxyOp (string op, string proxiedPackageName);
[<Android.Runtime.Register("noteProxyOp", "(Ljava/lang/String;Ljava/lang/String;)I", "GetNoteProxyOp_Ljava_lang_String_Ljava_lang_String_Handler", ApiSince=23)>]
abstract member NoteProxyOp : string * string -> Android.App.AppOpsManagerMode
override this.NoteProxyOp : string * string -> Android.App.AppOpsManagerMode

Parameters

op
String
proxiedPackageName
String

Returns

Attributes

Remarks

This member is deprecated. Use #noteProxyOp(String, String, int, String, String) instead

Java documentation for android.app.AppOpsManager.noteProxyOp(java.lang.String, java.lang.String).

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.

Applies to