Rendering Configuration Stylesheet

When rendering a document, Expere loads the configuration stylesheet from the data model at the current precedence level. It is loaded in the same way any other content pieces are loaded meaning that the stylesheet itself may be broken into smaller pieces. Once the stylesheet is loaded, the PackageDoc for the current document is fed in as the source to the transformation. The stylesheet will use the various pieces of information in the PackageDoc to decide what renderer to use. Once a renderer is determined, an XML fragment is built that corresponds to the proper renderer.

Consider this example. Below is a sample document, sample stylesheet, and the output that dictates that the DynamicPDFRenderer will be invoked with the ExpereStandard stylesheet:

<PackageDoc>
<DocDescriptor>
.
.
<DocType>Dynamic</DocType>
.
</DocDescriptor>
<DocWorkOrder>
.
.
<DocFormat>PDF</DocFormat>
<DocStyle>ExpereStandard</DocStyle>
.
</DocWorkOrder>
</PackageDoc>
Example PackageDoc
<xsl:stylesheet>
.
.
<xsl:template match="PackageDoc>
<xsl:choose>
<xsl:when test="DocWorkOrder/DocFormat = 'PDF'">
<xsl:choose>
<xsl:when test="DocDescriptor/DocType = 'Dynamic'">
<DynamicPDFRenderer>
<StylesheetName>
<xsl:value-of select="DocWorkOrder/DocStyle"/>
</StylesheetName>
</DynamicPDFRenderer>
</xsl:when>
.
.
</xsl:choose>
.
.
</xsl:when>
.
.
</xsl:choose>
</xsl:template>
</xsl:stylesheet>
Example Stylesheet
<DynamicPDFRenderer>
<StylesheetName>ExpereStandard</StylesheetName>
<DynamicPDFRenderer>
Example Output