Remove deprecated WorkManagerScheduler constructor

Use a non deprecated constructor that includes the option to provide a `Context` parameter instead.

#minor-release

PiperOrigin-RevId: 532535770
This commit is contained in:
rohks 2023-05-16 20:14:01 +01:00 committed by Ian Baker
parent 1061135cfd
commit df52864420
2 changed files with 3 additions and 10 deletions

View File

@ -37,6 +37,9 @@
Kotlin Charsets from the `kotlin.text` package, the
`java.nio.charset.StandardCharsets` or the
`com.google.common.base.Charsets` instead.
* Remove deprecated `WorkManagerScheduler` constructor, use a non
deprecated constructor that includes the option to provide a `Context`
parameter instead.
### 1.0.2 (2023-05-18)

View File

@ -56,16 +56,6 @@ public final class WorkManagerScheduler implements Scheduler {
private final WorkManager workManager;
private final String workName;
/**
* @deprecated Call {@link #WorkManagerScheduler(Context, String)} instead.
*/
@Deprecated
@SuppressWarnings("deprecation")
public WorkManagerScheduler(String workName) {
this.workName = workName;
workManager = WorkManager.getInstance();
}
/**
* @param context A context.
* @param workName A name for work scheduled by this instance. If the same name was used by a