Class CheckAndMutate

java.lang.Object
org.apache.hadoop.hbase.client.CheckAndMutate
All Implemented Interfaces:
Row

@Public @Evolving public final class CheckAndMutate extends Object implements Row
Used to perform CheckAndMutate operations.

Use the builder class to instantiate a CheckAndMutate object. This builder class is fluent style APIs, the code are like:

 
 // A CheckAndMutate operation where do the specified action if the column (specified by the
 // family and the qualifier) of the row equals to the specified value
 CheckAndMutate checkAndMutate = CheckAndMutate.newBuilder(row)
   .ifEquals(family, qualifier, value)
   .build(put);

 // A CheckAndMutate operation where do the specified action if the column (specified by the
 // family and the qualifier) of the row doesn't exist
 CheckAndMutate checkAndMutate = CheckAndMutate.newBuilder(row)
   .ifNotExists(family, qualifier)
   .build(put);

 // A CheckAndMutate operation where do the specified action if the row matches the filter
 CheckAndMutate checkAndMutate = CheckAndMutate.newBuilder(row)
   .ifMatches(filter)
   .build(delete);