public class CfgProcess extends CfgDeclarationStatement
The object contains the embedded control flow graph nodes
and EventList
sensitivity list. Also it can be either
of initial or of non-initial type.
NEW_VAR_PREFIX
Constructor and Description |
---|
CfgProcess()
Default constructor.
|
CfgProcess(boolean initial)
Constructs new process with the specified value of initial flag.
|
CfgProcess(boolean initial,
EventList list)
Constructs new process with the specified initial flag and sensitivity list.
|
Modifier and Type | Method and Description |
---|---|
void |
add(CfgStatement statement)
Adds the specified statement as child to this object.
|
void |
addAll(java.util.List<CfgStatement> list)
Adds all the statements from the specified list as children.
|
void |
addEvent(Event event)
Add the specified statement which this process is sensible to.
|
void |
apply(java.util.Map<java.lang.String,ru.ispras.fortress.expression.Node> bindings)
Applies bindings to process control flow graph and sensitivity list.
|
CfgStatement |
deepCopy()
Returns a copy of this statement and all it's sub-statements.
|
java.lang.String |
getDescription(ru.ispras.fortress.expression.printer.ExprTreePrinter printer)
Returns a string description in the format of the specified printer.
|
EventList |
getSensitivityList()
Returns
EventList sensitivity list. |
CfgStatementType |
getType()
Returns statement type.
|
boolean |
isInitial()
Checks whether process is of initial kind.
|
void |
setParent(CfgStatement parent)
Sets the specified statement as parent.
|
void |
setSensitivityList(EventList eventList)
Sets new
EventList sensitivity list. |
contains, containsInput, containsOutput, containsRegister, containsVariable, declareNewVariable, declareVariable, declareVariable, declareVariable, declareVariables, getDataType, getDeclaration, getDeclarationMap, getDeclarations, getDefines, getInitialValue, getInputNames, getInvariant, getOutputNames, getRegisterNames, getUses, getVariable, getVariableNames, getVariables, removeDeclaration, setVariablesMapping
add, contains, containStatements, equals, getDescription, getId, getParent, getStatement, getStatement, getStatementNum, hashCode, hasParent, indexOf, isType, remove, removeAll, removeParent, removeStatement
addMetaInfo, addMetaInfo, addMetaInfo, addMetaInfo, getMetaInfo, getMetaInfo, getMetaInfo, hasMetaInfo, hasMetaInfo, removeMetaInfo
public CfgProcess()
Constructs non-initial process.
public CfgProcess(boolean initial, EventList list)
initial
- initial flaglist
- event listjava.lang.IllegalArgumentException
- when sensitivity list argument is null
.public CfgProcess(boolean initial)
initial
- initial flagpublic boolean isInitial()
true
if process is initial, false
otherwise.public EventList getSensitivityList()
EventList
sensitivity list.public void setSensitivityList(EventList eventList)
EventList
sensitivity list.eventList
- event listjava.lang.IllegalArgumentException
- when argument is null
.RetrascopeRuntimeException
- when object is initial and argument is non-empty.public void addEvent(Event event)
event
- event to be addedjava.lang.IllegalArgumentException
- when argument is null
.RetrascopeRuntimeException
- when this process is initial.public void apply(java.util.Map<java.lang.String,ru.ispras.fortress.expression.Node> bindings)
apply
in interface Instantiated
apply
in class CfgStatement
bindings
- "variable name - expression" bindingspublic CfgStatement deepCopy()
CfgStatement
deepCopy
in class CfgStatement
public void add(CfgStatement statement)
CfgStatement
add
in class CfgStatement
statement
- Statement to be added.public void addAll(java.util.List<CfgStatement> list)
CfgStatement
addAll
in class CfgStatement
list
- Children statements to be added.public void setParent(CfgStatement parent)
CfgStatement
setParent
in class CfgStatement
parent
- Statement to be set as parent.public java.lang.String getDescription(ru.ispras.fortress.expression.printer.ExprTreePrinter printer)
Identifiable
printer
- Printer that provides an output string format.public CfgStatementType getType()
CfgStatement
getType
in class CfgStatement