org.apache.hadoop.hive.serde2.columnar
Class ColumnarSerDe

java.lang.Object
  extended by org.apache.hadoop.hive.serde2.columnar.ColumnarSerDeBase
      extended by org.apache.hadoop.hive.serde2.columnar.ColumnarSerDe
All Implemented Interfaces:
Deserializer, SerDe, Serializer

public class ColumnarSerDe
extends ColumnarSerDeBase

ColumnarSerDe is used for columnar based storage supported by RCFile. ColumnarSerDe differentiate from LazySimpleSerDe in:
(1) ColumnarSerDe uses a ColumnarStruct as its lazy Object
(2) ColumnarSerDe initialize ColumnarStruct's field directly. But under the field level, it works like LazySimpleSerDe


Field Summary
static org.apache.commons.logging.Log LOG
           
 
Fields inherited from class org.apache.hadoop.hive.serde2.columnar.ColumnarSerDeBase
cachedObjectInspector, lastOperationDeserialize, lastOperationSerialize, serializedSize, stats
 
Constructor Summary
ColumnarSerDe()
           
 
Method Summary
 void initialize(org.apache.hadoop.conf.Configuration job, Properties tbl)
          Initialize the SerDe given the parameters.
 org.apache.hadoop.io.Writable serialize(Object obj, ObjectInspector objInspector)
          Serialize a row of data.
 String toString()
           
 
Methods inherited from class org.apache.hadoop.hive.serde2.columnar.ColumnarSerDeBase
deserialize, getObjectInspector, getSerDeStats, getSerializedClass, initialize
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Field Detail

LOG

public static final org.apache.commons.logging.Log LOG
Constructor Detail

ColumnarSerDe

public ColumnarSerDe()
              throws SerDeException
Throws:
SerDeException
Method Detail

toString

public String toString()
Overrides:
toString in class Object

initialize

public void initialize(org.apache.hadoop.conf.Configuration job,
                       Properties tbl)
                throws SerDeException
Initialize the SerDe given the parameters.

Parameters:
job - System properties
tbl - table properties
Throws:
SerDeException
See Also:
Deserializer.initialize(Configuration, Properties)

serialize

public org.apache.hadoop.io.Writable serialize(Object obj,
                                               ObjectInspector objInspector)
                                        throws SerDeException
Serialize a row of data.

Parameters:
obj - The row object
objInspector - The ObjectInspector for the row object
Returns:
The serialized Writable object
Throws:
SerDeException
See Also:
Serializer.serialize(Object, ObjectInspector)


Copyright © 2013 The Apache Software Foundation