Click or drag to resize

IGraphProcessingEnvironment Interface

An environment for the advanced processing of graphs and the execution of sequences. With global variables, (sub)graph switching, and transaction management.

Namespace:  de.unika.ipd.grGen.libGr
Assembly:  libGr (in libGr.dll) Version: GrGen.NET 4.5
Syntax
C#
public interface IGraphProcessingEnvironment : ISubactionAndOutputAdditionEnvironment, 
	IActionExecutionEnvironment

The IGraphProcessingEnvironment type exposes the following members.

Properties
  NameDescription
Public propertyActions
The actions employed by this graph processing environment
(Inherited from IActionExecutionEnvironment.)
Public propertyCompliantUserProxy
Returns a non-interactive user proxy just echoing its inputs.
Public propertyEmitWriter
The writer used by emit statements. By default this is Console.Out.
(Inherited from ISubactionAndOutputAdditionEnvironment.)
Public propertyEmitWriterDebug
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.)
Public propertyGraph
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.)
Public propertyHighlightingUnderway
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.)
Public propertyIsInSubgraph
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.)
Public propertyItem
Indexer for accessing the variables by name, via index notation on this object.
Public propertyMaxMatches
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.)
Public propertyNamedGraph
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.)
Public propertyPerformanceInfo
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.)
Public propertyRecorder
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.)
Public propertyTransactionManager
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!
Public propertyUserProxy
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.
Public propertyVariables
Returns an iterator over all available (non-null) variables
Top
Methods
  NameDescription
Public methodAddEdge(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.
Public methodAddEdge(IEdge, String, String)
Adds an existing edge to the graph, names it, and assigns it to the given variable.
Public methodAddEdge(EdgeType, INode, INode, String)
Adds a new edge to the current graph of this processing environment and assigns it to the given variable.
Public methodAddEdge(EdgeType, INode, INode, String, String)
Adds a new named edge to the graph and assigns it to the given variable.
Public methodAddNode(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!
Public methodAddNode(NodeType, String)
Adds a new node to the current graph of this processing environment and assigns it to the given variable.
Public methodAddNode(INode, String, String)
Adds an existing node to the graph, names it, and assigns it to the given variable.
Public methodAddNode(NodeType, String, String)
Adds a new named node to the graph and assigns it to the given variable.
Public methodApplyGraphRewriteSequence(String)
Apply a graph rewrite sequence (to the currently associated graph).
Public methodApplyGraphRewriteSequence(Sequence)
Apply a graph rewrite sequence (to the currently associated graph).
Public methodApplyRewrite
Apply a rewrite rule (first computing the parameters with sequence expressions, last assigning result variables).
Public methodCloneGraphVariables
Duplicates the graph variables of an old just cloned graph, assigns them to the new cloned graph.
Public methodCustom
Does action execution environment dependent stuff.
(Inherited from IActionExecutionEnvironment.)
Public methodDebugEmitting
Fires an OnDebugEmit event.
(Inherited from ISubactionAndOutputAdditionEnvironment.)
Public methodDebugEntering
Fires an OnDebugEnter event.
(Inherited from ISubactionAndOutputAdditionEnvironment.)
Public methodDebugExiting
Fires an OnDebugExit event.
(Inherited from ISubactionAndOutputAdditionEnvironment.)
Public methodDebugHalting
Fires an OnDebugHalt event.
(Inherited from ISubactionAndOutputAdditionEnvironment.)
Public methodDebugHighlighting
Fires an OnDebugHighlight event.
(Inherited from ISubactionAndOutputAdditionEnvironment.)
Public methodEndOfIteration
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.
Public methodEnteringSequence
Fires an OnEnteringSequence event.
Public methodExitingSequence
Fires an OnExitingSequence event.
Public methodFinished
Fires an OnFinished event.
(Inherited from IActionExecutionEnvironment.)
Public methodFinishing
Fires an OnFinishing event.
(Inherited from IActionExecutionEnvironment.)
Public methodGetEdgeVarValue
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.
Public methodGetElementVariables
Returns a linked list of variables mapping to the given graph element or null, if no variable points to this element
Public methodGetNewestActionVersion
Retrieves the newest version of an IAction object currently available for this graph. This may be the given object.
(Inherited from IActionExecutionEnvironment.)
Public methodGetNodeVarValue
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.
Public methodGetVariableValue
Retrieves the object for a variable name or null, if the variable isn't set yet or anymore
Public methodMatched
Fires an OnMatched event.
(Inherited from IActionExecutionEnvironment.)
Public methodParseSequence
Parses the given XGRS string and generates a Sequence object. Any actions in the string must refer to actions from the actions contained in this object.
Public methodReplace
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.)
Public methodReturnFromSubgraph
Returns from the last switch to subgraph. (One level back on the current graph stack.)
(Inherited from ISubactionAndOutputAdditionEnvironment.)
Public methodRewritingNextMatch
Fires an OnRewritingNextMatch event.
(Inherited from IActionExecutionEnvironment.)
Public methodSetNewestActionVersion
Sets the newest action version for a static action.
(Inherited from IActionExecutionEnvironment.)
Public methodSetVariableValue
Sets the value of the given variable to the given value. If the variable name is null, this function does nothing. If elem is null, the variable is unset.
Public methodSwitchToSubgraph
Switches the graph to the given (sub)graph. (One level added to the current graph stack.)
(Inherited from ISubactionAndOutputAdditionEnvironment.)
Public methodValidateWithSequence(String)
Tests whether the given sequence succeeds on a clone of the associated graph.
Public methodValidateWithSequence(Sequence)
Tests whether the given sequence succeeds on a clone of the associated graph.
Top
Events
  NameDescription
Public eventOnDebugEmit
Fired when a debug emit is executed.
(Inherited from ISubactionAndOutputAdditionEnvironment.)
Public eventOnDebugEnter
Fired when a debug entity is entered.
(Inherited from ISubactionAndOutputAdditionEnvironment.)
Public eventOnDebugExit
Fired when a debug entity is left.
(Inherited from ISubactionAndOutputAdditionEnvironment.)
Public eventOnDebugHalt
Fired when a debug halt is executed.
(Inherited from ISubactionAndOutputAdditionEnvironment.)
Public eventOnDebugHighlight
Fired when a debug highlight is executed.
(Inherited from ISubactionAndOutputAdditionEnvironment.)
Public eventOnEndOfIteration
Fired when a sequence iteration is ended.
Public eventOnEntereringSequence
Fired when a sequence is entered.
Public eventOnExitingSequence
Fired when a sequence is left.
Public eventOnFinished
Fired after the rewrite step of a rule. Note, that the given matches object may contain invalid entries, as parts of the match may have been deleted!
(Inherited from IActionExecutionEnvironment.)
Public eventOnFinishing
Fired before the rewrite step of a rule, when at least one match has been found.
(Inherited from IActionExecutionEnvironment.)
Public eventOnMatched
Fired after all requested matches of a rule have been matched.
(Inherited from IActionExecutionEnvironment.)
Public eventOnReturnedFromSubgraph
Fired when graph processing is returning back after a switch. (To the main graph, or a subgraph previously switched to.)
(Inherited from ISubactionAndOutputAdditionEnvironment.)
Public eventOnRewritingNextMatch
Fired before the next match is rewritten. It is not fired before rewriting the first match.
(Inherited from IActionExecutionEnvironment.)
Public eventOnSwitchingToSubgraph
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.)
Top
See Also