How SLAX Works

SLAX does not affect the expressiveness of XSLT; it only makes XSLT easier to use. The underlying SLAX constructs are completely native to XSLT. SLAX adds nothing to the XSLT engine. The SLAX parser parses an input document and builds an XML tree identical to the one produced when the XML parser reads an XSLT document.

SLAX functions as a preprocessor for XSLT. The JUNOS Software internally translates SLAX programming instructions (such as if, then, and else statements) into the equivalent XSLT instructions (such as <xsl:choose> and <xsl:if> elements). After this translation, the XSLT transformation engine—which, for the JUNOS Software, is the JUNOS management (mgd) process—is invoked.

Figure 2 shows the flow of SLAX script input and output.

Figure 2: SLAX Script Input and Output

Image g016729.gif