Package org.apache.hadoop.hbase.client
Class RowMutations
java.lang.Object
org.apache.hadoop.hbase.client.RowMutations
- All Implemented Interfaces:
Comparable<Row>
,Row
Performs multiple mutations atomically on a single row. The mutations are performed in the order
in which they were added.
We compare and equate mutations based off their row so be careful putting RowMutations into Sets or using them as keys in Maps.
-
Field Summary
Fields inherited from interface org.apache.hadoop.hbase.client.Row
COMPARATOR
-
Constructor Summary
ConstructorDescriptionRowMutations
(byte[] row) RowMutations
(byte[] row, int initialCapacity) Create an atomic mutation for the specified row. -
Method Summary
Modifier and TypeMethodDescriptionAdd a list of mutationsvoid
Deprecated.since 2.0 version and will be removed in 3.0 version.void
Deprecated.since 2.0 version and will be removed in 3.0 version.int
Deprecated.As of release 2.0.0, this will be removed in HBase 3.0.0.boolean
Deprecated.As of release 2.0.0, this will be removed in HBase 3.0.0.int
Returns An unmodifiable list of the current mutations.byte[]
getRow()
Returns The row.int
hashCode()
Deprecated.As of release 2.0.0, this will be removed in HBase 3.0.0.static RowMutations
Create aRowMutations
with the specified mutations.
-
Field Details
-
mutations
-
row
-
-
Constructor Details
-
RowMutations
-
RowMutations
Create an atomic mutation for the specified row.- Parameters:
row
- row keyinitialCapacity
- the initial capacity of the RowMutations
-
-
Method Details
-
of
Create aRowMutations
with the specified mutations.- Parameters:
mutations
- the mutations to send- Throws:
IOException
- if any row in mutations is different to another
-
add
Deprecated.since 2.0 version and will be removed in 3.0 version. useadd(Mutation)
Add aPut
operation to the list of mutations- Parameters:
p
- ThePut
to add- Throws:
IOException
- if the row of added mutation doesn't match the original row
-
add
Deprecated.since 2.0 version and will be removed in 3.0 version. useadd(Mutation)
Add aDelete
operation to the list of mutations- Parameters:
d
- TheDelete
to add- Throws:
IOException
- if the row of added mutation doesn't match the original row
-
add
- Parameters:
mutation
- The data to send.- Throws:
IOException
- if the row of added mutation doesn't match the original row
-
add
Add a list of mutations- Parameters:
mutations
- The data to send.- Throws:
IOException
- if the row of added mutation doesn't match the original row
-
compareTo
Deprecated.As of release 2.0.0, this will be removed in HBase 3.0.0. UseRow.COMPARATOR
insteadDescription copied from interface:Row
Compare this row to another row.- Specified by:
compareTo
in interfaceComparable<Row>
- Specified by:
compareTo
in interfaceRow
-
equals
Deprecated.As of release 2.0.0, this will be removed in HBase 3.0.0. No replacement -
hashCode
Deprecated.As of release 2.0.0, this will be removed in HBase 3.0.0. No replacement -
getRow
Description copied from interface:Row
Returns The row. -
getMutations
Returns An unmodifiable list of the current mutations. -
getMaxPriority
-