Home > Class Reference > ENSLIB namespace > %ZEN.Mojo.Component.contentProvider

%ZEN.Mojo.Component.contentProvider

class %ZEN.Mojo.Component.contentProvider extends %ZEN.Component.composite

This class is used internally by InterSystems. You should not make direct use of it within your applications. There is no guarantee made about either the behavior or future operation of this class.

A content provider supplies a given base page with the information needed to display dynamic content including data and layout documents and client-side behaviors.
Basically this is a composite group containing multiple JSON providers and logic for client-side caching of the data served by the providers.
The list of provider to create is defined by the providerList.
There is always a pre-defined JSON provider, named "$code" to handle coded values.
In addition to the JSON providers, this component creates an instance of a %ZEN.Mojo.Component.contentTemplate class. This provides a way to inject dynamic behavior (i.e. methods) into a page without having to reload the entire page.

Property Inventory (Including Private)

Method Inventory (Including Private)

Parameters

parameter DEFAULTVISIBLE = 0;
This component is not visible.
parameter NAMESPACE = http://www.intersystems.com/zen/mojo;
Inherited description: This is the XML namespace used for library components.
parameter SYSMODULE = core;
Inherited description: If set, this indicates that this system component should be placed in the given "module". A module is a grouping of components within the same class package that share common include (js or css) files. Note that certain root classes are implicitly placed within the "core" module.
Classes outside of the Zen library should not set this, they should use the MODULE instead.

Properties (Including Private)

property OnGetCodeTable as %ZEN.Datatype.delegator (FORMALSPEC = "&pParameters:%String,*pObject:%RegisteredObject", RETURNTYPE = "%Status", ZENENCRYPT = 0);
Similar to the JSON provider's OnGetTargetObject callback. This callback is invoked to fetch the contents of a given code table.
Property methods: OnGetCodeTableDisplayToLogical(), OnGetCodeTableGet(), OnGetCodeTableIsValid(), OnGetCodeTableLogicalToDisplay(), OnGetCodeTableLogicalToOdbc(), OnGetCodeTableNormalize(), OnGetCodeTableSet()
property OnGetTemplateList as %ZEN.Datatype.delegator (FORMALSPEC = "&pParameters:%String,*pMetaData,*pData", RETURNTYPE = "%Status", ZENENCRYPT = 0);
Similar to the JSON provider's OnGetArray callback. This callback is invoked to fetch a list of available template classes along with a logical name and other data. This information can be used to drive an application menu from a set of templates.
Property methods: OnGetTemplateListDisplayToLogical(), OnGetTemplateListGet(), OnGetTemplateListIsValid(), OnGetTemplateListLogicalToDisplay(), OnGetTemplateListLogicalToOdbc(), OnGetTemplateListNormalize(), OnGetTemplateListSet()
property currTemplate as %ZEN.Datatype.string [ InitialExpression = "$default" ];
Name (key) of current template object.
Property methods: currTemplateDisplayToLogical(), currTemplateGet(), currTemplateIsValid(), currTemplateLogicalToDisplay(), currTemplateLogicalToOdbc(), currTemplateNormalize(), currTemplateSet()
property layout as %ZEN.Datatype.string (MAXLEN = 250, ZENENCRYPT = 0) [ InitialExpression = ..#DEFAULTLAYOUT ];
Specifies how components within this group should be layed out. (VALUELIST = ",vertical,horizontal")
Property methods: layoutDisplayToLogical(), layoutGet(), layoutIsValid(), layoutLogicalToDisplay(), layoutLogicalToOdbc(), layoutNormalize(), layoutSet()
property providerList as %ZEN.Datatype.csv;
Csv-list of json providers to create.
Property methods: providerListDisplayToLogical(), providerListGet(), providerListIsValid(), providerListLogicalToDisplay(), providerListLogicalToOdbc(), providerListNormalize(), providerListSet()
property templateClass as %ZEN.Datatype.className;
Initial template class.
Property methods: templateClassArrayBuildValueArray(), templateClassArrayCollectionToDisplay(), templateClassArrayCollectionToOdbc(), templateClassArrayDisplayToCollection(), templateClassArrayDisplayToLogical(), templateClassArrayGet(), templateClassArrayGetObject(), templateClassArrayGetObjectId(), templateClassArrayGetSwizzled(), templateClassArrayIsValid(), templateClassArrayLogicalToDisplay(), templateClassArrayLogicalToOdbc(), templateClassArrayNormalize(), templateClassArrayOdbcToCollection(), templateClassArraySet(), templateClassArraySetObject(), templateClassArraySetObjectId(), templateClassDisplayToLogical(), templateClassGet(), templateClassIsValid(), templateClassLogicalToDisplay(), templateClassLogicalToOdbc(), templateClassNormalize(), templateClassSet()
property templateClassArray as array of %ZEN.Datatype.className (XMLPROJECTION = "none");
Names of loaded contentTemplate classes supplying the content, indexed by key.
Property methods: templateClassArrayBuildValueArray(), templateClassArrayCollectionToDisplay(), templateClassArrayCollectionToOdbc(), templateClassArrayDisplayToCollection(), templateClassArrayDisplayToLogical(), templateClassArrayGet(), templateClassArrayGetObject(), templateClassArrayGetObjectId(), templateClassArrayGetSwizzled(), templateClassArrayIsValid(), templateClassArrayLogicalToDisplay(), templateClassArrayLogicalToOdbc(), templateClassArrayNormalize(), templateClassArrayOdbcToCollection(), templateClassArraySet(), templateClassArraySetObject(), templateClassArraySetObjectId()
property templateObjectArray as array of contentTemplate (XMLPROJECTION = "none");
Loaded template object(s), indexed by key.
Property methods: templateObjectArrayBuildValueArray(), templateObjectArrayCollectionToDisplay(), templateObjectArrayCollectionToOdbc(), templateObjectArrayDisplayToCollection(), templateObjectArrayGet(), templateObjectArrayGetObject(), templateObjectArrayGetObjectId(), templateObjectArrayGetSwizzled(), templateObjectArrayIsValid(), templateObjectArrayOdbcToCollection(), templateObjectArraySet(), templateObjectArraySetObject(), templateObjectArraySetObjectId()

Methods (Including Private)

private final method %LayoutChildren(pTuple As %Integer = "")
Does the actual work of laying out the children of this group. pTuple indicates the current tuple number in the case of a repeatingGroup.
final method %OnAfterCreateComposite() as %Status
Add children to this component.
method %OnGetProviderList(Output pList As %List) as %Status
Return a list defining what JSON providers should be created by this provider.
Returns:
pList(n) = $LB(name,[class])
final method GetJSONCodeTable(ByRef pParms, Output pObject As %RegisteredObject) as %Status [ ZenMethod ]