@InterfaceAudience.Public public class Put extends Mutation implements HeapSize
durability, familyMap, MUTATION_OVERHEAD, row, ts
ID_ATRIBUTE
COMPARATOR
Constructor and Description |
---|
Put(byte[] row)
Create a Put operation for the specified row.
|
Put(byte[] row,
boolean rowIsImmutable)
Create a Put operation for an immutable row key.
|
Put(byte[] rowArray,
int rowOffset,
int rowLength)
We make a copy of the passed in row key to keep local.
|
Put(byte[] rowArray,
int rowOffset,
int rowLength,
long ts)
We make a copy of the passed in row key to keep local.
|
Put(byte[] row,
long ts)
Create a Put operation for the specified row, using a given timestamp.
|
Put(byte[] row,
long ts,
boolean rowIsImmutable)
Create a Put operation for an immutable row key, using a given timestamp.
|
Put(byte[] row,
long ts,
NavigableMap<byte[],List<Cell>> familyMap)
Construct the Put with user defined data.
|
Put(ByteBuffer row) |
Put(ByteBuffer row,
long ts) |
Put(Put putToCopy)
Copy constructor.
|
Modifier and Type | Method and Description |
---|---|
Put |
add(Cell cell)
Add the specified KeyValue to this Put operation.
|
Put |
addColumn(byte[] family,
byte[] qualifier,
byte[] value)
Add the specified column and value to this Put operation.
|
Put |
addColumn(byte[] family,
byte[] qualifier,
long ts,
byte[] value)
Add the specified column and value, with the specified timestamp as
its version to this Put operation.
|
Put |
addColumn(byte[] family,
ByteBuffer qualifier,
long ts,
ByteBuffer value)
Add the specified column and value, with the specified timestamp as
its version to this Put operation.
|
Put |
addImmutable(byte[] family,
byte[] qualifier,
byte[] value)
Deprecated.
As of release 2.0.0, this will be removed in HBase 3.0.0.
Use
add(Cell) and CellBuilder instead |
Put |
addImmutable(byte[] family,
byte[] qualifier,
long ts,
byte[] value)
Deprecated.
As of release 2.0.0, this will be removed in HBase 3.0.0.
Use
add(Cell) and CellBuilder instead |
Put |
addImmutable(byte[] family,
ByteBuffer qualifier,
long ts,
ByteBuffer value)
Deprecated.
As of release 2.0.0, this will be removed in HBase 3.0.0.
Use
add(Cell) and CellBuilder instead |
Put |
setACL(Map<String,Permission> perms) |
Put |
setACL(String user,
Permission perms) |
Put |
setAttribute(String name,
byte[] value)
Sets an attribute.
|
Put |
setCellVisibility(CellVisibility expression)
Sets the visibility expression associated with cells in this Mutation.
|
Put |
setClusterIds(List<UUID> clusterIds)
Marks that the clusters with the given clusterIds have consumed the mutation
|
Put |
setDurability(Durability d)
Set the durability for this mutation
|
Put |
setFamilyCellMap(NavigableMap<byte[],List<Cell>> map)
Deprecated.
As of release 2.0.0, this will be removed in HBase 3.0.0.
Use
Put(byte[], long, NavigableMap) instead |
Put |
setId(String id)
This method allows you to set an identifier on an operation.
|
Put |
setPriority(int priority) |
Put |
setTimestamp(long timestamp)
Set the timestamp of the delete.
|
Put |
setTTL(long ttl)
Set the TTL desired for the result of the mutation, in milliseconds.
|
cellScanner, checkRow, checkRow, checkRow, compareTo, createPutKeyValue, createPutKeyValue, createPutKeyValue, extraHeapSize, get, getACL, getCellList, getCellVisibility, getClusterIds, getDurability, getFamilyCellMap, getFingerprint, getRow, getTimestamp, getTimeStamp, getTTL, has, has, has, has, has, heapSize, isEmpty, isReturnResults, numFamilies, setReturnResults, size, toCellVisibility, toMap
getAttribute, getAttributeSize, getAttributesMap, getId, getPriority
toJSON, toJSON, toMap, toString, toString
public Put(byte[] row)
row
- row keypublic Put(byte[] row, long ts)
row
- row key; we make a copy of what we are passed to keep local.ts
- timestamppublic Put(byte[] rowArray, int rowOffset, int rowLength)
rowArray
- rowOffset
- rowLength
- public Put(ByteBuffer row, long ts)
row
- row key; we make a copy of what we are passed to keep local.ts
- timestamppublic Put(ByteBuffer row)
row
- row key; we make a copy of what we are passed to keep local.public Put(byte[] rowArray, int rowOffset, int rowLength, long ts)
rowArray
- rowOffset
- rowLength
- ts
- public Put(byte[] row, boolean rowIsImmutable)
row
- row keyrowIsImmutable
- whether the input row is immutable.
Set to true if the caller can guarantee that
the row will not be changed for the Put duration.public Put(byte[] row, long ts, boolean rowIsImmutable)
row
- row keyts
- timestamprowIsImmutable
- whether the input row is immutable.
Set to true if the caller can guarantee that
the row will not be changed for the Put duration.public Put(Put putToCopy)
putToCopy
- put to copypublic Put(byte[] row, long ts, NavigableMap<byte[],List<Cell>> familyMap)
row
- row. CAN'T be nullts
- timestampfamilyMap
- the map to collect all cells internally. CAN'T be nullpublic Put addColumn(byte[] family, byte[] qualifier, byte[] value)
family
- family namequalifier
- column qualifiervalue
- column value@Deprecated public Put addImmutable(byte[] family, byte[] qualifier, byte[] value)
add(Cell)
and CellBuilder
insteadaddColumn(byte[], byte[], byte[])
. This version expects
that the underlying arrays won't change. It's intended
for usage internal HBase to and for advanced client applications.public Put addColumn(byte[] family, byte[] qualifier, long ts, byte[] value)
family
- family namequalifier
- column qualifierts
- version timestampvalue
- column value@Deprecated public Put addImmutable(byte[] family, byte[] qualifier, long ts, byte[] value)
add(Cell)
and CellBuilder
insteadaddColumn(byte[], byte[], long, byte[])
. This version expects
that the underlying arrays won't change. It's intended
for usage internal HBase to and for advanced client applications.public Put addColumn(byte[] family, ByteBuffer qualifier, long ts, ByteBuffer value)
family
- family namequalifier
- column qualifierts
- version timestampvalue
- column value@Deprecated public Put addImmutable(byte[] family, ByteBuffer qualifier, long ts, ByteBuffer value)
add(Cell)
and CellBuilder
insteadaddColumn(byte[], ByteBuffer, long, ByteBuffer)
. This version expects
that the underlying arrays won't change. It's intended
for usage internal HBase to and for advanced client applications.public Put add(Cell cell) throws IOException
add
in class Mutation
cell
- individual cellIOException
- epublic Put setTimestamp(long timestamp)
Mutation
setTimestamp
in class Mutation
public Put setAttribute(String name, byte[] value)
Attributes
setAttribute
in interface Attributes
setAttribute
in class OperationWithAttributes
name
- attribute namevalue
- attribute valuepublic Put setId(String id)
OperationWithAttributes
setId
in class OperationWithAttributes
id
- id to set for the scanpublic Put setDurability(Durability d)
Mutation
setDurability
in class Mutation
@Deprecated public Put setFamilyCellMap(NavigableMap<byte[],List<Cell>> map)
Put(byte[], long, NavigableMap)
insteadsetFamilyCellMap
in class Mutation
public Put setClusterIds(List<UUID> clusterIds)
Mutation
setClusterIds
in class Mutation
clusterIds
- of the clusters that have consumed the mutationpublic Put setCellVisibility(CellVisibility expression)
Mutation
setCellVisibility
in class Mutation
public Put setACL(String user, Permission perms)
public Put setACL(Map<String,Permission> perms)
public Put setTTL(long ttl)
Mutation
public Put setPriority(int priority)
setPriority
in class OperationWithAttributes
Copyright © 2007–2020 The Apache Software Foundation. All rights reserved.