|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectedu.udo.cs.miningmart.operator.ExecutableOperator
edu.udo.cs.miningmart.operator.ConceptOperator
This abstract class is the superclass for all operators whose output is a
concept. Operators of this type must produce at least one ColumnSet for the
output concept. The parameters "TheInputConcept" and "TheOutputConcept" are
provided by this class and are inherited by subclasses (using the methods
getInputConcept()
and getOutputConcept()
).
SingleCSOperator
,
MultipleCSOperator
Field Summary |
Fields inherited from class edu.udo.cs.miningmart.operator.ExecutableOperator |
generatedSQLDefinitions |
Constructor Summary | |
ConceptOperator()
|
Method Summary | |
void |
compileStatement()
Method for compiling the generated sql-statement. |
protected java.lang.String |
createMetadata(Feature inF,
Feature outF,
Columnset csForOutputConcept,
java.lang.String columnExpr)
Copy the metadata for all the BAs in the input feature to the output feature. |
protected java.lang.String |
createMetadataForOneBA(BaseAttribute inBA,
BaseAttribute outBA,
Columnset csForOutputConcept,
java.lang.String columnExpr)
Copy the metadata from the given input BA to the given output BA. |
protected Columnset |
createSingleColumnSet(int index)
Since all operators of this type (ConceptOperator) create columnsets, they can use this method to do so. |
void |
createStatement(boolean lazy)
Method for generating a sql-statement. |
EstimatedStatistics |
estimateStatistics(Step theStep)
Abstract method for estimating statistics for a concept. |
protected java.lang.String |
generateColumns(Columnset csForOutputConcept)
This method creates new Columns for the given Columnset, one for each Feature of this operator's output concept, if the method "mustCopyFeature()" for this Feature returns TRUE. |
abstract Columnset[] |
generateColumnSetsForOp(boolean lazy)
Abstract method to be implemented by subclasses. |
abstract java.lang.String |
generateSQLDefinition(java.lang.String selectPart,
int index)
This method must return the SQL definition of the newly created ColumnSet. |
Concept |
getInputConcept()
This method provides TheInputConcept for this operator. |
java.lang.String |
getNewCSName(int index)
This method is used to generate the name for new Columnset s.
|
Concept |
getOutputConcept()
This method provides TheOutputConcept for this operator. |
protected java.lang.String |
getStringForSelection(Column inputColumn)
This method returns a String to be used in the SELECT part of a view definition. |
abstract java.lang.String |
getTypeOfNewColumnSet(int index)
This method must return the entry String for the M4 table "Columnset_t", indicating whether the new Columnset is a view or a table. |
protected abstract boolean |
mustCopyFeature(java.lang.String nameOfFeature)
This method is for operators that do not copy all Features of the input concept to the output concept. |
protected void |
setNewCSMultiStepBranch(Columnset newCS,
int index)
Set the information about the multistep branch into the Columnset that is created by this operator. |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
public ConceptOperator()
Method Detail |
public void compileStatement() throws java.sql.SQLException, M4CompilerWarning, M4CompilerError
compileStatement
in class ExecutableOperator
java.sql.SQLException
M4CompilerWarning
M4CompilerError
edu.udo.cs.miningmart.operator.Operator#compileStatement
public void createStatement(boolean lazy) throws M4CompilerError, M4CompilerWarning
createStatement
in class ExecutableOperator
lazy
- If TRUE, run in lazy mode: create atmost one output
ColumnSet
M4CompilerError
M4CompilerWarning
edu.udo.cs.miningmart.operator.Operator#createStatement
public EstimatedStatistics estimateStatistics(Step theStep) throws M4Exception
ExecutableOperator
estimateStatistics
in class ExecutableOperator
theStep
- the step that creates the output concept whose statistics
are to be estimated
EstimatedStatistics
object, some of whose values
may or may not be available, depending on whether they could be guessed
or inferred.
M4Exception
ExecutableOperator.estimateStatistics(Step)
public abstract Columnset[] generateColumnSetsForOp(boolean lazy) throws M4CompilerError
M4CompilerError
public Concept getInputConcept() throws M4CompilerError
M4CompilerError
public Concept getOutputConcept() throws M4CompilerError
M4CompilerError
protected Columnset createSingleColumnSet(int index) throws M4CompilerError
generateSQLDefinition()
,
to be implemented by subclasses, to find the SQL String for the new columnset.
This method may be overridden by some subclasses.
index
- For MultipleCSOperators, the number of the columnset to be
created, starting with 0. For SingleCSOperators, this parameter must
be -1.
M4CompilerError
protected void setNewCSMultiStepBranch(Columnset newCS, int index) throws M4CompilerError
newCS
- the Columnset that is created by this operatorindex
- An index for MulipleCSOperators.
M4CompilerError
public abstract java.lang.String getTypeOfNewColumnSet(int index)
index
- An index for MulipleCSOperators.
protected java.lang.String generateColumns(Columnset csForOutputConcept) throws M4CompilerError
csForOutputConcept
- The ColumnSet for which Columns are to be produced.
M4CompilerError
protected java.lang.String createMetadata(Feature inF, Feature outF, Columnset csForOutputConcept, java.lang.String columnExpr) throws M4CompilerError
inF
- A Feature from the input conceptoutF
- The corresponding Feature from the output conceptcsForOutputConcept
- The current Columnset from the output concept
M4CompilerError
protected java.lang.String createMetadataForOneBA(BaseAttribute inBA, BaseAttribute outBA, Columnset csForOutputConcept, java.lang.String columnExpr) throws M4CompilerError
inBA
- A BaseAttribute from the input conceptoutBA
- The corresponding BaseAttribute from the output conceptcsForOutputConcept
- The current Columnset from the output concept
M4CompilerError
protected java.lang.String getStringForSelection(Column inputColumn)
inputColumn
- the given input column
public java.lang.String getNewCSName(int index) throws M4CompilerError
Columnset
s.
If an operator needs to generate specific names, this method should be
overwritten.
The index may be used to signal, that this operator creates more than one
Columnset
, so a suffix needs to be part of the name.
The Step
ID should always be part of the name, because
otherwise during parallel execution of Case
s intermediate
results of one Case
could be overwritten by another.
M4CompilerError
protected abstract boolean mustCopyFeature(java.lang.String nameOfFeature) throws M4CompilerError
nameOfFeature
- Name of the feature in question.
M4CompilerError
public abstract java.lang.String generateSQLDefinition(java.lang.String selectPart, int index) throws M4CompilerError
selectPart
- The String for the SELECT-part of the SQL definition to
be created.index
- An index for MultipleCSOperators.
M4CompilerError
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |