org.apache.hadoop.hbase.io
Class BatchOperation

java.lang.Object
  extended by org.apache.hadoop.hbase.io.BatchOperation
All Implemented Interfaces:
HeapSize, org.apache.hadoop.io.Writable

Deprecated. As of hbase 0.20.0, replaced by new Get/Put/Delete/Result-based API.

public class BatchOperation
extends Object
implements org.apache.hadoop.io.Writable, HeapSize

Batch update operation. If value is null, its a DELETE operation. If its non-null, its a PUT. This object is purposely bare-bones because many instances are created during bulk uploads. We have one class for DELETEs and PUTs rather than a class per type because it makes the serialization easier.

See Also:
BatchUpdate

Field Summary
 int ESTIMATED_HEAP_TAX
          Deprecated. Estimated size of this object.
 
Constructor Summary
BatchOperation()
          Deprecated. Default constructor
BatchOperation(byte[] column)
          Deprecated. Creates a DELETE batch operation.
BatchOperation(byte[] column, byte[] value)
          Deprecated. Create a batch operation.
BatchOperation(String column)
          Deprecated. Creates a DELETE batch operation.
BatchOperation(String column, String value)
          Deprecated. Create a batch operation.
 
Method Summary
 byte[] getColumn()
          Deprecated.  
 byte[] getValue()
          Deprecated.  
 long heapSize()
          Deprecated.  
 boolean isPut()
          Deprecated.  
 void readFields(DataInput in)
          Deprecated.  
 String toString()
          Deprecated.  
 void write(DataOutput out)
          Deprecated.  
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Field Detail

ESTIMATED_HEAP_TAX

public final int ESTIMATED_HEAP_TAX
Deprecated. 
Estimated size of this object.

See Also:
Constant Field Values
Constructor Detail

BatchOperation

public BatchOperation()
Deprecated. 
Default constructor


BatchOperation

public BatchOperation(byte[] column)
Deprecated. 
Creates a DELETE batch operation.

Parameters:
column - column name

BatchOperation

public BatchOperation(String column)
Deprecated. 
Creates a DELETE batch operation.

Parameters:
column - column name

BatchOperation

public BatchOperation(String column,
                      String value)
Deprecated. 
Create a batch operation.

Parameters:
column - column name
value - column value. If non-null, this is a PUT operation.

BatchOperation

public BatchOperation(byte[] column,
                      byte[] value)
Deprecated. 
Create a batch operation.

Parameters:
column - column name
value - column value. If non-null, this is a PUT operation.
Method Detail

getColumn

public byte[] getColumn()
Deprecated. 
Returns:
the column

getValue

public byte[] getValue()
Deprecated. 
Returns:
the value

isPut

public boolean isPut()
Deprecated. 
Returns:
True if this is a PUT operation (this.value is not null).

toString

public String toString()
Deprecated. 
Overrides:
toString in class Object
See Also:
Object.toString()

readFields

public void readFields(DataInput in)
                throws IOException
Deprecated. 
Specified by:
readFields in interface org.apache.hadoop.io.Writable
Throws:
IOException

write

public void write(DataOutput out)
           throws IOException
Deprecated. 
Specified by:
write in interface org.apache.hadoop.io.Writable
Throws:
IOException

heapSize

public long heapSize()
Deprecated. 
Specified by:
heapSize in interface HeapSize
Returns:
Approximate 'exclusive deep size' of implementing object. Includes count of payload and hosting object sizings.


Copyright © 2010 The Apache Software Foundation