Home > Class Reference > ENSLIB namespace > Ens.BPL.Compiler

Ens.BPL.Compiler

class Ens.BPL.Compiler extends %Library.RegisteredObject

This is the BPL Compiler. It it called during the compilation process of subclasses of Ens.BusinessProcessBPL to generate the business process runtime classes. These debug flags affect the diagnostic output of the compiler:- ^Ens.Debug("ShowGeneratedXML") - Displays XML reconstructed from the parse tree to the current device.

Property Inventory (Including Private)

Method Inventory (Including Private)

Properties (Including Private)

property BreakStack as Ens.BPL.Stack;
This holds the stack of states which may be broken to
Property methods: BreakStackGet(), BreakStackGetSwizzled(), BreakStackIsValid(), BreakStackNewObject(), BreakStackSet()
property CompensationHandlers as %String [ MultiDimensional ];
This holds the collection of compensatation handlers which are active for the current scope
Property methods: CompensationHandlersDisplayToLogical(), CompensationHandlersGet(), CompensationHandlersIsValid(), CompensationHandlersLogicalToDisplay(), CompensationHandlersLogicalToOdbc(), CompensationHandlersNormalize(), CompensationHandlersSet()
property Context as %Dictionary.ClassDefinition;
This holds the business class being generated
Property methods: ContextGet(), ContextGetObject(), ContextGetObjectId(), ContextGetSwizzled(), ContextIsValid(), ContextNewObject(), ContextSet(), ContextSetObject(), ContextSetObjectId(), ContextStackGet(), ContextStackGetSwizzled(), ContextStackIsValid(), ContextStackNewObject(), ContextStackSet(), ContextUnSwizzle()
property ContextStack as Ens.BPL.ContextStack;
This holds the current context of the compilation. It supports a 'Path' property which defines the current position in the nesting hierarchy of the parse tree being traversed.
Property methods: ContextStackGet(), ContextStackGetSwizzled(), ContextStackIsValid(), ContextStackNewObject(), ContextStackSet()
property ContinueStack as Ens.BPL.Stack;
This holds the stack of states which may be continued to
Property methods: ContinueStackGet(), ContinueStackGetSwizzled(), ContinueStackIsValid(), ContinueStackNewObject(), ContinueStackSet()
property CurrentMethod as %Dictionary.MethodDefinition [ Calculated ];
This holds the current method being generated
Property methods: CurrentMethodGet()
property CurrentStateCounter as Ens.BPL.Counter [ Calculated ];
This holds the counter for the current state
Property methods: CurrentStateCounterGet()
property CurrentThread as Ens.BPL.CompilerThread [ Calculated ];
This holds the current thread being generated
Property methods: CurrentThreadGet()
property Language as %String;
This holds the language for the generated classes
Property methods: LanguageDisplayToLogical(), LanguageGet(), LanguageIsValid(), LanguageLogicalToDisplay(), LanguageLogicalToOdbc(), LanguageNormalize(), LanguageSet()
property MethodCounter as Ens.BPL.Counter;
This holds the method counter
Property methods: MethodCounterGet(), MethodCounterGetSwizzled(), MethodCounterIsValid(), MethodCounterNewObject(), MethodCounterSet()
property MethodStack as Ens.BPL.Stack;
This holds the stack of methods being generated
Property methods: MethodStackGet(), MethodStackGetSwizzled(), MethodStackIsValid(), MethodStackNewObject(), MethodStackSet()
property Process as Ens.BPL.Process;
This holds the root of the parse tree being compiled
Property methods: ProcessGet(), ProcessGetSwizzled(), ProcessIsValid(), ProcessNewObject(), ProcessSet()
property PropertiesToNew as list of %String;
This holds the list of properties which must be instantiated in the %OnNew() method of the context class
Property methods: PropertiesToNewBuildValueArray(), PropertiesToNewCollectionToDisplay(), PropertiesToNewCollectionToOdbc(), PropertiesToNewDisplayToCollection(), PropertiesToNewDisplayToLogical(), PropertiesToNewGet(), PropertiesToNewGetObject(), PropertiesToNewGetObjectId(), PropertiesToNewGetSwizzled(), PropertiesToNewIsValid(), PropertiesToNewLogicalToDisplay(), PropertiesToNewLogicalToOdbc(), PropertiesToNewNormalize(), PropertiesToNewOdbcToCollection(), PropertiesToNewSet(), PropertiesToNewSetObject(), PropertiesToNewSetObjectId()
property StateCounterStack as Ens.BPL.Counter;
This holds the state counter
Property methods: StateCounterStackGet(), StateCounterStackGetSwizzled(), StateCounterStackIsValid(), StateCounterStackNewObject(), StateCounterStackSet()
property StateStack as Ens.BPL.Stack;
This holds the stack of states
Property methods: StateStackGet(), StateStackGetSwizzled(), StateStackIsValid(), StateStackNewObject(), StateStackSet()
property ThreadCounter as Ens.BPL.Counter;
This holds the thread counter
Property methods: ThreadCounterGet(), ThreadCounterGetSwizzled(), ThreadCounterIsValid(), ThreadCounterNewObject(), ThreadCounterSet()
property ThreadStack as Ens.BPL.Stack;
This holds the stack of thread classes being generated. There is at minimum a single thread class which implements the top-level activities of the process.
Property methods: ThreadStackGet(), ThreadStackGetSwizzled(), ThreadStackIsValid(), ThreadStackNewObject(), ThreadStackSet()

Methods (Including Private)

private method %OnNew(initvalue As %CacheString) as %Status
Initialize the compiler
classmethod CompileStream(pStream As %BinaryStream, pPackage As %String) as %Status
Parse the BPL contained in the supplied stream and generate/compile the resulting Business Process and its supporting Classes. The Package parameter must contain the name of the cache package prefix which will be prepended to the names of the generated classes
method CreateAlarmCall(Output pCall As Ens.BPL.Call, pCallName As %String, pDuration As %String, pUntil As %String = "") as