|
|||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||
SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object | +--operator
All operators extend this class (in reality all operators extend one of several classes for example operator1DInt that extend this class).
Field Summary | |
protected operatorBox |
box
The graphical representation of this operator on the UI. |
protected java.lang.String |
name
The unique name of the operator (for example convolution) |
protected javax.swing.JPanel |
panel
The panel that the operatorBox (representing the operator graphically on the UI) is placed on (this is the panel that is on the big scrollpane taking up most of the UI). |
protected javax.swing.JFrame |
parameters
The frame that contains the parameter window for this operator (made visible by clicking on the operator name in the operatorBox on th UI). |
protected java.lang.String |
type
The type of operator (for example convolution). |
Constructor Summary | |
operator()
|
Method Summary | |
protected operatorBox |
getBox()
Returns the graphical representation of the operator. |
java.lang.String |
getName()
Returns the name of the operator. |
javax.swing.JFrame |
getParameters()
Returns the parameters frame for this operator. |
java.lang.String |
getType()
Returns the type of this operator (for example convolution). |
abstract void |
go()
Runs the operator and then propagates the outputs to all operators that this operator links to. |
abstract void |
link1To1(operator linkOp)
Adds a link between this operator and another operator (output1 to input1). |
abstract void |
link1To2(operator linkOp)
Adds a link between this operator and another operator (output1 to input2). |
abstract void |
link2To1(operator linkOp)
Adds a link between this operator and another operator (output2 to input1). |
abstract void |
link2To2(operator linkOp)
Adds a link between this operator and another operator (output2 to input2). |
abstract void |
loadParameters(java.io.StreamTokenizer tokenizer)
|
void |
propagate()
Runs all the operators that this operator passes stuff to (all operators that are input linked to one of this operator's outputs). |
void |
propagateSingleLink(singleLink link)
Passes data from one of this operator's output to one of another operator's input (converting the image representation if necessary) and runs the next operator. |
java.lang.String |
saveOperator()
Returns a String representing the operator, containing all the information required to reconstruct this operator at a later date. |
abstract java.lang.String |
saveParameters()
Returns a String representing all the parameters for this operator for the purpose of saving the system setup (and being able to load it again at a future date). |
protected void |
setBox(javax.swing.JPanel panel,
linkData links,
int inputs,
int outputs)
Creates the box for the operator which is the graphical representation of the operator on the UI. |
abstract void |
setInput1(image x)
Sets input1 to the specified image. |
abstract void |
setInput2(image x)
Sets input2 to the specified image. |
void |
setName(java.lang.String name)
Sets the name of this operator. |
void |
setType(java.lang.String type)
|
void |
showParameters()
Makes the parameters window visible and deiconifies it if necessary. |
protected void |
updateParameters()
Lays out the parameters frame correctly. |
Methods inherited from class java.lang.Object |
clone,
equals,
finalize,
getClass,
hashCode,
notify,
notifyAll,
toString,
wait,
wait,
wait |
Field Detail |
protected javax.swing.JPanel panel
protected javax.swing.JFrame parameters
protected java.lang.String type
protected java.lang.String name
protected operatorBox box
Constructor Detail |
public operator()
Method Detail |
public java.lang.String saveOperator()
protected void setBox(javax.swing.JPanel panel, linkData links, int inputs, int outputs)
panel
- the panel that the box is to added tolinks
- the representation of the links between the operatorsinputs
- the number of inputs to the operator (1 or 2)outputs
- the number of outputs from the operator (1 or 2)protected operatorBox getBox()
public javax.swing.JFrame getParameters()
the
- parameters frame for this operatorprotected void updateParameters()
public void setName(java.lang.String name)
name
- of the operator to be usedpublic java.lang.String getName()
public void showParameters()
public void setType(java.lang.String type)
public java.lang.String getType()
public void propagate()
public void propagateSingleLink(singleLink link)
link
- the link that is to be usedpublic abstract void setInput1(image x)
x
- the image to be usedpublic abstract void setInput2(image x)
x
- the image to be usedpublic abstract void link1To1(operator linkOp)
linkOp
- the operator to be linked topublic abstract void link1To2(operator linkOp)
linkOp
- the operator to be linked topublic abstract void link2To1(operator linkOp)
linkOp
- the operator to be linked topublic abstract void link2To2(operator linkOp)
linkOp
- the operator to be linked topublic abstract java.lang.String saveParameters()
public abstract void loadParameters(java.io.StreamTokenizer tokenizer) throws java.io.IOException
public abstract void go()
|
|||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||
SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |