org.eigenbase.reltype
Class RelDataTypeFactory.ListFieldInfo

java.lang.Object
  extended by org.eigenbase.reltype.RelDataTypeFactory.ListFieldInfo
All Implemented Interfaces:
RelDataTypeFactory.FieldInfo
Enclosing interface:
RelDataTypeFactory

public static class RelDataTypeFactory.ListFieldInfo
extends Object
implements RelDataTypeFactory.FieldInfo

Simple implementation of RelDataTypeFactory.FieldInfo, based on a list of fields.


Field Summary
private  List<? extends RelDataTypeField> fieldList
           
 
Constructor Summary
RelDataTypeFactory.ListFieldInfo(List<? extends RelDataTypeField> fieldList)
          Creates a ListFieldInfo.
 
Method Summary
 int getFieldCount()
          Returns the number of fields.
 String getFieldName(int index)
          Returns the name of a given field.
 RelDataType getFieldType(int index)
          Returns the type of a given field.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

fieldList

private final List<? extends RelDataTypeField> fieldList
Constructor Detail

RelDataTypeFactory.ListFieldInfo

public RelDataTypeFactory.ListFieldInfo(List<? extends RelDataTypeField> fieldList)
Creates a ListFieldInfo.

Parameters:
fieldList - List of fields
Method Detail

getFieldCount

public int getFieldCount()
Description copied from interface: RelDataTypeFactory.FieldInfo
Returns the number of fields.

Specified by:
getFieldCount in interface RelDataTypeFactory.FieldInfo
Returns:
number of fields

getFieldName

public String getFieldName(int index)
Description copied from interface: RelDataTypeFactory.FieldInfo
Returns the name of a given field.

Specified by:
getFieldName in interface RelDataTypeFactory.FieldInfo
Parameters:
index - Ordinal of field
Returns:
Name of given field

getFieldType

public RelDataType getFieldType(int index)
Description copied from interface: RelDataTypeFactory.FieldInfo
Returns the type of a given field.

Specified by:
getFieldType in interface RelDataTypeFactory.FieldInfo
Parameters:
index - Ordinal of field
Returns:
Type of given field