class Ens.BPL.UI.Parser
extends %RegisteredObject
This class validates and parses a BPL.UI.Diagram object into a BPL.Process object.
Usage:
Set tParser = ##class(Ens.BPL.UI.Parser).%New()
Set tSC = tParser.ParseDiagram(tDiagram)
Set tProcess = tParser.Process
property Process
as Ens.BPL.Process;
The Process object created as a result of parsing
method CreateBPLNode(pShape As Shape, ByRef pNode As Ens.BPL.Node, pParent As Ens.BPL.Activity)
as %Status
Finds an instance of a Ens.BPL.Node object
that corresponds to the given shape.
method FindStartShape(pList As %RegisteredObject, ByRef pStart As Shape)
as Shape
Find the starting shape in the given collection.
method MakeError(pErr As %String, pShape As Shape = "")
as %Status
Create an error code for a diagram parsing error
method ParseDiagram(pDiagram As Diagram)
as %Status
Analyze the given diagram and create a BPL object tree
method ParseSequence(pStart As Shape, pParent As Ens.BPL.Node, pCurrScope As Ens.BPL.Scope, pActivities As Ens.BPL.NodeList, pEnd As Shape = "")
as %Status
Given a starting shape, process all the shapes in the given sequence.
Add the BPL nodes to the given ActivityList (which could be any NodeList).
If pEnd is present, then processing stops when it is reached.
pCurrScope is the current containing scope, if any.
method ValidateDiagram(pDiagram As Diagram)
as %Status
Analyze the given diagram and check for syntax errors
If there are errors, they are set into Error.