org.apache.pig
Class SortColInfo

java.lang.Object
  extended by org.apache.pig.SortColInfo
All Implemented Interfaces:
Serializable

@InterfaceAudience.Private
@InterfaceStability.Unstable
public class SortColInfo
extends Object
implements Serializable

A class representing information about a sort column in SortInfo

See Also:
Serialized Form

Nested Class Summary
static class SortColInfo.Order
           
 
Constructor Summary
SortColInfo(String colName, int colIndex, SortColInfo.Order orderingType)
           
 
Method Summary
 boolean equals(Object obj)
           
 int getColIndex()
           
 String getColName()
           
 SortColInfo.Order getSortOrder()
           
 int hashCode()
           
 String toString()
           
 
Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, wait, wait, wait
 

Constructor Detail

SortColInfo

public SortColInfo(String colName,
                   int colIndex,
                   SortColInfo.Order orderingType)
Parameters:
colName - sort column name
colIndex - index position (0 based) of sort column
orderingType - whether the column is sorted ascending or descending
Method Detail

getColName

public String getColName()
Returns:
the sort column name - could be null or empty string if column name could not be determined either because of the absence of a schema or because the schema had the column name as null or empty string - caller should check for these conditions.

getColIndex

public int getColIndex()
Returns:
index position (0 based) of sort column

getSortOrder

public SortColInfo.Order getSortOrder()
Returns:
whether the column is sorted ascending or descending

hashCode

public int hashCode()
Overrides:
hashCode in class Object

equals

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

toString

public String toString()
Overrides:
toString in class Object


Copyright © 2007-2012 The Apache Software Foundation