|
|||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||||
java.lang.Object
|
+--quoggles.boxes.Box
|
+--quoggles.stdboxes.subquery.SubQuery_Box
Input: depends on the loaded sub query
Output: depends on the loaded sub query
Allows specification of a file that contains a saved query. The box then represents this whole loaded query. Parameters of the query cannot be changed.
| Field Summary | |
private java.util.List |
currentResult
The current result table. |
(package private) org.graffiti.plugin.parameter.StringParameter |
fileNameParam
|
(package private) org.graffiti.plugin.parameter.ObjectParameter |
graphParam
|
private java.util.List |
inputBoxAndNumber
A list of Pairs (of boxes that need inputs and the index
where the box needs the input). |
private int[] |
inputTypes
|
private java.util.List |
outputBoxAndNumber
A list of Pairs (of boxes that yield outputs and the index
where the box's output is). |
private int[] |
outputTypes
|
private RunQuery |
queryRunner
|
private org.graffiti.graph.Graph |
subQueryGraph
Graüh holding the sub query |
| Fields inherited from class quoggles.boxes.Box |
boxExecuted, iBoxGRep, inputs, outputs, parameters |
| Constructor Summary | |
SubQuery_Box()
Constructs the box. |
|
| Method Summary | |
void |
execute()
Should be overridden and called first by subclasses. |
IBoxRepresentation |
getGraphicalRepresentation()
This implementation returns a new instance of DefaultBoxRepresentation.
|
int[] |
getInputTypes()
This implementation returns ONE element, the most general type. |
int[] |
getOutputTypes()
Override this method to specify more restricted types for the output(s) of the box. |
boolean |
needsQueryRunner()
Returns true. |
void |
setCurrentResult(java.util.List res)
Empty implementation. |
void |
setParameters(org.graffiti.plugin.parameter.Parameter[] pars,
boolean fromRep)
Sets the parameters and - if needed - sets them in the graphical representation. |
void |
setQueryRunner(RunQuery qr)
Empty implementation. |
| Methods inherited from class quoggles.boxes.Box |
areAllInputsNull, getClassName, getId, getNode, getNumberOfInputs, getNumberOfOutputs, getOutputAt, getOutputs, getParameters, hasBeenExecuted, ignoreBox, isGraphicalRepNull, isInputSet, isInputSetAt, removeNullValues, reset, reset, setBoxNumber, setCurrentNodesTodo, setDefaultParameters, setIgnoreBox, setInputAt, setInputs, setNode |
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Field Detail |
org.graffiti.plugin.parameter.StringParameter fileNameParam
org.graffiti.plugin.parameter.ObjectParameter graphParam
private int[] inputTypes
private int[] outputTypes
private org.graffiti.graph.Graph subQueryGraph
private java.util.List inputBoxAndNumber
Pairs (of boxes that need inputs and the index
where the box needs the input).
private java.util.List outputBoxAndNumber
Pairs (of boxes that yield outputs and the index
where the box's output is).
private RunQuery queryRunner
private java.util.List currentResult
| Constructor Detail |
public SubQuery_Box()
| Method Detail |
public void execute()
throws QueryExecutionException
BoxInputNotSetException if the inputSet
flag indicates the no input has been set for this box.
May throw other QueryExecutionExceptions.
The implementation of this abstract sets the output to be equal to the
input.
execute in interface IBoxexecute in class BoxQueryExecutionExceptionIBox.execute()
public void setParameters(org.graffiti.plugin.parameter.Parameter[] pars,
boolean fromRep)
Boxparameters.
setParameters in interface IBoxsetParameters in class BoxIBox.setParameters(org.graffiti.plugin.parameter.Parameter[], boolean)public IBoxRepresentation getGraphicalRepresentation()
BoxDefaultBoxRepresentation.
If your subclass has any parameters, you will probably have to design
your own representation and override this method for example as follows:
if (iBoxGRep == null || !(iBoxGRep instanceof MYOWNBOX_Rep)) {
iBoxGRep = new MYOWNBOX_Rep(this);
}
return iBoxGRep;
getGraphicalRepresentation in interface IBoxgetGraphicalRepresentation in class BoxIBox.getGraphicalRepresentation()public int[] getInputTypes()
BoxgetNumberOfInputs.
getInputTypes in interface IBoxgetInputTypes in class BoxIBox.getInputTypes()public int[] getOutputTypes()
BoxgetNumberOfOutputs.
This implementation returns the same as a call to
getInputTypes yields.
getOutputTypes in interface IBoxgetOutputTypes in class BoxIBox.getOutputTypes()public boolean needsQueryRunner()
true.
needsQueryRunner in interface IBoxneedsQueryRunner in class Boxquoggles.boxes.IBox#neeedsQueryRunner()public void setQueryRunner(RunQuery qr)
Box
setQueryRunner in interface IBoxsetQueryRunner in class BoxIBox.setQueryRunner(quoggles.auxiliary.RunQuery)public void setCurrentResult(java.util.List res)
Box
setCurrentResult in interface IBoxsetCurrentResult in class BoxIBox.setCurrentResult(java.util.List)
|
|||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||||