Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit c24765d5 authored by Desh's avatar Desh Committed by Oluwarotimi Adesina
Browse files

Improve AppFunction policy documentation

Flag: android.app.appfunctions.flags.enable_app_function_manager
Bug: 354956319
Test: N/A
Change-Id: I72257072881c6fc69f4f998a2891fc61e023d0fd
parent 6ff074b1
Loading
Loading
Loading
Loading
+12 −6
Original line number Diff line number Diff line
@@ -4354,20 +4354,24 @@ public class DevicePolicyManager {
    }
    /**
     * Indicates that app functions are not controlled by policy.
     * Indicates that {@link android.app.appfunctions.AppFunctionManager} is not controlled by
     * policy.
     *
     * <p>If no admin set this policy, it means appfunctions are enabled.
     */
    @FlaggedApi(android.app.appfunctions.flags.Flags.FLAG_ENABLE_APP_FUNCTION_MANAGER)
    public static final int APP_FUNCTIONS_NOT_CONTROLLED_BY_POLICY = 0;
    /** Indicates that app functions are controlled and disabled by a policy. */
    /** Indicates that {@link android.app.appfunctions.AppFunctionManager} is controlled and
     * disabled by policy, i.e. no apps in the current user are allowed to expose app functions.
     */
    @FlaggedApi(android.app.appfunctions.flags.Flags.FLAG_ENABLE_APP_FUNCTION_MANAGER)
    public static final int APP_FUNCTIONS_DISABLED = 1;
    /**
     * Indicates that app functions are controlled and disabled by a policy for cross profile
     * interactions only.
     * Indicates that {@link android.app.appfunctions.AppFunctionManager} is controlled and
     * disabled by a policy for cross profile interactions only, i.e. app functions exposed by apps
     * in the current user can only be invoked within the same user.
     *
     * <p>This is different from {@link #APP_FUNCTIONS_DISABLED} in that it only disables cross
     * profile interactions (even if the caller has permissions required to interact across users).
@@ -4388,7 +4392,9 @@ public class DevicePolicyManager {
    public @interface AppFunctionsPolicy {}
    /**
     * Sets the app functions policy which controls app functions operations on the device.
     * Sets the {@link android.app.appfunctions.AppFunctionManager} policy which controls app
     * functions operations on the device. An app function is a piece of functionality that apps
     * expose to the system for cross-app orchestration.
     *
     * <p>This function can only be called by a device owner, a profile owner or holders of the
     * permission {@link android.Manifest.permission#MANAGE_DEVICE_POLICY_APP_FUNCTIONS}.
@@ -4414,7 +4420,7 @@ public class DevicePolicyManager {
    }
    /**
     * Returns the current app functions policy.
     * Returns the current {@link android.app.appfunctions.AppFunctionManager} policy.
     *
     * <p>The returned policy will be the current resolved policy rather than the policy set by the
     * calling admin.