| Field Summary | |
|---|---|
| static jsx3.amp.ExtProc | Processes an extension by intepreting each child element of the XML extension declaration as code to evaluate. |
| static jsx3.amp.ExtProc | Processes an extension by intepreting each child element of the XML extension declaration as code to evaluate. |
| static jsx3.amp.ExtProc | Processes an extension by intepreting each child element of the XML extension declaration as code to evaluate. |
| Method Summary | |
|---|---|
| static void | Registers a processor factory. |
| static void | Creates a processor object from a |
| static jsx3.amp.ExtProc | newDescrProc(objClass : String | jsx3.lang.Class | Function) Creates a new extension processor that creates instances of a certain class. |
| static jsx3.$Array | Processes a list of extensions using the visitor pattern. |
| Methods Inherited From jsx3.lang.Object |
|---|
| clone, equals, eval, getClass, getInstanceOf, getInstanceOfClass, getInstanceOfPackage, instanceOf, isInstanceOf, isSubclassOf, jsxmix, jsxsuper, jsxsupermix, setInstanceOf, toString |
| Field Detail |
|---|
this.getPlugIn()
grants access in the script to the plug-in defining the extension.
No value is returned from the extension processing. If the load attribute of the eval
element is equal to "true" then the plug-in owning the extension is loaded before the script is evaluated.
Therefore, the script may be evaluated either synchronously or asynchronously, but since there is no value returned
from the processing, there is no way of knowing which one actually occurred.
this.getPlugIn()
grants access in the script to the plug-in defining the extension.
The value that the script evaluates to is returned from the extension processing.
this.getPlugIn()
grants access in the script to the plug-in defining the extension.
The value returned from the extension processing is an asynchronous return value as defined in the contract for
jsx3.$Y(). The return value may be notified either asynchronously or synchronously, depending on
whether the load attribute of the eval element is equal to "true". If it is, then
the plug-in owning the extension is loaded first and then the script is evaluated asynchronously. The asynchronous
return value is notified of completion with the value that the script evaluates to.
| Method Detail |
|---|
<processor> is found as a child of an <extension-point> element. Each processor element must
declare a type attribute. The factory that has been registered with the matching type is used to create
the processor. The method signature of the factory method is:
function(xml : jsx3.amp.XML) : jsx3.amp.ExtProc where xml is the XML representation
of the <processor> element.<processor> element.<processor> element.<processor> element.function init(ext : jsx3.amp.Ext, xml : jsx3.amp.XML).
The processing visitor will create a new instance of objClass for each child element of each
extension. If any child element defines a ext-class attribute, this is interpreted as the
fully-qualified class name of a subclass of objClass. This class, if it is defined, will be used
instead of objClass to process that particular child element.arrExt, this
method iterates over each child element of the extension declaration and invokes objVisitor for
each element. At each iteration the visitor is passed as arguments the extension object and an XML object
representing the child element.process(ext : jsx3.amp.Ext, data: jsx3.amp.XML) : Object or the function itself.