@InterfaceAudience.Public @InterfaceStability.Evolving public static final class CheckAndMutate.Builder extends Object
Modifier and Type | Field and Description |
---|---|
private byte[] |
family |
private Filter |
filter |
private CompareOperator |
op |
private byte[] |
qualifier |
private byte[] |
row |
private TimeRange |
timeRange |
private byte[] |
value |
Modifier | Constructor and Description |
---|---|
private |
Builder(byte[] row) |
Modifier and Type | Method and Description |
---|---|
CheckAndMutate |
build(Append append)
Build the CheckAndMutate object with an Append to commit if the check succeeds.
|
CheckAndMutate |
build(Delete delete)
Build the CheckAndMutate object
|
CheckAndMutate |
build(Increment increment)
Build the CheckAndMutate object with an Increment to commit if the check succeeds.
|
CheckAndMutate |
build(Put put)
Build the CheckAndMutate object
|
CheckAndMutate |
build(RowMutations mutations)
Build the CheckAndMutate object with a RowMutations to commit if the check succeeds.
|
CheckAndMutate.Builder |
ifEquals(byte[] family,
byte[] qualifier,
byte[] value)
Check for equality
|
CheckAndMutate.Builder |
ifMatches(byte[] family,
byte[] qualifier,
CompareOperator compareOp,
byte[] value)
Check for match
|
CheckAndMutate.Builder |
ifMatches(Filter filter)
Check for match
|
CheckAndMutate.Builder |
ifNotExists(byte[] family,
byte[] qualifier)
Check for lack of column
|
private void |
preCheck(Row action) |
CheckAndMutate.Builder |
timeRange(TimeRange timeRange)
Specify a timerange
|
private final byte[] row
private byte[] family
private byte[] qualifier
private CompareOperator op
private byte[] value
private Builder(byte[] row)
public CheckAndMutate.Builder ifNotExists(byte[] family, byte[] qualifier)
family
- family to checkqualifier
- qualifier to checkpublic CheckAndMutate.Builder ifEquals(byte[] family, byte[] qualifier, byte[] value)
family
- family to checkqualifier
- qualifier to checkvalue
- the expected valuepublic CheckAndMutate.Builder ifMatches(byte[] family, byte[] qualifier, CompareOperator compareOp, byte[] value)
family
- family to checkqualifier
- qualifier to checkcompareOp
- comparison operator to usevalue
- the expected valuepublic CheckAndMutate.Builder ifMatches(Filter filter)
filter
- filter to checkpublic CheckAndMutate.Builder timeRange(TimeRange timeRange)
timeRange
- time range to checkpublic CheckAndMutate build(Put put)
put
- data to put if check succeedspublic CheckAndMutate build(Delete delete)
delete
- data to delete if check succeedspublic CheckAndMutate build(Increment increment)
increment
- data to increment if check succeedspublic CheckAndMutate build(Append append)
append
- data to append if check succeedspublic CheckAndMutate build(RowMutations mutations)
mutations
- mutations to perform if check succeedsCopyright © 2007–2020 The Apache Software Foundation. All rights reserved.