DevicePolicyManager.SetCrossProfileCallerIdDisabled 方法

定义

由托管配置文件的配置文件所有者调用,用于设置传入呼叫的来自托管配置文件的调用方-Id 信息是否将显示在父配置文件中。

[Android.Runtime.Register("setCrossProfileCallerIdDisabled", "(Landroid/content/ComponentName;Z)V", "GetSetCrossProfileCallerIdDisabled_Landroid_content_ComponentName_ZHandler")]
public virtual void SetCrossProfileCallerIdDisabled (Android.Content.ComponentName admin, bool disabled);
[<Android.Runtime.Register("setCrossProfileCallerIdDisabled", "(Landroid/content/ComponentName;Z)V", "GetSetCrossProfileCallerIdDisabled_Landroid_content_ComponentName_ZHandler")>]
abstract member SetCrossProfileCallerIdDisabled : Android.Content.ComponentName * bool -> unit
override this.SetCrossProfileCallerIdDisabled : Android.Content.ComponentName * bool -> unit

参数

admin
ComponentName

DeviceAdminReceiver此请求与此请求相关联。

disabled
Boolean

如果未显示托管配置文件中真正的调用方 ID 信息。

属性

注解

由托管配置文件的配置文件所有者调用,用于设置传入呼叫的来自托管配置文件的调用方-Id 信息是否将显示在父配置文件中。

呼叫设备管理员必须是配置文件所有者。 如果不是,将引发安全异常。

从此android.os.Build.VERSION_CODES#UPSIDE_DOWN_CAKE开始,调用此函数类似于在 false 时disabled使用PackagePolicy#PACKAGE_POLICY_BLOCKLIST策略类型进行调用#setManagedProfileCallerIdAccessPolicy(PackagePolicy);如果为 true,则PackagePolicy#PACKAGE_POLICY_ALLOWLIST调用此函数类似于disabled策略类型。

此成员已弃用。 从 android.os.Build.VERSION_CODES#UPSIDE_DOWN_CAKE开始,请改用#setManagedProfileCallerIdAccessPolicy(PackagePolicy)

适用于 . 的 android.app.admin.DevicePolicyManager.setCrossProfileCallerIdDisabled(android.content.ComponentName, boolean)Java 文档

本页的某些部分是根据 Android 开放源代码项目创建和共享的工作进行的修改,并根据 Creative Commons 2.5 属性许可证中所述的术语使用。

适用于