org.apache.hadoop.hive.serde2.typeinfo
Class StructTypeInfo

java.lang.Object
  extended by org.apache.hadoop.hive.serde2.typeinfo.TypeInfo
      extended by org.apache.hadoop.hive.serde2.typeinfo.StructTypeInfo
All Implemented Interfaces:
Serializable

public class StructTypeInfo
extends TypeInfo
implements Serializable

StructTypeInfo represents the TypeInfo of a struct. A struct contains one or more fields each of which has a unique name and its own TypeInfo. Different fields can have the same or different TypeInfo. Always use the TypeInfoFactory to create new TypeInfo objects, instead of directly creating an instance of this class.

See Also:
Serialized Form

Constructor Summary
StructTypeInfo()
          For java serialization use only.
 
Method Summary
 boolean equals(Object other)
           
 ArrayList<String> getAllStructFieldNames()
           
 ArrayList<TypeInfo> getAllStructFieldTypeInfos()
           
 ObjectInspector.Category getCategory()
          The Category of this TypeInfo.
 TypeInfo getStructFieldTypeInfo(String field)
           
 String getTypeName()
          A String representation of the TypeInfo.
 int hashCode()
           
 void setAllStructFieldNames(ArrayList<String> allStructFieldNames)
          For java serialization use only.
 void setAllStructFieldTypeInfos(ArrayList<TypeInfo> allStructFieldTypeInfos)
          For java serialization use only.
 
Methods inherited from class org.apache.hadoop.hive.serde2.typeinfo.TypeInfo
toString
 
Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, wait, wait, wait
 

Constructor Detail

StructTypeInfo

public StructTypeInfo()
For java serialization use only.

Method Detail

getTypeName

public String getTypeName()
Description copied from class: TypeInfo
A String representation of the TypeInfo.

Specified by:
getTypeName in class TypeInfo

setAllStructFieldNames

public void setAllStructFieldNames(ArrayList<String> allStructFieldNames)
For java serialization use only.


setAllStructFieldTypeInfos

public void setAllStructFieldTypeInfos(ArrayList<TypeInfo> allStructFieldTypeInfos)
For java serialization use only.


getCategory

public ObjectInspector.Category getCategory()
Description copied from class: TypeInfo
The Category of this TypeInfo. Possible values are Primitive, List, Map and Struct, which corresponds to the 4 sub-classes of TypeInfo.

Specified by:
getCategory in class TypeInfo

getAllStructFieldNames

public ArrayList<String> getAllStructFieldNames()

getAllStructFieldTypeInfos

public ArrayList<TypeInfo> getAllStructFieldTypeInfos()

getStructFieldTypeInfo

public TypeInfo getStructFieldTypeInfo(String field)

equals

public boolean equals(Object other)
Overrides:
equals in class TypeInfo

hashCode

public int hashCode()
Overrides:
hashCode in class Object


Copyright © 2009 The Apache Software Foundation