@InterfaceAudience.Public public class RowMutations extends Object implements Row
We compare and equate mutations based off their row so be careful putting RowMutations into Sets or using them as keys in Maps.
Modifier and Type | Field and Description |
---|---|
private List<Mutation> |
mutations |
private byte[] |
row |
COMPARATOR
Constructor and Description |
---|
RowMutations(byte[] row) |
RowMutations(byte[] row,
int initialCapacity)
Create an atomic mutation for the specified row.
|
Modifier and Type | Method and Description |
---|---|
void |
add(Delete d)
Deprecated.
since 2.0 version and will be removed in 3.0 version. use
add(Mutation) |
RowMutations |
add(List<? extends Mutation> mutations)
Add a list of mutations
|
RowMutations |
add(Mutation mutation)
|
void |
add(Put p)
Deprecated.
since 2.0 version and will be removed in 3.0 version. use
add(Mutation) |
int |
compareTo(Row i)
Deprecated.
As of release 2.0.0, this will be removed in HBase 3.0.0. Use
Row.COMPARATOR instead |
boolean |
equals(Object obj)
Deprecated.
As of release 2.0.0, this will be removed in HBase 3.0.0. No replacement
|
int |
getMaxPriority() |
List<Mutation> |
getMutations()
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. No replacement
|
static RowMutations |
of(List<? extends Mutation> mutations)
Create a
RowMutations with the specified mutations. |
public RowMutations(byte[] row)
public RowMutations(byte[] row, int initialCapacity)
row
- row keyinitialCapacity
- the initial capacity of the RowMutationspublic static RowMutations of(List<? extends Mutation> mutations) throws IOException
RowMutations
with the specified mutations.mutations
- the mutations to send n * @throws IOException if any row in mutations is
different to anotherIOException
@Deprecated public void add(Put p) throws IOException
add(Mutation)
Put
operation to the list of mutationsp
- The Put
to addIOException
- if the row of added mutation doesn't match the original row@Deprecated public void add(Delete d) throws IOException
add(Mutation)
Delete
operation to the list of mutationsd
- The Delete
to addIOException
- if the row of added mutation doesn't match the original rowpublic RowMutations add(Mutation mutation) throws IOException
mutation
- The data to send.IOException
- if the row of added mutation doesn't match the original rowpublic RowMutations add(List<? extends Mutation> mutations) throws IOException
mutations
- The data to send.IOException
- if the row of added mutation doesn't match the original row@Deprecated public int compareTo(Row i)
Row.COMPARATOR
insteadRow
compareTo
in interface Comparable<Row>
compareTo
in interface Row
@Deprecated public boolean equals(Object obj)
@Deprecated public int hashCode()
public List<Mutation> getMutations()
public int getMaxPriority()
Copyright © 2007–2020 The Apache Software Foundation. All rights reserved.