다음을 통해 공유


DevicePolicyManager.SetLogoutEnabled(ComponentName, Boolean) Method

Definition

Called by a device owner to specify whether logout is enabled for all secondary users.

[Android.Runtime.Register("setLogoutEnabled", "(Landroid/content/ComponentName;Z)V", "GetSetLogoutEnabled_Landroid_content_ComponentName_ZHandler", ApiSince=28)]
public virtual void SetLogoutEnabled (Android.Content.ComponentName admin, bool enabled);
[<Android.Runtime.Register("setLogoutEnabled", "(Landroid/content/ComponentName;Z)V", "GetSetLogoutEnabled_Landroid_content_ComponentName_ZHandler", ApiSince=28)>]
abstract member SetLogoutEnabled : Android.Content.ComponentName * bool -> unit
override this.SetLogoutEnabled : Android.Content.ComponentName * bool -> unit

Parameters

admin
ComponentName

Which DeviceAdminReceiver this request is associated with.

enabled
Boolean

whether logout should be enabled or not.

Attributes

Remarks

Called by a device owner to specify whether logout is enabled for all secondary users. The system may show a logout button that stops the user and switches back to the primary user.

Java documentation for android.app.admin.DevicePolicyManager.setLogoutEnabled(android.content.ComponentName, boolean).

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