|
|||||||||
| 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
public abstract class 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 | |
|---|---|
static java.lang.String |
suffixForIntermediateViews
|
| 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. |
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 Columnsets. |
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 java.lang.String |
handleExtraOutputFeature(Feature outputFeature,
Columnset csForOutputConcept)
Abstract method to deal with output features for which there is no corresponding input feature. |
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 |
| Field Detail |
|---|
public static final java.lang.String suffixForIntermediateViews
| Constructor Detail |
|---|
public ConceptOperator()
| Method Detail |
|---|
public void compileStatement()
throws java.sql.SQLException,
M4CompilerWarning,
M4CompilerError
compileStatement in class ExecutableOperatorjava.sql.SQLException
M4CompilerWarning
M4CompilerErroredu.udo.cs.miningmart.operator.Operator#compileStatement
public void createStatement(boolean lazy)
throws M4CompilerError,
M4CompilerWarning
createStatement in class ExecutableOperatorlazy - If TRUE, run in lazy mode: create atmost one output
ColumnSet
M4CompilerError
M4CompilerWarningedu.udo.cs.miningmart.operator.Operator#createStatement
public abstract Columnset[] generateColumnSetsForOp(boolean lazy)
throws M4CompilerError,
M4CompilerWarning
M4CompilerError
M4CompilerWarning
public Concept getInputConcept()
throws M4CompilerError
M4CompilerError
public Concept getOutputConcept()
throws M4CompilerError
M4CompilerError
protected Columnset createSingleColumnSet(int index)
throws M4CompilerError,
M4CompilerWarning
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
M4CompilerWarning
protected void setNewCSMultiStepBranch(Columnset newCS,
int index)
throws M4CompilerError
newCS - the Columnset that is created by this operatorindex - An index for MulipleCSOperators.
M4CompilerErrorpublic 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 abstract java.lang.String handleExtraOutputFeature(Feature outputFeature,
Columnset csForOutputConcept)
throws M4CompilerError
outputFeature - Feature to be dealt withcsForOutputConcept - Columnset that was created for the output concept
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 conceptThe - so-far created String for the Select part of the SQL statement
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 conceptThe - so-far created String for the Select part of the SQL statement
M4CompilerErrorprotected java.lang.String getStringForSelection(Column inputColumn)
inputColumn - the given input column
public java.lang.String getNewCSName(int index)
throws M4CompilerError
Columnsets.
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 Cases intermediate
results of one Case could be overwritten by another.
the - index of the columnset to get the name for.
-1 specifies, that only a single columnset is created.
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,
M4CompilerWarning
selectPart - The String for the SELECT-part of the SQL definition to
be created.index - An index for MultipleCSOperators.
M4CompilerError
M4CompilerWarning
|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||