public final class AtomicIncrementRequest extends HBaseRpc implements HBaseRpc.HasTable, HBaseRpc.HasKey, HBaseRpc.HasFamily, HBaseRpc.HasQualifier
byte arrays in argumentbyte[] in argument will copy it.
For more info, please refer to the documentation of HBaseRpc.
Strings in argumentHBaseRpc.HasFamily, HBaseRpc.HasKey, HBaseRpc.HasQualifier, HBaseRpc.HasQualifiers, HBaseRpc.HasTable, HBaseRpc.HasTimestamp, HBaseRpc.HasValue, HBaseRpc.HasValues| Modifier and Type | Field and Description |
|---|---|
static byte[] |
MUTATE
RPC method name to use with HBase 0.95+.
|
| Constructor and Description |
|---|
AtomicIncrementRequest(byte[] table,
byte[] key,
byte[] family,
byte[] qualifier)
Constructor.
|
AtomicIncrementRequest(byte[] table,
byte[] key,
byte[] family,
byte[] qualifier,
long amount)
Constructor.
|
AtomicIncrementRequest(String table,
String key,
String family,
String qualifier)
Constructor.
|
AtomicIncrementRequest(String table,
String key,
String family,
String qualifier,
long amount)
Constructor.
|
| Modifier and Type | Method and Description |
|---|---|
byte[] |
family()
Returns the family this RPC is for.
|
long |
getAmount()
Returns the amount by which the value is going to be incremented.
|
byte[] |
key()
Returns the row key this RPC is for.
|
byte[] |
qualifier()
Returns the column qualifier this RPC is for.
|
void |
setAmount(long amount)
Changes the amount by which the value is going to be incremented.
|
byte[] |
table()
Returns the name of the table this RPC is for.
|
String |
toString() |
failfast, getTimeout, isProbe, isTraceRPC, setFailfast, setProbe, setTimeout, setTraceRPCpublic AtomicIncrementRequest(byte[] table,
byte[] key,
byte[] family,
byte[] qualifier,
long amount)
table - The non-empty name of the table to use.key - The row key of the value to increment.family - The column family of the value to increment.qualifier - The column qualifier of the value to increment.amount - Amount by which to increment the value in HBase.
If negative, the value in HBase will be decremented.public AtomicIncrementRequest(byte[] table,
byte[] key,
byte[] family,
byte[] qualifier)
AtomicIncrementRequest(table, key, family, qualifier, 1)
These byte arrays will NOT be copied.
table - The non-empty name of the table to use.key - The row key of the value to increment.family - The column family of the value to increment.qualifier - The column qualifier of the value to increment.public AtomicIncrementRequest(String table, String key, String family, String qualifier, long amount)
table - The non-empty name of the table to use.key - The row key of the value to increment.family - The column family of the value to increment.qualifier - The column qualifier of the value to increment.amount - Amount by which to increment the value in HBase.
If negative, the value in HBase will be decremented.public AtomicIncrementRequest(String table, String key, String family, String qualifier)
AtomicIncrementRequest(table, key, family, qualifier, 1)table - The non-empty name of the table to use.key - The row key of the value to increment.family - The column family of the value to increment.qualifier - The column qualifier of the value to increment.public long getAmount()
public void setAmount(long amount)
amount - The new amount. If negative, the value will be decremented.public byte[] table()
HBaseRpc.HasTableDO NOT MODIFY THE CONTENTS OF THE ARRAY RETURNED.
table in interface HBaseRpc.HasTablepublic byte[] key()
HBaseRpc.HasKeyDO NOT MODIFY THE CONTENTS OF THE ARRAY RETURNED.
key in interface HBaseRpc.HasKeypublic byte[] family()
HBaseRpc.HasFamilyDO NOT MODIFY THE CONTENTS OF THE ARRAY RETURNED.
family in interface HBaseRpc.HasFamilypublic byte[] qualifier()
HBaseRpc.HasQualifierDO NOT MODIFY THE CONTENTS OF THE ARRAY RETURNED.
qualifier in interface HBaseRpc.HasQualifierCopyright © 2010-2017, The Async HBase Authors