Sophie

Sophie

distrib > Mageia > 7 > i586 > by-pkgid > b3bdfe6d859a3d6920ff2c44b38e9a6f > files > 37

saxon-manual-9.4.0.9-2.mga7.noarch.rpm

<?xml version="1.0" encoding="iso-8859-1"?>
<?xml-stylesheet href="../../make-menu.xsl" type="text/xsl"?><html>
   <head>
      <this-is section="changes" page="intro" subpage="xt30-94"/>
      <!--
           Generated at 2011-12-09T20:47:22.916Z--><title>Saxonica: XSLT and XQuery Processing: XSLT changes</title>
      <meta name="coverage" content="Worldwide"/>
      <meta name="copyright" content="Copyright Saxonica Ltd"/>
      <meta name="title" content="Saxonica: XSLT and XQuery Processing: XSLT changes"/>
      <meta name="robots" content="noindex,nofollow"/>
      <link rel="stylesheet" href="../../saxondocs.css" type="text/css"/>
   </head>
   <body class="main">
      <h1>XSLT changes</h1>
      <p>See also <a class="bodylink" href="../../changes/intro/xp30-94.xml">XPath 3.0 changes</a>.</p>
      <p class="subhead">XSLT 2.0 implementation</p>
      <p>The call <code>system-property('xsl:vendor')</code> now returns the string "Saxonica". Previously it returned
                      a more complex string that also identified the product version; this information should now be obtained using the
                      XSLT 2.0 system properties such as <code>system-property('xsl:product-version')</code>. Information on the values
                      returned for each system property is at <a class="bodylink" href="../../conformance/xslt20.xml">XSLT 2.0 Conformance</a>.</p>
      <p>The handling of type errors in an <code>&lt;xsl:if&gt;</code>, or an <code>&lt;xsl:choose&gt;</code> with
                      no <code>&lt;xsl:otherwise&gt;</code> branch, has been made less draconian. If the construct appears in a context
                      where it is not allowed to return an empty sequence, the type error is no longer reported statically, but is only
                      reported if the implicit else/otherwise branch is actually taken at run-time. The immediate motivation for this
                      change is that it enables stylesheets generated using Altova's products to be executed; it also appears to be a 
                      more reasonable interpretation of the intent of the specification.</p>
      <p class="subhead">Command line</p>
      <p>The implementation of the <code>-TP</code> option on the command line, which produces a timing profile, has been rewritten.
                      Rather than producing a trace file containing all the events with timings, which could become very voluminous, it now aggregates the
                      timing data in memory, and outputs the results directly in HTML rather than requiring a separate post-processing step.</p>
      <p>On the <code>net.sf.saxon.Transform</code> command line, there is a new option <code>-threads:N</code> controlling how many
                      threads are to be used. This only has effect when the <code>-s</code> option specifies a directory. It does
             not cause individual transformations to be multi-threaded, it only causes the transformations of different files to
             run in parallel with each other.</p>
      <p>The new <code>-catalog:filename</code> option requests 
                      use of OASIS catalogs for resolving DTD references, external entity references,  URIs appearing in 
             <code>xsl:include</code> and <code>xsl:import</code> declarations, and calls to the <code>doc()</code>
             and <code>document()</code> functions.</p>
      <p>In Saxon-EE, Java bytecode is generated automatically unless suppressed using the option
             <code>--generateByteCode:off</code></p>
      <p class="subhead">XSLT 3.0 Features</p>
      <div class="boxed"
           style="border: solid thin; background-color: #B1CCC7; padding: 2px">XSLT 3.0 features are available only if XSLT 3.0 support is explicitly requested, for example by specifying
        <code>-xsltversion:3.0</code> on the command line.</div>
      <p>Maps, as defined in the draft XSLT 3.0 specification, are implemented as an extension to XPath 3.0. For details see
        <a class="bodylink" href="../../expressions/xpath30maps.xml">Maps in XPath 3.0</a>.</p>
      <p>The <code>xsl:merge</code> instruction is implemented.</p>
      <p>Pattern syntax in the form <code>~ItemType</code> is supported, for example <code>match="~xs:integer"</code>
        matches an integer. Predicates are allowed on such patterns, for example <code>~xs:integer[. gt 0]</code>.</p>
      <p>Associated with this change, <code>xsl:apply-templates</code> (as well as <code>xsl:next-match</code> and
        <code>xsl:apply-imports</code> can be used to process any kind of item, not only nodes (for example, atomic values
        or maps)</p>
      <p>Similarly, <code>xsl:for-each-group</code> with the <code>group-starting-with</code> or <code>group-ending-with</code>
        patterns can now process a sequence of atomic values.</p>
      <p>In the <code>xsl:mode</code> declaration, the values supported for the <code>on-no-match</code> attribute have
        changed, in line with changes in the XSLT 3.0 working draft. The option <code>copy</code> is renamed <code>shallow-copy</code>,
        <code>stringify</code> is renamed <code>text-only-copy</code>, and <code>discard</code> is renamed <code>deep-skip</code>. Two
        new options are added: <code>deep-copy</code> and <code>shallow-skip</code>.</p>
      <p>When <code>xsl:copy</code> is used with a <code>select</code> attribute (new feature in XSLT 3.0), the
        context item for evaluation of the contained sequence constructor is now the item selected by the <code>select</code>
        attribute.</p>
      <p>The <code>intersect</code> and <code>except</code> operators can now be used in match patterns; multiple operators
        and parentheses are allowed. Parentheses are also allowed around an expression that is then filtered by
        a predicate, for example <code>match="(foo|bar)[*]"</code> or <code>(//para)[1]</code>.</p>
      <table width="100%">
         <tr>
            <td>
               <p align="right"><a class="nav" href="xt-obfuscation.xml">Next</a></p>
            </td>
         </tr>
      </table>
   </body>
</html>