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

java.lang.Object
  extended by org.apache.hadoop.hive.serde2.objectinspector.primitive.AbstractPrimitiveObjectInspector
      extended by org.apache.hadoop.hive.serde2.objectinspector.primitive.AbstractPrimitiveWritableObjectInspector
All Implemented Interfaces:
Cloneable, ObjectInspector, PrimitiveObjectInspector, PrimitiveTypeSpec
Direct Known Subclasses:
WritableBinaryObjectInspector, WritableBooleanObjectInspector, WritableByteObjectInspector, WritableDateObjectInspector, WritableDoubleObjectInspector, WritableFloatObjectInspector, WritableHiveDecimalObjectInspector, WritableHiveVarcharObjectInspector, WritableIntObjectInspector, WritableLongObjectInspector, WritableShortObjectInspector, WritableStringObjectInspector, WritableTimestampObjectInspector, WritableVoidObjectInspector

public abstract class AbstractPrimitiveWritableObjectInspector
extends AbstractPrimitiveObjectInspector

An AbstractWritablePrimitiveObjectInspector for a Writable object.


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
 
Field Summary
 
Fields inherited from class org.apache.hadoop.hive.serde2.objectinspector.primitive.AbstractPrimitiveObjectInspector
typeParams
 
Constructor Summary
protected AbstractPrimitiveWritableObjectInspector(PrimitiveObjectInspectorUtils.PrimitiveTypeEntry typeEntry)
           
 
Method Summary
 Object getPrimitiveWritableObject(Object o)
          Return the data in an instance of primitive writable Object.
 boolean preferWritable()
          Whether the ObjectInspector prefers to return a Primitive Writable Object instead of a Primitive Java Object.
 
Methods inherited from class org.apache.hadoop.hive.serde2.objectinspector.primitive.AbstractPrimitiveObjectInspector
getCategory, getJavaPrimitiveClass, getPrimitiveCategory, getPrimitiveWritableClass, getTypeName, getTypeParams, setTypeParams
 
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
copyObject, getPrimitiveJavaObject
 

Constructor Detail

AbstractPrimitiveWritableObjectInspector

protected AbstractPrimitiveWritableObjectInspector(PrimitiveObjectInspectorUtils.PrimitiveTypeEntry typeEntry)
Method Detail

getPrimitiveWritableObject

public Object 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.


preferWritable

public boolean preferWritable()
Description copied from interface: PrimitiveObjectInspector
Whether the ObjectInspector prefers to return a Primitive Writable Object instead of a Primitive Java Object. This can be useful for determining the most efficient way to getting data out of the Object.



Copyright © 2012 The Apache Software Foundation