Share via


SystemUpdatePolicy.CreateWindowedInstallPolicy(Int32, Int32) Method

Definition

Create a policy object and set it to: new system update will only be installed automatically when the system clock is inside a daily maintenance window.

[Android.Runtime.Register("createWindowedInstallPolicy", "(II)Landroid/app/admin/SystemUpdatePolicy;", "", ApiSince=23)]
public static Android.App.Admin.SystemUpdatePolicy? CreateWindowedInstallPolicy (int startTime, int endTime);
[<Android.Runtime.Register("createWindowedInstallPolicy", "(II)Landroid/app/admin/SystemUpdatePolicy;", "", ApiSince=23)>]
static member CreateWindowedInstallPolicy : int * int -> Android.App.Admin.SystemUpdatePolicy

Parameters

startTime
Int32

the start of the maintenance window, measured as the number of minutes from midnight in the device's local time. Must be in the range of [0, 1440).

endTime
Int32

the end of the maintenance window, measured as the number of minutes from midnight in the device's local time. Must be in the range of [0, 1440).

Returns

The configured policy.

Attributes

Remarks

Create a policy object and set it to: new system update will only be installed automatically when the system clock is inside a daily maintenance window. If the start and end times are the same, the window is considered to include the whole 24 hours. That is, updates can install at any time. If start time is later than end time, the window is considered spanning midnight (i.e. the end time denotes a time on the next day). The maintenance window will last for 30 days for any given update, after which the window will no longer be effective and the pending update will be made available for manual installation as if no system update policy were set on the device. See #TYPE_INSTALL_WINDOWED for the details of this policy's behavior.

Java documentation for android.app.admin.SystemUpdatePolicy.createWindowedInstallPolicy(int, int).

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