org.apache.hadoop.hive.metastore.api
Class Table

java.lang.Object
  extended by org.apache.hadoop.hive.metastore.api.Table
All Implemented Interfaces:
Serializable, Cloneable, Comparable<Table>, org.apache.thrift.TBase<Table,Table._Fields>

public class Table
extends Object
implements org.apache.thrift.TBase<Table,Table._Fields>, Serializable, Cloneable

See Also:
Serialized Form

Nested Class Summary
static class Table._Fields
          The set of fields this struct contains, along with convenience methods for finding and manipulating them.
 
Field Summary
static Map<Table._Fields,org.apache.thrift.meta_data.FieldMetaData> metaDataMap
           
 
Constructor Summary
Table()
           
Table(String tableName, String dbName, String owner, int createTime, int lastAccessTime, int retention, StorageDescriptor sd, List<FieldSchema> partitionKeys, Map<String,String> parameters)
           
Table(Table other)
          Performs a deep copy on other.
 
Method Summary
 void addToPartitionKeys(FieldSchema elem)
           
 void clear()
           
 int compareTo(Table other)
           
 Table deepCopy()
           
 boolean equals(Object that)
           
 boolean equals(Table that)
           
 Table._Fields fieldForId(int fieldId)
           
 int getCreateTime()
           
 String getDbName()
           
 Object getFieldValue(Table._Fields field)
           
 int getLastAccessTime()
           
 String getOwner()
           
 Map<String,String> getParameters()
           
 int getParametersSize()
           
 List<FieldSchema> getPartitionKeys()
           
 Iterator<FieldSchema> getPartitionKeysIterator()
           
 int getPartitionKeysSize()
           
 int getRetention()
           
 StorageDescriptor getSd()
           
 String getTableName()
           
 int hashCode()
           
 boolean isSet(Table._Fields field)
          Returns true if field corresponding to fieldID is set (has been asigned a value) and false otherwise
 boolean isSetCreateTime()
          Returns true if field createTime is set (has been asigned a value) and false otherwise
 boolean isSetDbName()
          Returns true if field dbName is set (has been asigned a value) and false otherwise
 boolean isSetLastAccessTime()
          Returns true if field lastAccessTime is set (has been asigned a value) and false otherwise
 boolean isSetOwner()
          Returns true if field owner is set (has been asigned a value) and false otherwise
 boolean isSetParameters()
          Returns true if field parameters is set (has been asigned a value) and false otherwise
 boolean isSetPartitionKeys()
          Returns true if field partitionKeys is set (has been asigned a value) and false otherwise
 boolean isSetRetention()
          Returns true if field retention is set (has been asigned a value) and false otherwise
 boolean isSetSd()
          Returns true if field sd is set (has been asigned a value) and false otherwise
 boolean isSetTableName()
          Returns true if field tableName is set (has been asigned a value) and false otherwise
 void putToParameters(String key, String val)
           
 void read(org.apache.thrift.protocol.TProtocol iprot)
           
 void setCreateTime(int createTime)
           
 void setCreateTimeIsSet(boolean value)
           
 void setDbName(String dbName)
           
 void setDbNameIsSet(boolean value)
           
 void setFieldValue(Table._Fields field, Object value)
           
 void setLastAccessTime(int lastAccessTime)
           
 void setLastAccessTimeIsSet(boolean value)
           
 void setOwner(String owner)
           
 void setOwnerIsSet(boolean value)
           
 void setParameters(Map<String,String> parameters)
           
 void setParametersIsSet(boolean value)
           
 void setPartitionKeys(List<FieldSchema> partitionKeys)
           
 void setPartitionKeysIsSet(boolean value)
           
 void setRetention(int retention)
           
 void setRetentionIsSet(boolean value)
           
 void setSd(StorageDescriptor sd)
           
 void setSdIsSet(boolean value)
           
 void setTableName(String tableName)
           
 void setTableNameIsSet(boolean value)
           
 String toString()
           
 void unsetCreateTime()
           
 void unsetDbName()
           
 void unsetLastAccessTime()
           
 void unsetOwner()
           
 void unsetParameters()
           
 void unsetPartitionKeys()
           
 void unsetRetention()
           
 void unsetSd()
           
 void unsetTableName()
           
 void validate()
           
 void write(org.apache.thrift.protocol.TProtocol oprot)
           
 
Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, wait, wait, wait
 

Field Detail

metaDataMap

public static final Map<Table._Fields,org.apache.thrift.meta_data.FieldMetaData> metaDataMap
Constructor Detail

Table

public Table()

Table

public Table(String tableName,
             String dbName,
             String owner,
             int createTime,
             int lastAccessTime,
             int retention,
             StorageDescriptor sd,
             List<FieldSchema> partitionKeys,
             Map<String,String> parameters)

Table

public Table(Table other)
Performs a deep copy on other.

Method Detail

deepCopy

public Table deepCopy()
Specified by:
deepCopy in interface org.apache.thrift.TBase<Table,Table._Fields>

clear

public void clear()
Specified by:
clear in interface org.apache.thrift.TBase<Table,Table._Fields>

getTableName

