IGraphProcessingEnvironment Interface |
Namespace: de.unika.ipd.grGen.libGr
public interface IGraphProcessingEnvironment : ISubactionAndOutputAdditionEnvironment, IActionExecutionEnvironment
The IGraphProcessingEnvironment type exposes the following members.
Name | Description | |
---|---|---|
Actions |
The actions employed by this graph processing environment
(Inherited from IActionExecutionEnvironment.) | |
Backend |
The backend to be used for graph creation when a graph is imported
(Inherited from IActionExecutionEnvironment.) | |
CompliantUserProxy |
Returns a non-interactive user proxy just echoing its inputs.
| |
CustomCommandsAndDescriptions |
The action execution environment dependent commands that are available, and a description of each command.
(Inherited from IActionExecutionEnvironment.) | |
EmitWriter |
The writer used by emit statements. By default this is Console.Out.
(Inherited from ISubactionAndOutputAdditionEnvironment.) | |
EmitWriterDebug |
The writer used by emitdebug statements. This is Console.Out, and can't be redirected to a file in contrast to the EmitWriter.
(Inherited from ISubactionAndOutputAdditionEnvironment.) | |
EnableAssertions |
Allows to enable/disable assertions and find out about assertion state.
(Inherited from IActionExecutionEnvironment.) | |
Graph |
Returns the graph currently focused in processing / sequence execution.
This may be the initial main graph, or a subgraph switched to, the current top element of the graph usage stack.
(Inherited from IActionExecutionEnvironment.) | |
HighlightingUnderway |
Tells whether execution is interrupted because a highlight statement was hit.
Consequence: the timer that normally prints match statistics every second remains silent
(Inherited from IActionExecutionEnvironment.) | |
IsInSubgraph |
Returns true when graph processings is currently occuring inside a subgraph,
returns false when the main host graph is currently processed
(i.e. only one entry on the current graph stack is existing).
(Inherited from ISubactionAndOutputAdditionEnvironment.) | |
Item |
Indexer for accessing the variables by name, via index notation on this object.
| |
MaxMatches |
The maximum number of matches to be returned for a RuleAll sequence element.
If it is zero or less, the number of matches is unlimited.
(Inherited from IActionExecutionEnvironment.) | |
NamedGraph |
Returns the named graph currently focused in processing / sequence execution.
Returns null if this graph is not a named but an unnamed graph.
(Inherited from IActionExecutionEnvironment.) | |
PerformanceInfo |
PerformanceInfo is used to accumulate information about needed time, found matches and applied rewrites.
And additionally search steps carried out if profiling instrumentation code was generated.
It must not be null.
The user is responsible for resetting the PerformanceInfo object.
This is typically done at the start of a rewrite sequence, to measure its performance.
(Inherited from IActionExecutionEnvironment.) | |
Recorder |
The recorder of the main graph.
Might be null (is set if a named graph is available, then the persistent names are taken from the named graph).
(Inherited from ISubactionAndOutputAdditionEnvironment.) | |
TransactionManager |
Returns the transaction manager of the processing environment.
(Recording and undoing changes in the main graph and all processed subgraphs).
Don't forget to call Commit after a transaction is finished!
| |
UserProxy |
The user proxy queried for choices during sequence execution.
By default the compliant user proxy, if debugging the debugger acting on behalf of/controlled by the user.
| |
Variables |
Returns an iterator over all available (non-null) variables
|
Name | Description | |
---|---|---|
AddEdge(IEdge, String) |
Adds an existing IEdge object to the current graph of this processing environment and assigns it to the given variable.
The edge must not be part of any graph, yet!
Source and target of the edge must already be part of the graph.
| |
AddEdge(IEdge, String, String) |
Adds an existing edge to the graph, names it, and assigns it to the given variable.
| |
AddEdge(EdgeType, INode, INode, String) |
Adds a new edge to the current graph of this processing environment and assigns it to the given variable.
| |
AddEdge(EdgeType, INode, INode, String, String) |
Adds a new named edge to the graph and assigns it to the given variable.
| |
AddNode(INode, String) |
Adds an existing INode object to the current graph of this processing environment and assigns it to the given variable.
The node must not be part of any graph, yet!
The node may not be connected to any other elements!
| |
AddNode(NodeType, String) |
Adds a new node to the current graph of this processing environment and assigns it to the given variable.
| |
AddNode(INode, String, String) |
Adds an existing node to the graph, names it, and assigns it to the given variable.
| |
AddNode(NodeType, String, String) |
Adds a new named node to the graph and assigns it to the given variable.
| |
ApplyGraphRewriteSequence(String) |
Apply a graph rewrite sequence (to the currently associated graph).
| |
ApplyGraphRewriteSequence(Sequence) |
Apply a graph rewrite sequence (to the currently associated graph).
| |
ApplyRewrite |
Apply a rewrite rule.
| |
BeginExecution |
Fires an OnBeginExecution event.
(Inherited from IActionExecutionEnvironment.) | |
Custom |
Does action execution environment dependent stuff.
(Inherited from IActionExecutionEnvironment.) | |
DebugEmitting |
Fires an OnDebugEmit event.
(Inherited from ISubactionAndOutputAdditionEnvironment.) | |
DebugEntering |
Fires an OnDebugEnter event.
(Inherited from ISubactionAndOutputAdditionEnvironment.) | |
DebugExiting |
Fires an OnDebugExit event.
(Inherited from ISubactionAndOutputAdditionEnvironment.) | |
DebugHalting |
Fires an OnDebugHalt event.
(Inherited from ISubactionAndOutputAdditionEnvironment.) | |
DebugHighlighting |
Fires an OnDebugHighlight event.
(Inherited from ISubactionAndOutputAdditionEnvironment.) | |
EndExecution |
Fires an OnEndExecution event.
(Inherited from IActionExecutionEnvironment.) | |
EndOfIteration |
Fires an OnEndOfIteration event.
This informs the debugger about the end of a loop iteration, so it can display the state at the end of the iteration.
| |
EnteringSequence |
Fires an OnEnteringSequence event (sequence includes sequence computations and sequence expressions).
| |
EvaluateGraphRewriteSequenceExpression(String) |
Evaluate a graph rewrite sequence expression (on the currently associated graph).
| |
EvaluateGraphRewriteSequenceExpression(SequenceExpression) |
Evaluate a graph rewrite sequence expression (on the currently associated graph).
| |
ExitingSequence |
Fires an OnExitingSequence event (sequence includes sequence computations and sequence expressions).
| |
Filter |
Filters the matches of a rule (all) call with a lambda expression filter (call).
| |
Finished(IMatches, Boolean) |
Fires an OnFinished event.
(Inherited from IActionExecutionEnvironment.) | |
Finished(IMatches, Boolean) |
Fires an OnFinished event.
(Inherited from IActionExecutionEnvironment.) | |
FinishedSelectedMatch |
Fires an OnFinishedSelectedMatch event.
(Inherited from IActionExecutionEnvironment.) | |
GetEdgeVarValue |
Retrieves the IEdge for a variable name or null, if the variable isn't set yet or anymore.
A InvalidCastException is thrown, if the variable is set and does not point to an IEdge object.
| |
GetElementVariables |
Returns a linked list of variables mapping to the given graph element
or null, if no variable points to this element
| |
GetNewestActionVersion |
Retrieves the newest version of an IAction object currently available for this graph.
This may be the given object.
(Inherited from IActionExecutionEnvironment.) | |
GetNodeVarValue |
Retrieves the INode for a variable name or null, if the variable isn't set yet or anymore.
A InvalidCastException is thrown, if the variable is set and does not point to an INode object.
| |
GetVariableValue |
Retrieves the object for a variable name or null, if the variable isn't set yet or anymore
| |
JoinSequences |
Fires an OnJoinSequences event.
| |
Match |
Matches a rewrite rule.
(Inherited from IActionExecutionEnvironment.) | |
MatchedAfterFiltering(IMatches, Boolean) |
Fires an OnMatchedAfter event.
(Inherited from IActionExecutionEnvironment.) | |
MatchedAfterFiltering(IMatches, Boolean) |
Fires an OnMatchedAfter event.
(Inherited from IActionExecutionEnvironment.) | |
MatchedBeforeFiltering(IMatches) |
Fires an OnMatchedBefore event.
(Inherited from IActionExecutionEnvironment.) | |
MatchedBeforeFiltering(IMatches) |
Fires an OnMatchedBefore event.
(Inherited from IActionExecutionEnvironment.) | |
MatchForQuery(Boolean, ActionCall) |
Matches the rewrite rules, without firing the Matched event, but with firing the PreMatch event and Cloning of the matches
(so they can stored, or used in an expression combining multiple queries).
(Inherited from IActionExecutionEnvironment.) | |
MatchForQuery(IAction, Object, Int32, Boolean) |
Matches a rewrite rule, without firing the Matched event, but with firing the PreMatch event and Cloning of the matches
(so they can stored, or used in an expression combining multiple queries like [?r] + [?r],
or the action can be called multiple times in a multi rule all call query (on different parameters)).
(Inherited from IActionExecutionEnvironment.) | |
MatchSelected |
Fires an OnMatchSelected event.
(Inherited from IActionExecutionEnvironment.) | |
MatchWithoutEvent(Boolean, ActionCall) |
Matches the rewrite rules, without firing the Matched event, but fires the MatchedBeforeFiltering event (for internal or non-debugger use).
(Inherited from IActionExecutionEnvironment.) | |
MatchWithoutEvent(IAction, Object, Int32, Boolean) |
Matches a rewrite rule, without firing the Matched event (but fires the MatchedBeforeFiltering event - for internal or non-debugger use).
(Inherited from IActionExecutionEnvironment.) | |
ParallelApplyGraphRewriteSequences(SequenceParallelArrayExecute) |
In parallel, apply the graph rewrite sequence (to the given graphs, with the given input values).
| |
ParallelApplyGraphRewriteSequences(SequenceParallelExecute) |
In parallel, apply the graph rewrite sequence(s) (to the given graphs, with the given input values).
| |
ParseSequence |
Parses the given sequence string and generates a Sequence object.
Any actions in the string must refer to actions from the actions contained in this object.
| |
ParseSequenceExpression |
Parses the given sequence expression string and generates a SequenceExpression object.
Any actions in the string must refer to actions from the actions contained in this object.
| |
Replace |
Executes the modifications of the according rule to the given match/matches.
Fires OnRewritingNextMatch events before each rewrite except for the first one.
(Inherited from IActionExecutionEnvironment.) | |
ReturnFromSubgraph |
Returns from the last switch to subgraph.
(One level back on the current graph stack.)
(Inherited from ISubactionAndOutputAdditionEnvironment.) | |
RewritingSelectedMatch |
Fires an OnRewritingSelectedMatch event (comparable to the old OnFinishing and OnRewritingNextMatch, now one event, fired per selected match).
(Inherited from IActionExecutionEnvironment.) | |
SetNewestActionVersion |
Sets the newest action version for a static action.
(Inherited from IActionExecutionEnvironment.) | |
SetVariableValue |
Sets the value of the given variable to the given value.
If the variable name is null, this function does nothing.
If val is null, the variable is unset.
| |
SpawnSequences |
Fires an OnSpawnSequences event.
| |
SwitchToSubgraph |
Switches the graph to the given (sub)graph.
(One level added to the current graph stack.)
(Inherited from ISubactionAndOutputAdditionEnvironment.) | |
ValidateWithSequence(String) |
Tests whether the given sequence succeeds on a clone of the associated graph.
| |
ValidateWithSequence(Sequence) |
Tests whether the given sequence succeeds on a clone of the associated graph.
|
Name | Description | |
---|---|---|
OnBeginExecution |
Fired when execution of a pattern matching construct begins.
(Inherited from IActionExecutionEnvironment.) | |
OnDebugEmit |
Fired when a debug emit is executed.
(Inherited from ISubactionAndOutputAdditionEnvironment.) | |
OnDebugEnter |
Fired when a debug entity is entered.
(Inherited from ISubactionAndOutputAdditionEnvironment.) | |
OnDebugExit |
Fired when a debug entity is left.
(Inherited from ISubactionAndOutputAdditionEnvironment.) | |
OnDebugHalt |
Fired when a debug halt is executed.
(Inherited from ISubactionAndOutputAdditionEnvironment.) | |
OnDebugHighlight |
Fired when a debug highlight is executed.
(Inherited from ISubactionAndOutputAdditionEnvironment.) | |
OnEndExecution |
Fired when execution of a pattern matching construct ends.
(Inherited from IActionExecutionEnvironment.) | |
OnEndOfIteration |
Fired when a sequence iteration is ended.
| |
OnEntereringSequence |
Fired when a sequence is entered.
| |
OnExitingSequence |
Fired when a sequence is left.
| |
OnFinished |
Fired after the rewrite step of a rule/after rule execution has completed.
Note, that the given matches object may contain invalid entries,
as parts of the match may have been deleted!
(Inherited from IActionExecutionEnvironment.) | |
OnFinishedSelectedMatch |
Fired after the selected match was rewritten and embedded sequences executed.
(Inherited from IActionExecutionEnvironment.) | |
OnJoinSequences |
Fired when sequences have joined (again) their parent thread.
| |
OnMatchedAfter |
Fired after all requested matches of a multi rule or rule have been matched (after filtering of matches).
(Inherited from IActionExecutionEnvironment.) | |
OnMatchedBefore |
Fired after all requested matches of a multi rule or rule have been matched, before filtering of the matches.
Allows a lookahead on the matches, on all found matches, in contrast to OnMatchedAfter that only reports the ones that are applied in the end.
(Inherited from IActionExecutionEnvironment.) | |
OnMatchSelected |
Fired when a match was selected for execution (after filtering/selection of matches).
(Inherited from IActionExecutionEnvironment.) | |
OnReturnedFromSubgraph |
Fired when graph processing is returning back after a switch.
(To the main graph, or a subgraph previously switched to.)
(Inherited from ISubactionAndOutputAdditionEnvironment.) | |
OnRewritingSelectedMatch |
Fired before the selected match is rewritten (comparable to the old OnFinishing and OnRewritingNextMatch, now one event, fired per selected match).
(Inherited from IActionExecutionEnvironment.) | |
OnSelectedMatchRewritten |
Fired after the selected match was rewritten (but before embedded sequences are executed).
(Inherited from IActionExecutionEnvironment.) | |
OnSpawnSequences |
Fired when sequences have been spawned (split off) from their parent thread.
| |
OnSwitchingToSubgraph |
Fired when graph processing (rule and sequence execution) is switched to a (sub)graph.
(Not fired when the main graph is replaced by another main graph, or initialized.)
(Inherited from ISubactionAndOutputAdditionEnvironment.) |