JobInfo.Builder.SetMinimumLatency(Int64) Method
Definition
Important
Some information relates to prerelease product that may be substantially modified before it’s released. Microsoft makes no warranties, express or implied, with respect to the information provided here.
Specify that this job should be delayed by the provided amount of time.
[Android.Runtime.Register("setMinimumLatency", "(J)Landroid/app/job/JobInfo$Builder;", "")]
public Android.App.Job.JobInfo.Builder? SetMinimumLatency(long minLatencyMillis);
[<Android.Runtime.Register("setMinimumLatency", "(J)Landroid/app/job/JobInfo$Builder;", "")>]
member this.SetMinimumLatency : int64 -> Android.App.Job.JobInfo.Builder
Parameters
- minLatencyMillis
- Int64
Milliseconds before which this job will not be considered for execution.
Returns
This builder instance.
- Attributes
Remarks
Specify that this job should be delayed by the provided amount of time. The job may not run the instant the delay has elapsed. JobScheduler will start the job at an indeterminate time after the delay has elapsed.
Because it doesn't make sense setting this property on a periodic job, doing so will throw an IllegalArgumentException when build() is called. Negative latencies also don't make sense for a job and are indicative of an error, so starting in Android version Build.VERSION_CODES.VANILLA_ICE_CREAM, setting a negative latency will result in build() throwing an IllegalArgumentException.
Android reference for android.app.job.JobInfo.Builder.setMinimumLatency.
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.