public String getTableName()

setTableName

public void setTableName(String tableName)

unsetTableName

public void unsetTableName()

isSetTableName

public boolean isSetTableName()
Returns true if field tableName is set (has been asigned a value) and false otherwise


setTableNameIsSet

public void setTableNameIsSet(boolean value)

getDbName

public String getDbName()

setDbName

public void setDbName(String dbName)

unsetDbName

public void unsetDbName()

isSetDbName

public boolean isSetDbName()
Returns true if field dbName is set (has been asigned a value) and false otherwise


setDbNameIsSet

public void setDbNameIsSet(boolean value)

getOwner

public String getOwner()

setOwner

public void setOwner(String owner)

unsetOwner

public void unsetOwner()

isSetOwner

public boolean isSetOwner()
Returns true if field owner is set (has been asigned a value) and false otherwise


setOwnerIsSet

public void setOwnerIsSet(boolean value)

getCreateTime

public int getCreateTime()

setCreateTime

public void setCreateTime(int createTime)

unsetCreateTime

public void unsetCreateTime()

isSetCreateTime

public boolean isSetCreateTime()
Returns true if field createTime is set (has been asigned a value) and false otherwise


setCreateTimeIsSet

public void setCreateTimeIsSet(boolean value)

getLastAccessTime

public int getLastAccessTime()

setLastAccessTime

public void setLastAccessTime(int lastAccessTime)

unsetLastAccessTime

public void unsetLastAccessTime()

isSetLastAccessTime

public boolean isSetLastAccessTime()
Returns true if field lastAccessTime is set (has been asigned a value) and false otherwise


setLastAccessTimeIsSet

public void setLastAccessTimeIsSet(boolean value)

getRetention

public int getRetention()

setRetention

public void setRetention(int retention)

unsetRetention

public void unsetRetention()

isSetRetention

public boolean isSetRetention()
Returns true if field retention is set (has been asigned a value) and false otherwise


setRetentionIsSet

public void setRetentionIsSet(boolean value)

getSd

public StorageDescriptor getSd()

setSd

public void setSd(StorageDescriptor sd)

unsetSd

public void unsetSd()

isSetSd

public boolean isSetSd()
Returns true if field sd is set (has been asigned a value) and false otherwise


setSdIsSet

public void setSdIsSet(boolean value)

getPartitionKeysSize

public int getPartitionKeysSize()

getPartitionKeysIterator

public Iterator<FieldSchema> getPartitionKeysIterator()

addToPartitionKeys

public void addToPartitionKeys(FieldSchema elem)

getPartitionKeys

public List<FieldSchema> getPartitionKeys()

setPartitionKeys

public void setPartitionKeys(List<FieldSchema> partitionKeys)

unsetPartitionKeys

public void unsetPartitionKeys()

isSetPartitionKeys

public boolean isSetPartitionKeys()
Returns true if field partitionKeys is set (has been asigned a value) and false otherwise


setPartitionKeysIsSet

public void setPartitionKeysIsSet(boolean value)

getParametersSize

public int getParametersSize()

putToParameters

public void putToParameters(String key,
                            String val)

getParameters

public Map<String,String> getParameters()

setParameters

public void setParameters(Map<String,String> parameters)

unsetParameters

public void unsetParameters()

isSetParameters

public boolean isSetParameters()
Returns true if field parameters is set (has been asigned a value) and false otherwise


setParametersIsSet

public void setParametersIsSet(boolean value)

setFieldValue

public void setFieldValue(Table._Fields field,
                          Object value)
Specified by:
setFieldValue in interface org.apache.thrift.TBase<Table,Table._Fields>

getFieldValue

public Object getFieldValue(Table._Fields field)
Specified by:
getFieldValue in interface org.apache.thrift.TBase<Table,Table._Fields>

isSet

public boolean isSet(Table._Fields field)
Returns true if field corresponding to fieldID is set (has been asigned a value) and false otherwise

Specified by:
isSet in interface org.apache.thrift.TBase<Table,Table._Fields>

equals

public boolean equals(Object that)
Overrides:
equals in class Object

equals

public boolean equals(Table that)

hashCode

public int hashCode()
Overrides:
hashCode in class Object

compareTo

public int compareTo(Table other)
Specified by:
compareTo in interface Comparable<Table>

fieldForId

public Table._Fields fieldForId(int fieldId)
Specified by:
fieldForId in interface org.apache.thrift.TBase<Table,Table._Fields>

read

public void read(org.apache.thrift.protocol.TProtocol iprot)
          throws org.apache.thrift.TException
Specified by:
read in interface org.apache.thrift.TBase<Table,Table._Fields>
Throws:
org.apache.thrift.TException

write

public void write(org.apache.thrift.protocol.TProtocol oprot)
           throws org.apache.thrift.TException
Specified by:
write in interface org.apache.thrift.TBase<Table,Table._Fields>
Throws:
org.apache.thrift.TException

toString

public String toString()
Overrides:
toString in class Object

validate

public void validate()
              throws org.apache.thrift.TException
Throws:
org.apache.thrift.TException


Copyright © 2009 The Apache Software Foundation