|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object org.eigenbase.relopt.RelOptAbstractTable net.sf.farrago.namespace.impl.MedAbstractColumnSet net.sf.farrago.namespace.flatfile.FlatFileColumnSet
class FlatFileColumnSet
FlatFileColumnSet provides a flatfile implementation of the FarragoMedColumnSet
interface.
Field Summary | |
---|---|
(package private) String |
filePath
|
(package private) String |
logFilePath
|
(package private) long |
numRows
|
(package private) FlatFileParams |
params
|
static String |
PROP_FILENAME
|
static String |
PROP_LOG_FILENAME
|
(package private) FlatFileParams.SchemaType |
schemaType
|
private static String |
TIMESTAMP_FORMAT
|
private static String |
TIMESTAMP_PREFIX
|
Fields inherited from class org.eigenbase.relopt.RelOptAbstractTable |
---|
name, rowType, schema |
Constructor Summary | |
---|---|
FlatFileColumnSet(String[] localName,
RelDataType rowType,
FlatFileParams params,
Properties tableProps,
long numRows,
FlatFileParams.SchemaType schemaType)
|
Method Summary | |
---|---|
String |
getFilePath()
|
String |
getLogFilePath()
|
FlatFileParams |
getParams()
|
double |
getRowCount()
Returns an estimate of the number of rows in the table. |
private String |
makeFilePath(String[] localName,
String filename)
Constructs the full path to the file for a table, based upon the server directory, filename option (if specified), and the server data file extension. |
private String |
makeLogFilePath(String logFilename)
Constructs the full path to the log file for a table. |
private CalcRel |
newCalcRel(RelOptCluster cluster,
FennelRel child,
RexProgram program)
Constructs a new CalcRel |
private FennelRel |
newFennelRel(RelOptCluster cluster,
RelOptConnection connection,
FlatFileParams.SchemaType schemaType,
RelDataType rowType)
Constructs a new FlatFileFennelRel |
RelNode |
toRel(RelOptCluster cluster,
RelOptConnection connection)
Converts this table into a relational expression . |
Methods inherited from class net.sf.farrago.namespace.impl.MedAbstractColumnSet |
---|
getAllowedAccess, getColumnPropertyMap, getCwmColumnSet, getForeignName, getLocalName, getMonotonicity, getPreparingStmt, getQualifiedName, getTableProperties, setAllowedAccess, setCwmColumnSet, setPreparingStmt, toLenientRel, toUdxRel |
Methods inherited from class org.eigenbase.relopt.RelOptAbstractTable |
---|
getCollationList, getName, getRelOptSchema, getRowType, setRowType |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Methods inherited from interface org.eigenbase.relopt.RelOptTable |
---|
getCollationList, getRelOptSchema, getRowType |
Methods inherited from interface org.eigenbase.sql.validate.SqlValidatorTable |
---|
getRowType |
Field Detail |
---|
public static final String PROP_FILENAME
public static final String PROP_LOG_FILENAME
private static final String TIMESTAMP_PREFIX
private static final String TIMESTAMP_FORMAT
FlatFileParams params
String filePath
String logFilePath
FlatFileParams.SchemaType schemaType
long numRows
Constructor Detail |
---|
FlatFileColumnSet(String[] localName, RelDataType rowType, FlatFileParams params, Properties tableProps, long numRows, FlatFileParams.SchemaType schemaType)
Method Detail |
---|
public FlatFileParams getParams()
public String getFilePath()
public String getLogFilePath()
public double getRowCount()
RelOptTable
getRowCount
in interface RelOptTable
getRowCount
in class RelOptAbstractTable
public RelNode toRel(RelOptCluster cluster, RelOptConnection connection)
RelOptTable
relational expression
.
The planner
calls this
method to convert a table into an initial relational expression,
generally something abstract, such as a TableAccessRel
, then optimizes this expression by
applying rules
to transform it
into more efficient access methods for this table.
cluster
- the cluster the relational expression will belong toconnection
- the parse tree of the expression which evaluates to a
connection objectprivate FennelRel newFennelRel(RelOptCluster cluster, RelOptConnection connection, FlatFileParams.SchemaType schemaType, RelDataType rowType)
private CalcRel newCalcRel(RelOptCluster cluster, FennelRel child, RexProgram program)
private String makeFilePath(String[] localName, String filename)
localName
- name of the table within the catalogfilename
- name of the file, specified in parameters
private String makeLogFilePath(String logFilename)
Log files names are appended with a timestamp and have a .ERR extension rather than the data file extension.
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |