Loading api/current.txt +5 −0 Original line number Diff line number Diff line Loading @@ -6239,6 +6239,7 @@ package android.app.job { method public long getMinLatencyMillis(); method public int getNetworkType(); method public android.content.ComponentName getService(); method public android.os.Bundle getTransientExtras(); method public android.app.job.JobInfo.TriggerContentUri[] getTriggerContentUris(); method public boolean isPeriodic(); method public boolean isPersisted(); Loading Loading @@ -6271,6 +6272,7 @@ package android.app.job { method public android.app.job.JobInfo.Builder setRequiredNetworkType(int); method public android.app.job.JobInfo.Builder setRequiresCharging(boolean); method public android.app.job.JobInfo.Builder setRequiresDeviceIdle(boolean); method public android.app.job.JobInfo.Builder setTransientExtras(android.os.Bundle); } public static final class JobInfo.TriggerContentUri implements android.os.Parcelable { Loading @@ -6287,6 +6289,7 @@ package android.app.job { method public int describeContents(); method public android.os.PersistableBundle getExtras(); method public int getJobId(); method public android.os.Bundle getTransientExtras(); method public java.lang.String[] getTriggeredContentAuthorities(); method public android.net.Uri[] getTriggeredContentUris(); method public boolean isOverrideDeadlineExpired(); Loading Loading @@ -28309,6 +28312,7 @@ package android.os { ctor public Bundle(android.os.Bundle); ctor public Bundle(android.os.PersistableBundle); method public java.lang.Object clone(); method public android.os.Bundle deepcopy(); method public int describeContents(); method public android.os.IBinder getBinder(java.lang.String); method public android.os.Bundle getBundle(java.lang.String); Loading Loading @@ -29017,6 +29021,7 @@ package android.os { ctor public PersistableBundle(int); ctor public PersistableBundle(android.os.PersistableBundle); method public java.lang.Object clone(); method public android.os.PersistableBundle deepcopy(); method public int describeContents(); method public android.os.PersistableBundle getPersistableBundle(java.lang.String); method public void putPersistableBundle(java.lang.String, android.os.PersistableBundle); api/system-current.txt +5 −0 Original line number Diff line number Diff line Loading @@ -6497,6 +6497,7 @@ package android.app.job { method public long getMinLatencyMillis(); method public int getNetworkType(); method public android.content.ComponentName getService(); method public android.os.Bundle getTransientExtras(); method public android.app.job.JobInfo.TriggerContentUri[] getTriggerContentUris(); method public boolean isPeriodic(); method public boolean isPersisted(); Loading Loading @@ -6529,6 +6530,7 @@ package android.app.job { method public android.app.job.JobInfo.Builder setRequiredNetworkType(int); method public android.app.job.JobInfo.Builder setRequiresCharging(boolean); method public android.app.job.JobInfo.Builder setRequiresDeviceIdle(boolean); method public android.app.job.JobInfo.Builder setTransientExtras(android.os.Bundle); } public static final class JobInfo.TriggerContentUri implements android.os.Parcelable { Loading @@ -6545,6 +6547,7 @@ package android.app.job { method public int describeContents(); method public android.os.PersistableBundle getExtras(); method public int getJobId(); method public android.os.Bundle getTransientExtras(); method public java.lang.String[] getTriggeredContentAuthorities(); method public android.net.Uri[] getTriggeredContentUris(); method public boolean isOverrideDeadlineExpired(); Loading Loading @@ -30595,6 +30598,7 @@ package android.os { ctor public Bundle(android.os.Bundle); ctor public Bundle(android.os.PersistableBundle); method public java.lang.Object clone(); method public android.os.Bundle deepcopy(); method public int describeContents(); method public android.os.IBinder getBinder(java.lang.String); method public android.os.Bundle getBundle(java.lang.String); Loading Loading @@ -31303,6 +31307,7 @@ package android.os { ctor public PersistableBundle(int); ctor public PersistableBundle(android.os.PersistableBundle); method public java.lang.Object clone(); method public android.os.PersistableBundle deepcopy(); method public int describeContents(); method public android.os.PersistableBundle getPersistableBundle(java.lang.String); method public void putPersistableBundle(java.lang.String, android.os.PersistableBundle); api/test-current.txt +5 −0 Original line number Diff line number Diff line Loading @@ -6241,6 +6241,7 @@ package android.app.job { method public long getMinLatencyMillis(); method public int getNetworkType(); method public android.content.ComponentName getService(); method public android.os.Bundle getTransientExtras(); method public android.app.job.JobInfo.TriggerContentUri[] getTriggerContentUris(); method public boolean isPeriodic(); method public boolean isPersisted(); Loading Loading @@ -6273,6 +6274,7 @@ package android.app.job { method public android.app.job.JobInfo.Builder setRequiredNetworkType(int); method public android.app.job.JobInfo.Builder setRequiresCharging(boolean); method public android.app.job.JobInfo.Builder setRequiresDeviceIdle(boolean); method public android.app.job.JobInfo.Builder setTransientExtras(android.os.Bundle); } public static final class JobInfo.TriggerContentUri implements android.os.Parcelable { Loading @@ -6289,6 +6291,7 @@ package android.app.job { method public int describeContents(); method public android.os.PersistableBundle getExtras(); method public int getJobId(); method public android.os.Bundle getTransientExtras(); method public java.lang.String[] getTriggeredContentAuthorities(); method public android.net.Uri[] getTriggeredContentUris(); method public boolean isOverrideDeadlineExpired(); Loading Loading @@ -28318,6 +28321,7 @@ package android.os { ctor public Bundle(android.os.Bundle); ctor public Bundle(android.os.PersistableBundle); method public java.lang.Object clone(); method public android.os.Bundle deepcopy(); method public int describeContents(); method public android.os.IBinder getBinder(java.lang.String); method public android.os.Bundle getBundle(java.lang.String); Loading Loading @@ -29026,6 +29030,7 @@ package android.os { ctor public PersistableBundle(int); ctor public PersistableBundle(android.os.PersistableBundle); method public java.lang.Object clone(); method public android.os.PersistableBundle deepcopy(); method public int describeContents(); method public android.os.PersistableBundle getPersistableBundle(java.lang.String); method public void putPersistableBundle(java.lang.String, android.os.PersistableBundle); core/java/android/app/job/JobInfo.java +29 −2 Original line number Diff line number Diff line Loading @@ -20,6 +20,7 @@ import android.annotation.NonNull; import android.annotation.Nullable; import android.content.ComponentName; import android.net.Uri; import android.os.Bundle; import android.os.Parcel; import android.os.Parcelable; import android.os.PersistableBundle; Loading Loading @@ -85,6 +86,7 @@ public class JobInfo implements Parcelable { private final int jobId; private final PersistableBundle extras; private final Bundle transientExtras; private final ComponentName service; private final boolean requireCharging; private final boolean requireDeviceIdle; Loading Loading @@ -116,6 +118,14 @@ public class JobInfo implements Parcelable { return extras; } /** * Bundle of transient extras which are returned to your application at execution time, * but not persisted by the system. */ public Bundle getTransientExtras() { return transientExtras; } /** * Name of the service endpoint that will be called back into by the JobScheduler. */ Loading Loading @@ -247,6 +257,7 @@ public class JobInfo implements Parcelable { private JobInfo(Parcel in) { jobId = in.readInt(); extras = in.readPersistableBundle(); transientExtras = in.readBundle(); service = in.readParcelable(null); requireCharging = in.readInt() == 1; requireDeviceIdle = in.readInt() == 1; Loading @@ -267,7 +278,8 @@ public class JobInfo implements Parcelable { private JobInfo(JobInfo.Builder b) { jobId = b.mJobId; extras = b.mExtras; extras = b.mExtras.deepcopy(); transientExtras = b.mTransientExtras.deepcopy(); service = b.mJobService; requireCharging = b.mRequiresCharging; requireDeviceIdle = b.mRequiresDeviceIdle; Loading Loading @@ -297,6 +309,7 @@ public class JobInfo implements Parcelable { public void writeToParcel(Parcel out, int flags) { out.writeInt(jobId); out.writePersistableBundle(extras); out.writeBundle(transientExtras); out.writeParcelable(service, flags); out.writeInt(requireCharging ? 1 : 0); out.writeInt(requireDeviceIdle ? 1 : 0); Loading Loading @@ -405,6 +418,7 @@ public class JobInfo implements Parcelable { public static final class Builder { private int mJobId; private PersistableBundle mExtras = PersistableBundle.EMPTY; private Bundle mTransientExtras = Bundle.EMPTY; private ComponentName mJobService; private int mPriority; // Requirements. Loading Loading @@ -457,6 +471,16 @@ public class JobInfo implements Parcelable { return this; } /** * Set optional transient extras. This is incompatible with jobs that are also * persisted with {@link #setPersisted(boolean)}; mixing the two is not allowed. * @param extras Bundle containing extras you want the scheduler to hold on to for you. */ public Builder setTransientExtras(Bundle extras) { mTransientExtras = extras; return this; } /** * Set some description of the kind of network type your job needs to have. * Not calling this function means the network is not necessary, as the default is Loading Loading @@ -616,7 +640,6 @@ public class JobInfo implements Parcelable { throw new IllegalArgumentException("You're trying to build a job with no " + "constraints, this is not allowed."); } mExtras = new PersistableBundle(mExtras); // Make our own copy. // Check that a deadline was not set on a periodic job. if (mIsPeriodic && (mMaxExecutionDelayMillis != 0L)) { throw new IllegalArgumentException("Can't call setOverrideDeadline() on a " + Loading @@ -634,6 +657,10 @@ public class JobInfo implements Parcelable { throw new IllegalArgumentException("Can't call addTriggerContentUri() on a " + "persisted job"); } if (mIsPersisted && !mTransientExtras.isEmpty()) { throw new IllegalArgumentException("Can't call setTransientExtras() on a " + "persisted job"); } if (mBackoffPolicySet && mRequiresDeviceIdle) { throw new IllegalArgumentException("An idle mode job will not respect any" + " back-off policy, so calling setBackoffCriteria with" + Loading core/java/android/app/job/JobParameters.java +15 −1 Original line number Diff line number Diff line Loading @@ -18,6 +18,7 @@ package android.app.job; import android.app.job.IJobCallback; import android.net.Uri; import android.os.Bundle; import android.os.IBinder; import android.os.Parcel; import android.os.Parcelable; Loading @@ -42,6 +43,7 @@ public class JobParameters implements Parcelable { private final int jobId; private final PersistableBundle extras; private final Bundle transientExtras; private final IBinder callback; private final boolean overrideDeadlineExpired; private final Uri[] mTriggeredContentUris; Loading @@ -51,10 +53,11 @@ public class JobParameters implements Parcelable { /** @hide */ public JobParameters(IBinder callback, int jobId, PersistableBundle extras, boolean overrideDeadlineExpired, Uri[] triggeredContentUris, Bundle transientExtras, boolean overrideDeadlineExpired, Uri[] triggeredContentUris, String[] triggeredContentAuthorities) { this.jobId = jobId; this.extras = extras; this.transientExtras = transientExtras; this.callback = callback; this.overrideDeadlineExpired = overrideDeadlineExpired; this.mTriggeredContentUris = triggeredContentUris; Loading Loading @@ -85,6 +88,15 @@ public class JobParameters implements Parcelable { return extras; } /** * @return The transient extras you passed in when constructing this job with * {@link android.app.job.JobInfo.Builder#setTransientExtras(android.os.Bundle)}. This will * never be null. If you did not set any extras this will be an empty bundle. */ public Bundle getTransientExtras() { return transientExtras; } /** * For jobs with {@link android.app.job.JobInfo.Builder#setOverrideDeadline(long)} set, this * provides an easy way to tell whether the job is being executed due to the deadline Loading Loading @@ -127,6 +139,7 @@ public class JobParameters implements Parcelable { private JobParameters(Parcel in) { jobId = in.readInt(); extras = in.readPersistableBundle(); transientExtras = in.readBundle(); callback = in.readStrongBinder(); overrideDeadlineExpired = in.readInt() == 1; mTriggeredContentUris = in.createTypedArray(Uri.CREATOR); Loading @@ -148,6 +161,7 @@ public class JobParameters implements Parcelable { public void writeToParcel(Parcel dest, int flags) { dest.writeInt(jobId); dest.writePersistableBundle(extras); dest.writeBundle(transientExtras); dest.writeStrongBinder(callback); dest.writeInt(overrideDeadlineExpired ? 1 : 0); dest.writeTypedArray(mTriggeredContentUris, flags); Loading Loading
api/current.txt +5 −0 Original line number Diff line number Diff line Loading @@ -6239,6 +6239,7 @@ package android.app.job { method public long getMinLatencyMillis(); method public int getNetworkType(); method public android.content.ComponentName getService(); method public android.os.Bundle getTransientExtras(); method public android.app.job.JobInfo.TriggerContentUri[] getTriggerContentUris(); method public boolean isPeriodic(); method public boolean isPersisted(); Loading Loading @@ -6271,6 +6272,7 @@ package android.app.job { method public android.app.job.JobInfo.Builder setRequiredNetworkType(int); method public android.app.job.JobInfo.Builder setRequiresCharging(boolean); method public android.app.job.JobInfo.Builder setRequiresDeviceIdle(boolean); method public android.app.job.JobInfo.Builder setTransientExtras(android.os.Bundle); } public static final class JobInfo.TriggerContentUri implements android.os.Parcelable { Loading @@ -6287,6 +6289,7 @@ package android.app.job { method public int describeContents(); method public android.os.PersistableBundle getExtras(); method public int getJobId(); method public android.os.Bundle getTransientExtras(); method public java.lang.String[] getTriggeredContentAuthorities(); method public android.net.Uri[] getTriggeredContentUris(); method public boolean isOverrideDeadlineExpired(); Loading Loading @@ -28309,6 +28312,7 @@ package android.os { ctor public Bundle(android.os.Bundle); ctor public Bundle(android.os.PersistableBundle); method public java.lang.Object clone(); method public android.os.Bundle deepcopy(); method public int describeContents(); method public android.os.IBinder getBinder(java.lang.String); method public android.os.Bundle getBundle(java.lang.String); Loading Loading @@ -29017,6 +29021,7 @@ package android.os { ctor public PersistableBundle(int); ctor public PersistableBundle(android.os.PersistableBundle); method public java.lang.Object clone(); method public android.os.PersistableBundle deepcopy(); method public int describeContents(); method public android.os.PersistableBundle getPersistableBundle(java.lang.String); method public void putPersistableBundle(java.lang.String, android.os.PersistableBundle);
api/system-current.txt +5 −0 Original line number Diff line number Diff line Loading @@ -6497,6 +6497,7 @@ package android.app.job { method public long getMinLatencyMillis(); method public int getNetworkType(); method public android.content.ComponentName getService(); method public android.os.Bundle getTransientExtras(); method public android.app.job.JobInfo.TriggerContentUri[] getTriggerContentUris(); method public boolean isPeriodic(); method public boolean isPersisted(); Loading Loading @@ -6529,6 +6530,7 @@ package android.app.job { method public android.app.job.JobInfo.Builder setRequiredNetworkType(int); method public android.app.job.JobInfo.Builder setRequiresCharging(boolean); method public android.app.job.JobInfo.Builder setRequiresDeviceIdle(boolean); method public android.app.job.JobInfo.Builder setTransientExtras(android.os.Bundle); } public static final class JobInfo.TriggerContentUri implements android.os.Parcelable { Loading @@ -6545,6 +6547,7 @@ package android.app.job { method public int describeContents(); method public android.os.PersistableBundle getExtras(); method public int getJobId(); method public android.os.Bundle getTransientExtras(); method public java.lang.String[] getTriggeredContentAuthorities(); method public android.net.Uri[] getTriggeredContentUris(); method public boolean isOverrideDeadlineExpired(); Loading Loading @@ -30595,6 +30598,7 @@ package android.os { ctor public Bundle(android.os.Bundle); ctor public Bundle(android.os.PersistableBundle); method public java.lang.Object clone(); method public android.os.Bundle deepcopy(); method public int describeContents(); method public android.os.IBinder getBinder(java.lang.String); method public android.os.Bundle getBundle(java.lang.String); Loading Loading @@ -31303,6 +31307,7 @@ package android.os { ctor public PersistableBundle(int); ctor public PersistableBundle(android.os.PersistableBundle); method public java.lang.Object clone(); method public android.os.PersistableBundle deepcopy(); method public int describeContents(); method public android.os.PersistableBundle getPersistableBundle(java.lang.String); method public void putPersistableBundle(java.lang.String, android.os.PersistableBundle);
api/test-current.txt +5 −0 Original line number Diff line number Diff line Loading @@ -6241,6 +6241,7 @@ package android.app.job { method public long getMinLatencyMillis(); method public int getNetworkType(); method public android.content.ComponentName getService(); method public android.os.Bundle getTransientExtras(); method public android.app.job.JobInfo.TriggerContentUri[] getTriggerContentUris(); method public boolean isPeriodic(); method public boolean isPersisted(); Loading Loading @@ -6273,6 +6274,7 @@ package android.app.job { method public android.app.job.JobInfo.Builder setRequiredNetworkType(int); method public android.app.job.JobInfo.Builder setRequiresCharging(boolean); method public android.app.job.JobInfo.Builder setRequiresDeviceIdle(boolean); method public android.app.job.JobInfo.Builder setTransientExtras(android.os.Bundle); } public static final class JobInfo.TriggerContentUri implements android.os.Parcelable { Loading @@ -6289,6 +6291,7 @@ package android.app.job { method public int describeContents(); method public android.os.PersistableBundle getExtras(); method public int getJobId(); method public android.os.Bundle getTransientExtras(); method public java.lang.String[] getTriggeredContentAuthorities(); method public android.net.Uri[] getTriggeredContentUris(); method public boolean isOverrideDeadlineExpired(); Loading Loading @@ -28318,6 +28321,7 @@ package android.os { ctor public Bundle(android.os.Bundle); ctor public Bundle(android.os.PersistableBundle); method public java.lang.Object clone(); method public android.os.Bundle deepcopy(); method public int describeContents(); method public android.os.IBinder getBinder(java.lang.String); method public android.os.Bundle getBundle(java.lang.String); Loading Loading @@ -29026,6 +29030,7 @@ package android.os { ctor public PersistableBundle(int); ctor public PersistableBundle(android.os.PersistableBundle); method public java.lang.Object clone(); method public android.os.PersistableBundle deepcopy(); method public int describeContents(); method public android.os.PersistableBundle getPersistableBundle(java.lang.String); method public void putPersistableBundle(java.lang.String, android.os.PersistableBundle);
core/java/android/app/job/JobInfo.java +29 −2 Original line number Diff line number Diff line Loading @@ -20,6 +20,7 @@ import android.annotation.NonNull; import android.annotation.Nullable; import android.content.ComponentName; import android.net.Uri; import android.os.Bundle; import android.os.Parcel; import android.os.Parcelable; import android.os.PersistableBundle; Loading Loading @@ -85,6 +86,7 @@ public class JobInfo implements Parcelable { private final int jobId; private final PersistableBundle extras; private final Bundle transientExtras; private final ComponentName service; private final boolean requireCharging; private final boolean requireDeviceIdle; Loading Loading @@ -116,6 +118,14 @@ public class JobInfo implements Parcelable { return extras; } /** * Bundle of transient extras which are returned to your application at execution time, * but not persisted by the system. */ public Bundle getTransientExtras() { return transientExtras; } /** * Name of the service endpoint that will be called back into by the JobScheduler. */ Loading Loading @@ -247,6 +257,7 @@ public class JobInfo implements Parcelable { private JobInfo(Parcel in) { jobId = in.readInt(); extras = in.readPersistableBundle(); transientExtras = in.readBundle(); service = in.readParcelable(null); requireCharging = in.readInt() == 1; requireDeviceIdle = in.readInt() == 1; Loading @@ -267,7 +278,8 @@ public class JobInfo implements Parcelable { private JobInfo(JobInfo.Builder b) { jobId = b.mJobId; extras = b.mExtras; extras = b.mExtras.deepcopy(); transientExtras = b.mTransientExtras.deepcopy(); service = b.mJobService; requireCharging = b.mRequiresCharging; requireDeviceIdle = b.mRequiresDeviceIdle; Loading Loading @@ -297,6 +309,7 @@ public class JobInfo implements Parcelable { public void writeToParcel(Parcel out, int flags) { out.writeInt(jobId); out.writePersistableBundle(extras); out.writeBundle(transientExtras); out.writeParcelable(service, flags); out.writeInt(requireCharging ? 1 : 0); out.writeInt(requireDeviceIdle ? 1 : 0); Loading Loading @@ -405,6 +418,7 @@ public class JobInfo implements Parcelable { public static final class Builder { private int mJobId; private PersistableBundle mExtras = PersistableBundle.EMPTY; private Bundle mTransientExtras = Bundle.EMPTY; private ComponentName mJobService; private int mPriority; // Requirements. Loading Loading @@ -457,6 +471,16 @@ public class JobInfo implements Parcelable { return this; } /** * Set optional transient extras. This is incompatible with jobs that are also * persisted with {@link #setPersisted(boolean)}; mixing the two is not allowed. * @param extras Bundle containing extras you want the scheduler to hold on to for you. */ public Builder setTransientExtras(Bundle extras) { mTransientExtras = extras; return this; } /** * Set some description of the kind of network type your job needs to have. * Not calling this function means the network is not necessary, as the default is Loading Loading @@ -616,7 +640,6 @@ public class JobInfo implements Parcelable { throw new IllegalArgumentException("You're trying to build a job with no " + "constraints, this is not allowed."); } mExtras = new PersistableBundle(mExtras); // Make our own copy. // Check that a deadline was not set on a periodic job. if (mIsPeriodic && (mMaxExecutionDelayMillis != 0L)) { throw new IllegalArgumentException("Can't call setOverrideDeadline() on a " + Loading @@ -634,6 +657,10 @@ public class JobInfo implements Parcelable { throw new IllegalArgumentException("Can't call addTriggerContentUri() on a " + "persisted job"); } if (mIsPersisted && !mTransientExtras.isEmpty()) { throw new IllegalArgumentException("Can't call setTransientExtras() on a " + "persisted job"); } if (mBackoffPolicySet && mRequiresDeviceIdle) { throw new IllegalArgumentException("An idle mode job will not respect any" + " back-off policy, so calling setBackoffCriteria with" + Loading
core/java/android/app/job/JobParameters.java +15 −1 Original line number Diff line number Diff line Loading @@ -18,6 +18,7 @@ package android.app.job; import android.app.job.IJobCallback; import android.net.Uri; import android.os.Bundle; import android.os.IBinder; import android.os.Parcel; import android.os.Parcelable; Loading @@ -42,6 +43,7 @@ public class JobParameters implements Parcelable { private final int jobId; private final PersistableBundle extras; private final Bundle transientExtras; private final IBinder callback; private final boolean overrideDeadlineExpired; private final Uri[] mTriggeredContentUris; Loading @@ -51,10 +53,11 @@ public class JobParameters implements Parcelable { /** @hide */ public JobParameters(IBinder callback, int jobId, PersistableBundle extras, boolean overrideDeadlineExpired, Uri[] triggeredContentUris, Bundle transientExtras, boolean overrideDeadlineExpired, Uri[] triggeredContentUris, String[] triggeredContentAuthorities) { this.jobId = jobId; this.extras = extras; this.transientExtras = transientExtras; this.callback = callback; this.overrideDeadlineExpired = overrideDeadlineExpired; this.mTriggeredContentUris = triggeredContentUris; Loading Loading @@ -85,6 +88,15 @@ public class JobParameters implements Parcelable { return extras; } /** * @return The transient extras you passed in when constructing this job with * {@link android.app.job.JobInfo.Builder#setTransientExtras(android.os.Bundle)}. This will * never be null. If you did not set any extras this will be an empty bundle. */ public Bundle getTransientExtras() { return transientExtras; } /** * For jobs with {@link android.app.job.JobInfo.Builder#setOverrideDeadline(long)} set, this * provides an easy way to tell whether the job is being executed due to the deadline Loading Loading @@ -127,6 +139,7 @@ public class JobParameters implements Parcelable { private JobParameters(Parcel in) { jobId = in.readInt(); extras = in.readPersistableBundle(); transientExtras = in.readBundle(); callback = in.readStrongBinder(); overrideDeadlineExpired = in.readInt() == 1; mTriggeredContentUris = in.createTypedArray(Uri.CREATOR); Loading @@ -148,6 +161,7 @@ public class JobParameters implements Parcelable { public void writeToParcel(Parcel dest, int flags) { dest.writeInt(jobId); dest.writePersistableBundle(extras); dest.writeBundle(transientExtras); dest.writeStrongBinder(callback); dest.writeInt(overrideDeadlineExpired ? 1 : 0); dest.writeTypedArray(mTriggeredContentUris, flags); Loading