org.apache.hadoop.hive.serde2.objectinspector.primitive
Class WritableBinaryObjectInspector

java.lang.Object
  extended by org.apache.hadoop.hive.serde2.objectinspector.primitive.AbstractPrimitiveObjectInspector
      extended by org.apache.hadoop.hive.serde2.objectinspector.primitive.AbstractPrimitiveWritableObjectInspector
          extended by org.apache.hadoop.hive.serde2.objectinspector.primitive.WritableBinaryObjectInspector
All Implemented Interfaces:
Cloneable, ObjectInspector, BinaryObjectInspector, SettableBinaryObjectInspector, PrimitiveObjectInspector

public class WritableBinaryObjectInspector
extends AbstractPrimitiveWritableObjectInspector
implements SettableBinaryObjectInspector


Nested Class Summary
 
Nested classes/interfaces inherited from interface org.apache.hadoop.hive.serde2.objectinspector.PrimitiveObjectInspector
PrimitiveObjectInspector.PrimitiveCategory
 
Nested classes/interfaces inherited from interface org.apache.hadoop.hive.serde2.objectinspector.ObjectInspector
ObjectInspector.Category
 
Method Summary
 org.apache.hadoop.io.BytesWritable copyObject(Object o)
          Get a copy of the Object in the same class, so the return value can be stored independently of the parameter.
 org.apache.hadoop.io.BytesWritable create(ByteArrayRef bb)
           
 org.apache.hadoop.io.BytesWritable create(org.apache.hadoop.io.BytesWritable bw)
           
 ByteArrayRef getPrimitiveJavaObject(Object o)
          Get the Java Primitive object.
 org.apache.hadoop.io.BytesWritable getPrimitiveWritableObject(Object o)
          Return the data in an instance of primitive writable Object.
 org.apache.hadoop.io.BytesWritable set(Object o, ByteArrayRef bb)
           
 org.apache.hadoop.io.BytesWritable set(Object o, org.apache.hadoop.io.BytesWritable bw)
           
 
Methods inherited from class org.apache.hadoop.hive.serde2.objectinspector.primitive.AbstractPrimitiveWritableObjectInspector
preferWritable
 
Methods inherited from class org.apache.hadoop.hive.serde2.objectinspector.primitive.AbstractPrimitiveObjectInspector
getCategory, getJavaPrimitiveClass, getPrimitiveCategory, getPrimitiveWritableClass, getTypeName
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 
Methods inherited from interface org.apache.hadoop.hive.serde2.objectinspector.PrimitiveObjectInspector
getJavaPrimitiveClass, getPrimitiveCategory, getPrimitiveWritableClass, preferWritable
 
Methods inherited from interface org.apache.hadoop.hive.serde2.objectinspector.ObjectInspector
getCategory, getTypeName
 

Method Detail

copyObject

public org.apache.hadoop.io.BytesWritable copyObject(Object o)
Description copied from interface: PrimitiveObjectInspector
Get a copy of the Object in the same class, so the return value can be stored independently of the parameter. If the Object is a Primitive Java Object, we just return the parameter since Primitive Java Object is immutable.

Specified by:
copyObject in interface PrimitiveObjectInspector

getPrimitiveJavaObject

public ByteArrayRef getPrimitiveJavaObject(Object o)
Description copied from interface: PrimitiveObjectInspector
Get the Java Primitive object.

Specified by:
getPrimitiveJavaObject in interface BinaryObjectInspector
Specified by:
getPrimitiveJavaObject in interface PrimitiveObjectInspector

getPrimitiveWritableObject

public org.apache.hadoop.io.BytesWritable getPrimitiveWritableObject(Object o)
Description copied from interface: PrimitiveObjectInspector
Return the data in an instance of primitive writable Object. If the Object is already a primitive writable Object, just return o.

Specified by:
getPrimitiveWritableObject in interface BinaryObjectInspector
Specified by:
getPrimitiveWritableObject in interface PrimitiveObjectInspector
Overrides:
getPrimitiveWritableObject in class AbstractPrimitiveWritableObjectInspector

set

public org.apache.hadoop.io.BytesWritable set(Object o,
                                              ByteArrayRef bb)
Specified by:
set in interface SettableBinaryObjectInspector

set

public org.apache.hadoop.io.BytesWritable set(Object o,
                                              org.apache.hadoop.io.BytesWritable bw)
Specified by:
set in interface SettableBinaryObjectInspector

create

public org.apache.hadoop.io.BytesWritable create(ByteArrayRef bb)
Specified by:
create in interface SettableBinaryObjectInspector

create

public org.apache.hadoop.io.BytesWritable create(org.apache.hadoop.io.BytesWritable bw)
Specified by:
create in interface SettableBinaryObjectInspector


Copyright © 2011 The Apache Software Foundation