public class Processor extends java.lang.Object implements REpiceaUIObjectWithParent, REpiceaUIObject, javax.swing.event.CaretListener, java.io.Serializable
| Modifier and Type | Field and Description |
|---|---|
protected double |
averageIntake
Deprecated.
|
protected ProcessorButton |
guiInterface |
protected boolean |
isTerminal |
protected java.util.List<Processor> |
subProcessors |
| Constructor and Description |
|---|
Processor()
General constructor.
|
Processor(java.lang.String name)
General constructor with name.
|
| Modifier and Type | Method and Description |
|---|---|
void |
addSubProcessor(Processor processor)
This method adds a process to the sub processes.
|
void |
caretUpdate(javax.swing.event.CaretEvent evt) |
protected java.util.List<ProcessUnit> |
createProcessUnits(ProcessUnit inputUnit,
int intake) |
protected java.util.List<ProcessUnit> |
createProcessUnitsFromThisProcessor(ProcessUnit inputUnit,
int intake) |
java.util.Collection<ProcessUnit> |
doProcess(java.util.List<ProcessUnit> inputUnits) |
java.lang.String |
getName()
This method returns the name of the processor.
|
protected java.awt.Point |
getOriginalLocation() |
protected REpiceaPanel |
getProcessFeaturesPanel()
This method returns other process features when the processor button is double clicked.
|
protected java.util.Map<Processor,java.lang.Integer> |
getSubProcessorIntakes()
This method returns the processor intakes in a map.
|
java.util.List<Processor> |
getSubProcessors()
This method returns the processes that are subordinated to this one.
|
ProcessorButton |
getUI()
This method returns the GUI interface of the class that implements this interface.
|
ProcessorButton |
getUI(java.awt.Container container)
This method returns the GUI interface of the class that implements this interface.
|
boolean |
hasSubProcessors()
This method returns true if the processor has one or many subprocessors tied to itself or false otherwise.
|
boolean |
isPartOfEndlessLoop() |
boolean |
isTerminalProcessor()
This method returns true if the processor is a final processor, which means it cannot
send anything to subprocessors.
|
boolean |
isValid()
This method checks if the wood processor is valid as well as all its subprocessors.
|
boolean |
isVisible()
This method returns true if the GUI is visible.
|
void |
removeSubProcessor(Processor processor)
This method removes a process from the sub processes.
|
void |
setName(java.lang.String str)
This method sets the name of the processor.
|
protected void |
setOriginalLocation(java.awt.Point relativePoint) |
protected void |
setPartOfEndlessLoop(boolean bool) |
java.lang.String |
toString() |
protected transient ProcessorButton guiInterface
protected java.util.List<Processor> subProcessors
protected boolean isTerminal
@Deprecated protected double averageIntake
public Processor()
public Processor(java.lang.String name)
public boolean isTerminalProcessor()
public java.util.Collection<ProcessUnit> doProcess(java.util.List<ProcessUnit> inputUnits)
protected final java.util.List<ProcessUnit> createProcessUnits(ProcessUnit inputUnit, int intake)
protected java.util.List<ProcessUnit> createProcessUnitsFromThisProcessor(ProcessUnit inputUnit, int intake)
public void addSubProcessor(Processor processor)
processor - a Process instancepublic void removeSubProcessor(Processor processor)
processor - a Process instancepublic java.util.List<Processor> getSubProcessors()
protected java.util.Map<Processor,java.lang.Integer> getSubProcessorIntakes()
protected java.awt.Point getOriginalLocation()
protected void setOriginalLocation(java.awt.Point relativePoint)
public ProcessorButton getUI(java.awt.Container container)
REpiceaUIObjectWithParentgetUI in interface REpiceaUIObjectWithParentcontainer - a parent Container instance (can be null)public java.lang.String getName()
public void setName(java.lang.String str)
str - a String instancepublic java.lang.String toString()
toString in class java.lang.Objectpublic ProcessorButton getUI()
REpiceaUIObjectgetUI in interface REpiceaUIObjectpublic void caretUpdate(javax.swing.event.CaretEvent evt)
caretUpdate in interface javax.swing.event.CaretListenerpublic boolean hasSubProcessors()
public boolean isValid()
public boolean isPartOfEndlessLoop()
protected REpiceaPanel getProcessFeaturesPanel()
public boolean isVisible()
REpiceaUIObjectWithParentisVisible in interface REpiceaUIObjectisVisible in interface REpiceaUIObjectWithParentprotected void setPartOfEndlessLoop(boolean bool)