org.apache.hadoop.hbase.client
Class OperationWithAttributes
java.lang.Object
org.apache.hadoop.hbase.client.Operation
org.apache.hadoop.hbase.client.OperationWithAttributes
- All Implemented Interfaces:
- Attributes
- Direct Known Subclasses:
- Get, Mutation, Scan
public abstract class OperationWithAttributes
- extends Operation
- implements Attributes
OperationWithAttributes
public OperationWithAttributes()
setAttribute
public void setAttribute(String name,
byte[] value)
- Description copied from interface:
Attributes
- Sets an attribute.
In case value = null attribute is removed from the attributes map.
- Specified by:
setAttribute
in interface Attributes
- Parameters:
name
- attribute namevalue
- attribute value
getAttribute
public byte[] getAttribute(String name)
- Description copied from interface:
Attributes
- Gets an attribute
- Specified by:
getAttribute
in interface Attributes
- Parameters:
name
- attribute name
- Returns:
- attribute value if attribute is set, null otherwise
getAttributesMap
public Map<String,byte[]> getAttributesMap()
- Description copied from interface:
Attributes
- Gets all attributes
- Specified by:
getAttributesMap
in interface Attributes
- Returns:
- unmodifiable map of all attributes
getAttributeSize
protected long getAttributeSize()
writeAttributes
protected void writeAttributes(DataOutput out)
throws IOException
- Throws:
IOException
readAttributes
protected void readAttributes(DataInput in)
throws IOException
- Throws:
IOException
Copyright © 2012 The Apache Software Foundation. All Rights Reserved.