PageRendererFactory 

Factory for page render.

Kind: global class


new PageRendererFactory(componentUtils, React) 

Initializes the factory used by the page renderer.

Param Type Description
componentUtils ComponentUtils The registry of component utilities.
React React The React framework instance to use to render the page.

pageRendererFactory._componentUtils : ComponentUtils 

The registry of component utilities.

Kind: instance property of PageRendererFactory


pageRendererFactory._React : React 

Rect framework instance, used to render the page.

Kind: instance property of PageRendererFactory
Access: protected


pageRendererFactory.getUtils() 

Return object of services which are defined for alias $Utils.

Kind: instance method of PageRendererFactory


pageRendererFactory.getDocumentView(documentView) ⇒ function 

Returns the class constructor of the specified document view component. Document view may be specified as a namespace path or as a class constructor.

Kind: instance method of PageRendererFactory
Returns: function - The constructor of the document view component.

Param Type Description
documentView function | string The namespace path pointing to the document view component, or the constructor of the document view component.

pageRendererFactory.getManagedRootView(managedRootView) ⇒ function 

Returns the class constructor of the specified managed root view component. Managed root view may be specified as a namespace path or as a class constructor.

Kind: instance method of PageRendererFactory
Returns: function - The constructor of the managed root view component.

Param Type Description
managedRootView function | string The namespace path pointing to the managed root view component, or the constructor of the React component.

pageRendererFactory._resolveClassConstructor(view) ⇒ function 

Returns the class constructor of the specified view component. View may be specified as a namespace path or as a class constructor.

Kind: instance method of PageRendererFactory
Returns: function - The constructor of the view component.

Param Type Description
view function The namespace path pointing to the view component, or the constructor of the React.Component.

pageRendererFactory.wrapView(view, props) ⇒ React.Element 

Wraps the provided view into the view adapter so it can access the state passed from controller through the props property instead of the state property.

Kind: instance method of PageRendererFactory
Returns: React.Element - View adapter handling passing the controller’s state to an instance of the specified page view through properties.

Param Type Description
view function | string The namespace path pointing to the view component, or the constructor of the React.Component.
props Object The initial props to pass to the view.

pageRendererFactory.createReactElementFactory(view) ⇒ function 

Return a function that produces ReactElements of a given type. Like React.createElement.

Kind: instance method of PageRendererFactory
Returns: function - The created factory function. The factory accepts an object containing the component’s properties as the argument and returns a rendered component.

Param Type Description
view string | function The react component for which a factory function should be created.