public class BlockingControlLink extends AbstractCloneable implements ControlLink
AbstractCloneable.Cloning, AbstractCloneable.CopyVisitor
Constructor and Description |
---|
BlockingControlLink()
Constructs an unconnected
BlockingControlLink . |
BlockingControlLink(Processor block,
Processor untilFinished)
Constructs a
BlockingControlLink with the specified blocked and control Processor s. |
Modifier and Type | Method and Description |
---|---|
boolean |
accept(Visitor visitor)
Accepts a
Visitor to this WorkflowBean . |
protected void |
cloneInto(WorkflowBean clone,
AbstractCloneable.Cloning cloning) |
int |
compareTo(Object o) |
boolean |
equals(Object obj) |
Processor |
getBlock()
Returns the
Processor that is blocked from starting. |
Workflow |
getParent()
Returns the parent of this workflow bean, or
null if it is orphan. |
Processor |
getUntilFinished()
Returns the
Processor that controls the block. |
int |
hashCode() |
void |
setBlock(Processor block)
Sets the
Processor that is blocked from starting. |
void |
setParent(Workflow parent)
Sets the parent of this workflow bean.
|
void |
setUntilFinished(Processor untilFinished)
Sets the
Processor that controls the block. |
String |
toString() |
clone, cloneWorkflowBean
finalize, getClass, notify, notifyAll, wait, wait, wait
clone
public BlockingControlLink()
BlockingControlLink
.public BlockingControlLink(Processor block, Processor untilFinished)
BlockingControlLink
with the specified blocked and control Processor
s.
The parent Workflow
is set to be the same as the parent of the block Processor
.
block
- the Processor
that is blocked from starting. Must
not be null
untilFinished
- the Processor
that controls the block. Can be null
.public boolean accept(Visitor visitor)
WorkflowBean
Visitor
to this WorkflowBean
.accept
in interface WorkflowBean
visitor
- the Visitor
to accepttrue
if this WorkflowBeans
children should be visited.public int compareTo(Object o)
compareTo
in interface Comparable
public Processor getBlock()
Processor
that is blocked from starting.Processor
that is blocked from startingpublic Workflow getParent()
Child
null
if it is orphan.public Processor getUntilFinished()
Processor
that controls the block.Processor
that controls the blockpublic void setBlock(Processor block)
Processor
that is blocked from starting.block
- the Processor
that is blocked from starting. Can be null
public void setParent(Workflow parent)
Child
Setting the parent would normally also add the object to the relevant collection in the parent if it does not already exist there.
If the child has an existing, object-identity different parent, the child will first be removed from the parent collection if it exists there.
Note:If the child is Named
the parent collection will be a
NamedSet
. This implicit insertion would overwrite any conflicting sibling with the
same Named.getName()
- to avoid this, add the child to the parent collection by using
NamedSet.addWithUniqueName(Named)
before setting the parent.
public void setUntilFinished(Processor untilFinished)
Processor
that controls the block.untilFinished
- the Processor
that controls the block. Can be null
protected void cloneInto(WorkflowBean clone, AbstractCloneable.Cloning cloning)
cloneInto
in class AbstractCloneable
Copyright © 2013 myGrid. All rights reserved.