XSLT & Layout

The OpenHierarchy framework conforms to the MVC architectural pattern and separates the concerns of representing information from interacting with it.


A transformation scheme showing how HTML/XHTML, PDF documents or other views can be generated with XML data from module responses togheter with instructions from XSLT stylesheets

A common way of representing data is by the use of XML, and each module* can be configured with XSLT stylesheets in order to supply instructions for how the view of its data should be produced. The framework core will assemble all such instructions for all the modules affecting the view at any given moment, and handle the transformations of the complete user interface.

Commonly, the web application supplies XSLT stylesheets dictating the overall structural layout of the view, and CSS stylesheets for describing the look and formatting. The structural layout contains slots where any output from the modules are to be inserted. This way, each module output can be addressed by the core to the appropriate part of the view. However, in cases where XML representations of data and XSLT transformations aren't suitable, module responses can carry pure HTML or other views that will be appended directly to the user interface without further transformations.

Requests are propagated to the modules by the framework core as ordinary method calls. These calls carry both the original request and response objects as arguments. Thereby, the receiving module is able to access the output stream directly instead of delegating the output processing to the core through module responses. This can be desirable for binary streaming or for returning json or xml data representations expected by for example ajax clients.

*) Stylesheets are not applicable for filter modules which does not affect the view