public final class Job extends java.lang.Object implements JobParameters
| Modifier and Type | Class and Description |
|---|---|
static class |
Job.Builder
A class that understands how to build a
Job. |
| Modifier and Type | Method and Description |
|---|---|
int[] |
getConstraints()
The runtime constraints applied to this Job.
|
android.os.Bundle |
getExtras()
The optional set of user-supplied extras associated with this Job.
|
int |
getLifetime()
The Job's lifetime; how long it should persist for.
|
RetryStrategy |
getRetryStrategy()
The RetryStrategy for the Job.
|
java.lang.String |
getService()
Returns the name of the backing JobService class.
|
java.lang.String |
getTag()
Returns a string identifier for the Job.
|
JobTrigger |
getTrigger()
The Job's Trigger, which decides when the Job is ready to run.
|
boolean |
isRecurring()
Whether the Job should repeat.
|
boolean |
shouldReplaceCurrent()
Whether the Job should replace a pre-existing Job with the same tag.
|
@NonNull public int[] getConstraints()
getConstraints in interface JobParameters@Nullable public android.os.Bundle getExtras()
getExtras in interface JobParameters@NonNull public RetryStrategy getRetryStrategy()
getRetryStrategy in interface JobParameterspublic boolean shouldReplaceCurrent()
shouldReplaceCurrent in interface JobParameters@NonNull public java.lang.String getTag()
getTag in interface JobParameters@NonNull public JobTrigger getTrigger()
getTrigger in interface JobParameterspublic int getLifetime()
getLifetime in interface JobParameterspublic boolean isRecurring()
isRecurring in interface JobParameters@NonNull public java.lang.String getService()
getService in interface JobParameters