@Retention(value=SOURCE)
public @interface CancelReason
Job.onCancel(int, Throwable).public static final int SINGLE_INSTANCE_ID_QUEUED
public static final int REACHED_RETRY_LIMIT
Job.onRun()
and will be cancelled because it has reached its retry limit.Job.getRetryLimit()public static final int CANCELLED_WHILE_RUNNING
Job.onRun()
and will be cancelled because it was cancelled via
JobManager.cancelJobs(TagConstraint, String...) while it was running.public static final int SINGLE_INSTANCE_WHILE_RUNNING
Job.onRun()
and will be cancelled because another job with the same single instance id was
queued while it was running.Job.getSingleInstanceId()public static final int CANCELLED_VIA_SHOULD_RE_RUN
Job.onRun()
and will be cancelled because it decided not to run again via
Job.shouldReRunOnThrowable(Throwable, int, int).public static final int REACHED_DEADLINE
This means the job's params were constructed using
Params.overrideDeadlineToCancelInMs(long).