%XGEN.AbstractSequence
Class %XGEN.AbstractSequence Extends (%XGEN.AbstractNode, %XGEN.AbstractGroup) [ Abstract, Inheritance = right, System = 3 ]
Note: This class is included because it is needed by other parts of the library. You should not use this or any other class within this package within your applications as a future version will be incompatible. If you are interested in this functionality please contact InterSystems.
This is the base class for sequences within an XGEN document.
See %XGEN.AbstractDocument for an overview of XGEN.
A sequence is a container that can hold one or more nodes within an XGEN document. A sequence does the following:
- optionally Generates one or more lines of code before processing its children.
- Loops over the child nodes within the sequence and asks each one to generate code in turn.
- optionally Generates one or more lines of code after processing its children.
To create a new sequence within a XGEN document, create a subclass of this class and override the %OnBeforeGenerateCode and %OnAfterGenerateCode methods to generate sequence-specific code.
Note that a subclass can prevent its child nodes from being processed by setting the skipChildren property to 1 in its %OnBeforeGenerateCode method.