org.apache.hadoop.hive.ql.plan
Class alterTableDesc

java.lang.Object
  extended by org.apache.hadoop.hive.ql.plan.ddlDesc
      extended by org.apache.hadoop.hive.ql.plan.alterTableDesc
All Implemented Interfaces:
Serializable

public class alterTableDesc
extends ddlDesc
implements Serializable

See Also:
Serialized Form

Nested Class Summary
static class alterTableDesc.alterTableTypes
           
 
Constructor Summary
alterTableDesc(alterTableDesc.alterTableTypes alterType)
           
alterTableDesc(String tableName, int numBuckets, List<String> bucketCols, List<Order> sortCols)
           
alterTableDesc(String name, List<FieldSchema> newCols, alterTableDesc.alterTableTypes alterType)
           
alterTableDesc(String oldName, String newName)
           
alterTableDesc(String name, String inputFormat, String outputFormat, String serdeName)
           
alterTableDesc(String tblName, String oldColName, String newColName, String newType, String newComment, boolean first, String afterCol)
           
 
Method Summary
 String getAfterCol()
           
 String getAlterTableTypeString()
           
 List<String> getBucketColumns()
           
 boolean getFirst()
           
 String getInputFormat()
           
 String getNewColComment()
           
 String getNewColName()
           
 List<FieldSchema> getNewCols()
           
 List<String> getNewColsString()
           
 String getNewColType()
           
 String getNewName()
           
 int getNumberBuckets()
           
 String getOldColName()
           
 String getOldName()
           
 alterTableDesc.alterTableTypes getOp()
           
 String getOutputFormat()
           
 Map<String,String> getProps()
           
 String getSerdeName()
           
 List<Order> getSortColumns()
           
 void setAfterCol(String afterCol)
           
 void setBucketColumns(List<String> bucketColumns)
           
 void setFirst(boolean first)
           
 void setInputFormat(String inputFormat)
           
 void setNewColComment(String newComment)
           
 void setNewColName(String newColName)
           
 void setNewCols(List<FieldSchema> newCols)
           
 void setNewColType(String newType)
           
 void setNewName(String newName)
           
 void setNumberBuckets(int numberBuckets)
           
 void setOldColName(String oldColName)
           
 void setOldName(String oldName)
           
 void setOp(alterTableDesc.alterTableTypes op)
           
 void setOutputFormat(String outputFormat)
           
 void setProps(Map<String,String> props)
           
 void setSerdeName(String serdeName)
           
 void setSortColumns(List<Order> sortColumns)
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

alterTableDesc

public alterTableDesc(String tblName,
                      String oldColName,
                      String newColName,
                      String newType,
                      String newComment,
                      boolean first,
                      String afterCol)
Parameters:
tblName - table name
oldColName - old column name
newColName - new column name
newComment -
newType -

alterTableDesc

public alterTableDesc(String oldName,
                      String newName)
Parameters:
oldName - old name of the table
newName - new name of the table

alterTableDesc

public alterTableDesc(String name,
                      List<FieldSchema> newCols,
                      alterTableDesc.alterTableTypes alterType)
Parameters:
name - name of the table
newCols - new columns to be added

alterTableDesc

public alterTableDesc(alterTableDesc.alterTableTypes alterType)
Parameters:
alterType - type of alter op

alterTableDesc

public alterTableDesc(String name,
                      String inputFormat,
                      String outputFormat,
                      String serdeName)
Parameters:
name - name of the table
inputFormat - new table input format
outputFormat - new table output format

alterTableDesc

public alterTableDesc(String tableName,
                      int numBuckets,
                      List<String> bucketCols,
                      List<Order> sortCols)
Method Detail

getOldName

public String getOldName()
Returns:
the old name of the table

setOldName

public void setOldName(String oldName)
Parameters:
oldName - the oldName to set

getNewName

public String getNewName()
Returns:
the newName

setNewName

public void setNewName(String newName)
Parameters:
newName - the newName to set

getOp

public alterTableDesc.alterTableTypes getOp()
Returns:
the op

getAlterTableTypeString

public String getAlterTableTypeString()

setOp

public void setOp(alterTableDesc.alterTableTypes op)
Parameters:
op - the op to set

getNewCols

public List<FieldSchema> getNewCols()
Returns:
the newCols

getNewColsString

public List<String> getNewColsString()

setNewCols

public void setNewCols(List<FieldSchema> newCols)
Parameters:
newCols - the newCols to set

getSerdeName

public String getSerdeName()
Returns:
the serdeName

setSerdeName

public void setSerdeName(String serdeName)
Parameters:
serdeName - the serdeName to set

getProps

public Map<String,String> getProps()
Returns:
the props

setProps

public void setProps(Map<String,String> props)
Parameters:
props - the props to set

getInputFormat

public String getInputFormat()
Returns:
the input format

setInputFormat

public void setInputFormat(String inputFormat)
Parameters:
inputFormat - the input format to set

getOutputFormat

public String getOutputFormat()
Returns:
the output format

setOutputFormat

public void setOutputFormat(String outputFormat)
Parameters:
outputFormat - the output format to set

getNumberBuckets

public int getNumberBuckets()
Returns:
the number of buckets

setNumberBuckets

public void setNumberBuckets(int numberBuckets)
Parameters:
numberBuckets - the number of buckets to set

getBucketColumns

public List<String> getBucketColumns()
Returns:
the bucket columns

setBucketColumns

public void setBucketColumns(List<String> bucketColumns)
Parameters:
bucketColumns - the bucket columns to set

getSortColumns

public List<Order> getSortColumns()
Returns:
the sort columns

setSortColumns

public void setSortColumns(List<Order> sortColumns)
Parameters:
sortColumns - the sort columns to set

getOldColName

public String getOldColName()
Returns:
old column name

setOldColName

public void setOldColName(String oldColName)
Parameters:
oldColName - the old column name

getNewColName

public String getNewColName()
Returns:
new column name

setNewColName

public void setNewColName(String newColName)
Parameters:
newColName - the new column name

getNewColType

public String getNewColType()
Returns:
new column type

setNewColType

public void setNewColType(String newType)
Parameters:
newType - new column's type

getNewColComment

public String getNewColComment()
Returns:
new column's comment

setNewColComment

public void setNewColComment(String newComment)
Parameters:
newComment - new column's comment

getFirst

public boolean getFirst()
Returns:
if the column should be changed to position 0

setFirst

public void setFirst(boolean first)
Parameters:
first - set the column to position 0

getAfterCol

public String getAfterCol()
Returns:
the column's after position

setAfterCol

public void setAfterCol(String afterCol)
Parameters:
afterCol - set the column's after position


Copyright © 2009 The Apache Software Foundation