Technical Overview

The Input Module

The input documents (an XML document and/or a corresponding XML schema document) are first sent to the Input Module, where the documents are parsed, and a schema is generated if one has not been passed to the system. There is an optional filtering step, so the system can process only part of a schema if required, and the last function of the input module is to create a PSVI (post-schema-validation infoset), which is used by the next stage in the process as the basis for UI generation.

The schema generation is carried out using open-source software from the Castor project. Specifically, Castor contains code (the classes org.exolab.castor.xml.schema.Schema and org.exolab.castor.xml.schema.writer.SchemaWriter;) for inspecting a well-formed XML instance document, and then automatically generating a corresponding W3C Schema document.

Once a schema has been passed to the input or automatically generated, the schema is parsed using code from the Apache Xerces project to create the PSVI (specifically, the package org.apache.xerces.impl.xs.psvi). Conceptually, the PSVI is somewhat analogous to a DOM representation - in the PSVI, a tree of "XSObject" objects is constructed, with each XSObject containing information about the schema element it represents, much in the same way that DOM tree "Node" objects contain information about the XML document elements they represent. This PSVI therefore contains all the schema information that is used by the business rules engine to generate the basic framework for a user interface. If an XML document was also sent to the input module, this is parsed and a corresponding DOM document created, which is passed to the business rules engine along with the PSVI.