Sdílet prostřednictvím


JobScheduler.Cancel(Int32) Method

Definition

Cancel the specified job.

[Android.Runtime.Register("cancel", "(I)V", "GetCancel_IHandler")]
public abstract void Cancel (int jobId);
[<Android.Runtime.Register("cancel", "(I)V", "GetCancel_IHandler")>]
abstract member Cancel : int -> unit

Parameters

jobId
Int32

unique identifier for the job to be canceled, as supplied to JobInfo.Builder#Builder(int, android.content.ComponentName) JobInfo.Builder(int, android.content.ComponentName).

Attributes

Remarks

Cancel the specified job. If the job is currently executing, it is stopped immediately and the return value from its JobService#onStopJob(JobParameters) method is ignored.

Java documentation for android.app.job.JobScheduler.cancel(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