ExistingWorkPolicy

public final enum ExistingWorkPolicy
extends Enum<ExistingWorkPolicy>

java.lang.Object
   ↳ java.lang.Enum<androidx.work.ExistingWorkPolicy>
     ↳ androidx.work.ExistingWorkPolicy


An enumeration of the conflict resolution policies available to unique OneTimeWorkRequests in case of a collision.

Summary

Enum values

ExistingWorkPolicy  APPEND

If there is existing pending (uncompleted) work with the same unique name, append the newly-specified work as a child of all the leaves of that work sequence. 

ExistingWorkPolicy  APPEND_OR_REPLACE

If there is existing pending (uncompleted) work with the same unique name, append the newly-specified work as the child of all the leaves of that work sequence. 

ExistingWorkPolicy  KEEP

If there is existing pending (uncompleted) work with the same unique name, do nothing. 

ExistingWorkPolicy  REPLACE

If there is existing pending (uncompleted) work with the same unique name, cancel and delete it. 

Public methods

static ExistingWorkPolicy valueOf(String name)
static final ExistingWorkPolicy[] values()

Inherited methods