|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectcz.cuni.amis.pogamut.sposh.elements.PoshElement<THIS,PARENT>
cz.cuni.amis.pogamut.sposh.elements.PoshDummyElement<Adopt,PoshPlan>
cz.cuni.amis.pogamut.sposh.elements.Adopt
public class Adopt
Adopt element is a stopgap. When engine requires to clear the stack, stack will be cleared only up to first adopt with failed exit condition.
Field Summary | |
---|---|
static String |
adName
Property string of competence name |
static String |
adParams
Property string used for PropertyChangeEvent when FormalParameters
are changed. |
static DataFlavor |
dataFlavor
Data flavor of adopt class, used for drag-and-drop |
Fields inherited from class cz.cuni.amis.pogamut.sposh.elements.PoshDummyElement |
---|
IDENT_PATTERN |
Constructor Summary | |
---|---|
Adopt(String name,
FormalParameters parameters,
List<Sense> exitCondition,
PrimitiveCall adoptedElement)
|
Method Summary | |
---|---|
void |
addCondition(Sense sense)
|
TriggeredAction |
getAdoptedElement()
|
List<? extends PoshElement> |
getChildDataNodes()
Get list of children of this node. |
Trigger<Adopt> |
getCondition()
Get exit condition of the adopt. |
DataFlavor |
getDataFlavor()
Get data flavour of posh plan element,used during DnD from palette to PoshScene. |
Trigger<Adopt> |
getExitCondition()
|
String |
getName()
Get name of the element. |
FormalParameters |
getParameters()
|
LapType |
getType()
Get type of the element. |
boolean |
moveChild(int newIndex,
PoshElement child)
Move child to the @newIndex. |
void |
rename(String newName)
Change name of the element to newName. |
void |
setName(String name)
|
void |
setParameters(FormalParameters newParams)
Set new parameters. |
Methods inherited from class cz.cuni.amis.pogamut.sposh.elements.PoshDummyElement |
---|
getElementId, getUnusedName, isUsedName, moveChildInList |
Methods inherited from class cz.cuni.amis.pogamut.sposh.elements.PoshElement |
---|
addElementListener, emitChildDeleted, emitChildMove, emitChildNode, firePropertyChange, getChildId, getChildren, getElementListeners, getId, getParent, getRootNode, isChildOfParent, removeElementListener, setParent |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
---|
public static final DataFlavor dataFlavor
public static final String adName
public static final String adParams
PropertyChangeEvent
when FormalParameters
are changed.
Constructor Detail |
---|
public Adopt(String name, FormalParameters parameters, List<Sense> exitCondition, PrimitiveCall adoptedElement)
Method Detail |
---|
public FormalParameters getParameters()
getParameters
in interface IParametrizedElement
public void setParameters(FormalParameters newParams)
IParametrizedElement
setParameters
in interface IParametrizedElement
newParams
- new parameterspublic String getName()
INamedElement
getName
in interface INamedElement
public void setName(String name) throws InvalidNameException, DuplicateNameException, CycleException
InvalidNameException
DuplicateNameException
CycleException
public void rename(String newName) throws InvalidNameException, CycleException, DuplicateNameException
INamedElement
rename
in interface INamedElement
newName
- New name of the element.
InvalidNameException
- Passed name is not valid Yaposh name.
CycleException
- Renaming causes cycle.
DuplicateNameException
- Such name is already used in the plan.public void addCondition(Sense sense)
public Trigger<Adopt> getExitCondition()
public Trigger<Adopt> getCondition()
getCondition
in interface IConditionElement<Adopt>
getExitCondition()
public TriggeredAction getAdoptedElement()
public DataFlavor getDataFlavor()
PoshElement
getDataFlavor
in class PoshElement<Adopt,PoshPlan>
public LapType getType()
PoshElement
getType
in class PoshElement<Adopt,PoshPlan>
public List<? extends PoshElement> getChildDataNodes()
PoshElement
getChildDataNodes
in class PoshElement<Adopt,PoshPlan>
public boolean moveChild(int newIndex, PoshElement child)
PoshElement
moveChild
in class PoshElement<Adopt,PoshPlan>
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |