Package io.pravega.client.tables
Class Remove
- java.lang.Object
-
- io.pravega.client.tables.TableModification
-
- io.pravega.client.tables.Remove
-
public final class Remove extends TableModification
Removes aTableKeyfrom aKeyValueTable.
-
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description VersiongetVersion()Gets aVersionthat may condition the modification.booleanisRemoval()Gets a value indicating whether this modification attempts to remove theTableKeyor not.java.lang.StringtoString()-
Methods inherited from class io.pravega.client.tables.TableModification
getKey
-
-
-
-
Constructor Detail
-
Remove
public Remove(TableKey key)
Creates a new instance of theRemoveclass for an unconditional removal.- Parameters:
key- TheTableKeyto remove.
-
Remove
public Remove(TableKey key, @Nullable Version version)
Creates a new instance of theRemoveclass for a conditional removal.- Parameters:
key- TheTableKeyto remove.version- Optional) TheVersionto condition the removal on. This can be retrieved fromTableEntry.getVersion()or it may beVersion.NOT_EXISTSorVersion.NO_VERSION. Ifnull, this will be substituted withVersion.NO_VERSION, which makes this operation an Unconditional Update.
-
-
Method Detail
-
isRemoval
public boolean isRemoval()
Description copied from class:TableModificationGets a value indicating whether this modification attempts to remove theTableKeyor not.- Specified by:
isRemovalin classTableModification- Returns:
- True if removal, false otherwise.
-
getVersion
public Version getVersion()
Description copied from class:TableModificationGets aVersionthat may condition the modification. SeeKeyValueTablefor details on conditional updates.- Specified by:
getVersionin classTableModification- Returns:
- The
Version.
-
toString
public java.lang.String toString()
- Overrides:
toStringin classjava.lang.Object
-
-