dleslie     00/10/16 09:48:13

  Modified:    java/xdocs/sources/xalan BUGS commandline.xml getstarted.xml
                        readme.xml resources.xml samples.xml
                        usagepatterns.xml whatsnew.xml
  Log:
  Review draft for Xalan-J 2.0.D01
  
  Revision  Changes    Path
  1.2       +10 -6     xml-xalan/java/xdocs/sources/xalan/BUGS
  
  Index: BUGS
  ===================================================================
  RCS file: /home/cvs/xml-xalan/java/xdocs/sources/xalan/BUGS,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -r1.1 -r1.2
  --- BUGS      2000/09/15 19:03:20     1.1
  +++ BUGS      2000/10/16 16:48:06     1.2
  @@ -1,10 +1,14 @@
   <s3 title="Open bugs and bug reporting">
  -<p>Open bugs:</p>
  -
  - <p>Outstanding bugs are recorded in the Apache XML <jump 
href="http://xml.apache.org/bugs/";>Bug Tracking System</jump>. 
  -  If you find a bug, please use this system to report it.</p> 
  -  <note>If the Apache XML Bug Tracking System is not working, please report 
the bug to the
  -  <human-resource-ref idref="xalandev"/>.</note>
  +<p>We are aware of the following limitations and problems in this alpha 
release:</p>
  +<ul>
  +<li>The processor cannot yet handle XML source documents with stylesheet 
processing instructions. You must explicitly indicate the styleshee when you 
perform a transformation.t<br/><br/></li>
  +<li>??<br/><br/></li>
  +<li>??<br/><br/></li>
  +<li><br/><br/></li>
  +<li><br/><br/></li>
  +<li><br/><br/></li>
  +</ul>
  +<p>The Apache XML Bug Tracking System is currently not working. If you find 
a bug, please report it (with "Xalan-J 2 bug" in the subject line) to the 
<human-resource-ref idref="xalandev"/>.</p>
   </s3>
   
   
  
  
  
  1.4       +1 -10     xml-xalan/java/xdocs/sources/xalan/commandline.xml
  
  Index: commandline.xml
  ===================================================================
  RCS file: /home/cvs/xml-xalan/java/xdocs/sources/xalan/commandline.xml,v
  retrieving revision 1.3
  retrieving revision 1.4
  diff -u -r1.3 -r1.4
  --- commandline.xml   2000/10/12 15:34:17     1.3
  +++ commandline.xml   2000/10/16 16:48:06     1.4
  @@ -112,15 +112,6 @@
         <p>Use -HTML to write 4.0 transitional HTML (some elements, such as 
&lt;br&gt;, are
         not well formed XML.</p>
         <p>To set stylesheet parameters from the command line, use <br/>
  -      <code>TestXSLT -PARAM <ref>name expression</ref></code><br/>
  -      To set the parameter to a string value, enclose the string in single 
quotes (') to
  -      make it an expression.</p>
  -      <p><anchor name="compiledstylesheet"/><em>Using a compiled 
stylesheet</em></p>
  -        <p>If you are using a stylesheet repeatedly, you can improve 
performance by compiling the stylesheet the first time
  -          you use it and using the compiled stylesheet for subsequent 
transformations.</p>
  -        <p>For example, the following command line performs a transformation 
and compiles the stylesheet:"<br/><br/>
  -      <code>java org.apache.xalan.xslt.Process -in foo.xml -xsl foo.xsl 
-lxcout foo.style</code><br/><br/>
  -      The following command line uses the compiled stylesheet for the next 
transformation:<br/><br/>
  -      <code>java org.apache.xalan.xslt.Process -in foo2.xml -lxcin 
foo.style</code></p>
  +      <code>TestXSLT -PARAM <ref>name expression</ref></code></p>
      </s2>
   </s1>
  
  
  
  1.4       +5 -5      xml-xalan/java/xdocs/sources/xalan/getstarted.xml
  
  Index: getstarted.xml
  ===================================================================
  RCS file: /home/cvs/xml-xalan/java/xdocs/sources/xalan/getstarted.xml,v
  retrieving revision 1.3
  retrieving revision 1.4
  diff -u -r1.3 -r1.4
  --- getstarted.xml    2000/10/12 15:34:17     1.3
  +++ getstarted.xml    2000/10/16 16:48:07     1.4
  @@ -15,7 +15,7 @@
   <ul>
   <li>The JDK or JRE 1.1.8 or 1.2.2</li>
   <li>xalan.jar</li>
  -<li>xerces.jar</li>
  +<li>xerces.jar (or another <link idref="usagepatterns" 
anchor="xmlreader">XMLReader</link>)</li>
   </ul>
   <p>You can get the JDK or JRE from <jump 
href="http://www.ibm.com/java/jdk";>ibm.com/java/jdk/</jump> or <jump 
href="http://www.java.sun.com";>java.sun.com</jump>.</p> 
   <p>Download <resource-ref idref="xslt4j-dist-zip"/> or <resource-ref 
idref="xslt4j-dist-targz"/>. Both of these files contain <resource-ref 
idref="xslt4j-current"/> (with xalan.jar) and xerces.jar from <resource-ref 
idref="xml4j-used"/>. You can use a zip or tar utility to expand these files 
into a full build.</p>
  @@ -53,11 +53,11 @@
   <p>You can start by using your own XML source files and XSL stylesheets with 
the sample applications, which illustrate a number of the <link 
idref="usagepatterns">basic usage patterns</link>.</p>
   <p>Here is the basic TRaX procedure to keep in mind when you set up a 
transformation:</p>
   <ol>
  -<li>Use trax.Processor.newInstance("xslt") to instantiate a stylesheet 
processor -- a TRaX <jump href="apidocs/trax/Processor.html">Processor</jump> 
object implemented by the Xalan <jump 
href="apidocs/org/apache/xalan/processor/StylesheetProcessor.html">StylesheetProcessor</jump>.<br/><br/></li>
  -<li>Use the Processor process() or processFromNode() method to process the 
stylesheet (a SAX InputSource or DOM Node) and generate a Templates object -- a 
TRaX <jump href="apidocs/trax/Templates.html">Templates</jump> object 
implemented by the Xalan <jump 
href="apidocs/org/apache/xalan/processor/StylesheetRoot.html">StylesheetRoot</jump><br/><br/></li>
  +<li>Use org.apache.trax.Processor.newInstance("xslt") to instantiate a 
stylesheet processor -- a TRaX <jump 
href="apidocs/org/apache/trax/Processor.html">Processor</jump> object 
implemented by the Xalan <jump 
href="apidocs/org/apache/xalan/processor/StylesheetProcessor.html">StylesheetProcessor</jump>.<br/><br/></li>
  +<li>Use the Processor process() or processFromNode() method to process the 
stylesheet (a SAX InputSource or DOM Node) and generate a Templates object -- a 
TRaX <jump href="apidocs/org/apache/trax/Templates.html">Templates</jump> 
object implemented by the Xalan <jump 
href="apidocs/org/apache/xalan/processor/StylesheetRoot.html">StylesheetRoot</jump><br/><br/></li>
   <li>Use the Templates newTransformer() method to instantiate a Transformer 
-- a TRaX
  -<jump href="apidocs/trax/Transformer.html">Transformer</jump> object 
implemented by the Xalan <jump 
href="apidocs/org/apache/xalan/transformer/TransformerImpl.html">TransformerImpl</jump>.<br/><br/></li>
  -<li>Use one of the Transformer transform() or transformNode() methods to 
apply the Templates object to an XML document (a SAX InputSource or DOM Node) 
and perform the transformation, placing the output in a TRaX <jump 
href="apidocs/trax/Result.html">Result</jump> object.</li>
  +<jump href="apidocs/org/apache/trax/Transformer.html">Transformer</jump> 
object implemented by the Xalan <jump 
href="apidocs/org/apache/xalan/transformer/TransformerImpl.html">TransformerImpl</jump>.<br/><br/></li>
  +<li>Use one of the Transformer transform() or transformNode() methods to 
apply the Templates object to an XML document (a SAX InputSource or DOM Node) 
and perform the transformation, placing the output in a TRaX <jump 
href="apidocs/org/apache/trax/Result.html">Result</jump> object.</li>
   </ol>
   <p>For more information about this procedure and its variations, see <link 
idref="usagepatterns">Basic Usage Patterns</link>.</p>
   </s2>
  
  
  
  1.4       +28 -29    xml-xalan/java/xdocs/sources/xalan/readme.xml
  
  Index: readme.xml
  ===================================================================
  RCS file: /home/cvs/xml-xalan/java/xdocs/sources/xalan/readme.xml,v
  retrieving revision 1.3
  retrieving revision 1.4
  diff -u -r1.3 -r1.4
  --- readme.xml        2000/10/12 15:34:17     1.3
  +++ readme.xml        2000/10/16 16:48:07     1.4
  @@ -66,17 +66,17 @@
     <li><link anchor="status">Status</link></li>
     <li><link anchor="build">Build Notes</link></li>
     <li><link anchor="contact">Getting in touch</link></li>
  -  <li><link anchor="history">History of software changes</link></li>
  +  <!--li><link anchor="history">History of software changes</link></li-->
    </ul>
     <s2 title="Status">
      <ul>
  -    <li><link anchor="done">Changes since version 1.2.D01</link></li>    
  +    <!--li><link anchor="done">Changes since version 2.0.D01</link></li-->   
 
       <li><link anchor="bugs">Open bugs and bug reporting</link></li>
       <li><link anchor="status">Version of Xerces to use</link></li>
       <li><link anchor="to-do">To-do tasks for future &xslt4j; 
releases</link></li>
      </ul>
  -     <anchor name="done"/>
  -     &done-j;     
  +     <!--anchor name="done"/>
  +     &done-j;   -->  
        <anchor name="bugs"/>
        &bugs-j;
        <anchor name="status"/>
  @@ -98,7 +98,6 @@
        Windows32 batch file (build.bat) and a UNIX shell file (build.sh). The 
build file defines the "targets" that you can use Ant
        to build. The batch and shell files set up the classpath and launch Ant 
with the target (and any other arguments) you
        provide.</p>
  -     <note>We still use makefiles to build the distribution copy of 
&xslt4j;.</note>
        <p><em>Instructions for using Ant</em></p>
        <ol>
          <li>Set the JAVA_HOME environment variable to the JDK root 
directory.<br/><br/>
  @@ -179,28 +178,28 @@
          <li>To build the API documentation, run the JDK 1.2.2 javadoc tool 
from the xdocs directory:<br/><br/>
   <code>
   javadoc -doclet xalanjdoc.Standard -docletpath ../bin/xalanjdoc.jar -private
  --overview ../src/javadocOverview.html -sourcepath ../src 
  --group TrAX "trax" 
  --group Xalan_Core "org.apache.xalan.processor:org.apache.xalan.templates:
  -org.apache.xalan.transformer"
  --group XPath "org.apache.xpath*:org.w3c.xslt" 
  --group Xalan_Other "org.apache.xalan.client:org.apache.xalan.dtm:
  -org.apache.xalan.extensions:org.apache.xalan.res:org.apache.xalan.stree:
  -org.apache.xalan.trace:org.apache.xalan.utils" 
  --group Xalan_Extensions "org.apache.xalan.lib*" 
  --group Serializers "serialize*" 
  --group Xalan-Java_1_Interface "org.apache.xalan.xslt:org.apache.xalan.xpath" 
  -org.apache.xalan.client org.apache.xalan.dtm org.apache.xalan.extensions 
  -org.apache.xalan.lib org.apache.xalan.lib.sql org.apache.xalan.processor 
  -org.apache.xalan.res org.apache.xalan.stree org.apache.xalan.templates 
  -org.apache.xalan.trace org.apache.xalan.transformer org.apache.xalan.utils 
  -org.apache.xalan.xpath org.apache.xalan.xpath.xml org.apache.xalan.xslt 
  -org.apache.xpath org.apache.xpath.axes org.apache.xpath.compiler 
  -org.apache.xpath.functions org.apache.xpath.objects 
org.apache.xpath.operations 
  -org.apache.xpath.patterns org.apache.xpath.res org.w3c.xslt 
  -serialize serialize.helpers trax 
  --d ../build/docs/apidocs -windowtitle "Xalan-Java 2" -doctitle "Xalan-Java 2"
  --bottom "Copyright &#169; 2000 Apache XML Project. All Rights Reserved."
  + -overview ../src/javadocOverview.html -sourcepath ../src 
  + -group TrAX "org.apache.trax" 
  + -group Xalan_Core "org.apache.xalan.processor:org.apache.xalan.templates:
  + org.apache.xalan.transformer"
  + -group XPath "org.apache.xpath*:org.w3c.xslt" 
  + -group Xalan_Other "org.apache.xalan.client:org.apache.xalan.dtm:
  + org.apache.xalan.extensions:org.apache.xalan.res:org.apache.xalan.stree:
  + org.apache.xalan.trace:org.apache.xalan.utils:org.apache.xalan.xslt" 
  + -group Xalan_Extensions "org.apache.xalan.lib*" 
  + -group Serializers 
"org.apache.serialize*:org.apache.xml.serialize.transition" 
  + org.apache.xalan.client org.apache.xalan.dtm org.apache.xalan.extensions 
  + org.apache.xalan.lib org.apache.xalan.lib.sql org.apache.xalan.processor 
  + org.apache.xalan.res org.apache.xalan.stree org.apache.xalan.templates 
  + org.apache.xalan.trace org.apache.xalan.transformer org.apache.xalan.utils 
  + org.apache.xalan.xslt 
  + org.apache.xpath org.apache.xpath.axes org.apache.xpath.compiler 
  + org.apache.xpath.functions org.apache.xpath.objects 
org.apache.xpath.operations 
  + org.apache.xpath.patterns org.apache.xpath.res org.w3c.xslt 
  + org.apache.serialize org.apache.serialize.helpers 
org.apache.xml.serialize.transition 
  + org.apache.trax 
  + -d ../build/docs/apidocs -windowtitle "Xalan-Java 2" -doctitle "Xalan-Java 
2"
  + -bottom "Copyright &#169; 2000 Apache XML Project. All Rights Reserved."
   </code></li>
   </ul>
     </s3>    
  @@ -208,9 +207,9 @@
    <s2 title="Getting in Touch">
     <p>Your feedback is more than welcome. Offers of help are even more so! 
Perhaps you would like to take on an active role in the ongoing development, 
testing, and documentation of &xslt4j;?</p> 
   <p>Please email your comments, questions, suggestions, and offers to join 
the Xalan team to <human-resource-ref idref="xalandev"/>.</p>
  - </s2><anchor name="history"/>
  + </s2><!--anchor name="history"/>
    <s2 title="Cumulative history of software changes">
      <note>We started tracking the changes in earlier releases beginning with 
&xslt4j; version 1.1.</note>
   
  - </s2>
  + </s2-->
   </s1>
  
  
  
  1.2       +1 -1      xml-xalan/java/xdocs/sources/xalan/resources.xml
  
  Index: resources.xml
  ===================================================================
  RCS file: /home/cvs/xml-xalan/java/xdocs/sources/xalan/resources.xml,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -r1.1 -r1.2
  --- resources.xml     2000/09/15 19:03:20     1.1
  +++ resources.xml     2000/10/16 16:48:07     1.2
  @@ -53,7 +53,7 @@
   
     <resource id="trax" 
               title="TRaX (Transformations for XML)" 
  -            location="http://trax.openxml.org/"/>
  +            
location="apidocs/org/apache/xalan/trax/package-summary.html#package_description"/>
     <resource id="dom" 
               title="DOM" 
               location="http://www.w3.org/DOM"/>
  
  
  
  1.9       +2 -2      xml-xalan/java/xdocs/sources/xalan/samples.xml
  
  Index: samples.xml
  ===================================================================
  RCS file: /home/cvs/xml-xalan/java/xdocs/sources/xalan/samples.xml,v
  retrieving revision 1.8
  retrieving revision 1.9
  diff -u -r1.8 -r1.9
  --- samples.xml       2000/10/12 15:34:17     1.8
  +++ samples.xml       2000/10/16 16:48:08     1.9
  @@ -223,8 +223,8 @@
         <p>What it does: Uses the Redirect extension elements shipped with 
&xslt4j; to direct output to two output
           files.</p>
         <p>Run this sample from the extensions subdirectory with</p> 
  -       <p><code>java org.apache.xalan.xslt.Process -in 1-redir.xml</code></p>
  -       <p>&nbsp;&nbsp;<code>-xsl 1-redir.xsl</code></p>
  +       <p><code>java org.apache.xalan.xslt.Process -in 
1-redir.xml</code><br/>
  +       &nbsp;&nbsp;<code>-xsl 1-redir.xsl</code></p>
         <p>The standard (non-redirected) output is writen to the screen. The 
redirected output is written to 1-redir-out, or
         whatever filename you assign to the doc/foo @file attribute in 
1-redir.xml. The stylesheet gets the file name for
         redirected output from the XML input file.</p>
  
  
  
  1.6       +45 -40    xml-xalan/java/xdocs/sources/xalan/usagepatterns.xml
  
  Index: usagepatterns.xml
  ===================================================================
  RCS file: /home/cvs/xml-xalan/java/xdocs/sources/xalan/usagepatterns.xml,v
  retrieving revision 1.5
  retrieving revision 1.6
  diff -u -r1.5 -r1.6
  --- usagepatterns.xml 2000/10/12 15:34:17     1.5
  +++ usagepatterns.xml 2000/10/16 16:48:08     1.6
  @@ -82,25 +82,26 @@
     </ol>
       <p>The following example highlights the four basic steps involved in 
performing a transformation.</p>
       <source>// 1. Instantiate a stylesheet Processor.
  -trax.Processor processor = trax.Processor.newInstance("xslt");
  +org.apache.trax.Processor processor = 
  +                          org.apache.trax.Processor.newInstance("xslt");
   
   // 2. Process the stylesheet, producing a Templates object.
  -trax.Templates templates = processor.process
  -&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;(new 
org.xml.sax.InputSource("foo.xsl"));
  +org.apache.trax.Templates templates = processor.process
  +                               (new org.xml.sax.InputSource("foo.xsl"));
   
   // 3. Use the Templates object to instantiate a Transformer.
  -trax.Transformer transformer = templates.newTransformer();
  +org.apache.trax.Transformer transformer = templates.newTransformer();
   
   // 4. Use the Transformer to apply the Templates object to an XML
   //&nbsp;&nbsp;&nbsp;&nbsp;source and send the output to a Result object.
   transformer.transform
  -&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;(new 
org.xml.sax.InputSource("foo.xml"), 
  -&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;new 
trax.Result(new java.io.FileWriter("foo.out")));</source>
  +      ( new org.xml.sax.InputSource("foo.xml"), 
  +        new org.apache.trax.Result(new java.io.FileWriter("foo.out")) 
);</source>
     <note>For a working example of this model at its simplest, see 
SimpleTransform.java in the java/samples/SimpleTransform subdirectory.</note>
     </s2><anchor name="processor"/>
     <s2 title="1. Instantiate a stylesheet Processor">
  -  <p>The trax.Processor static newInstance() method with "xslt" as its 
argument instantiates the processor designated by the trax.processor.xslt 
system property.</p>
  -  <p>If this system property has not already been set, trax.Processor sets 
it from a file.</p>
  +  <p>The org.apache.trax.Processor static newInstance() method with "xslt" 
as its argument instantiates the processor designated by the 
org.apache.trax.processor.xslt system property.</p>
  +  <p>If this system property has not already been set, 
org.apache.trax.Processor sets it from org/apache/trax/trax.properties (in 
xalan.jar).</p>
     <p>For &xslt4j;, this system property should be set to 
org.apache.xalan.processor.StylesheetProcessor.</p>
   </s2><anchor name="process"/>
     <s2 title="2. Process the stylesheet, producing a Templates object">
  @@ -109,12 +110,12 @@
   <p>A given Templates object may be used repeatedly and by multiple 
concurrent threads for the transformation of XML input.</p>
     <p>You may provide the stylesheet as a SAX input source (from a file or 
stream) or as a DOM tree.</p>
     <p>Use the Processor process() method with a SAX input source (as in the 
example above), or the processFromNode() method with a DOM tree to generate a 
Templates object.</p>
  -<p>To perform this operation with a SAX input source, the processor uses a 
trax.TemplatesBuilder (extending the SAX ContentHandler interface) and a SAX 
XMLReader.</p>
  +<p>To perform this operation with a SAX input source, the processor uses a 
org.apache.trax.TemplatesBuilder (extending the SAX ContentHandler interface) 
and a SAX XMLReader.</p>
   <p>The XMLReader parses the input, sending parse events to the 
TemplatesBuilder, which responds by building the Templates object.</p>
   <p>If you use the processFromNode() method with a DOM representation of the 
stylesheet, the processor traverses the DOM, sending SAX events to the 
TemplatesBuilder.</p>
   </s2><anchor name="transformer"/>
   <s2 title="3. Instantiate a Transformer">
  -<p>To transform an XML document, you need an implementation of the 
trax.Transformer interface.</p>
  +<p>To transform an XML document, you need an implementation of the 
org.apache.trax.Transformer interface.</p>
   <note>&xslt4j; implements the Transformer interface with 
org.apache.xalan.transformer.TransformerImpl.</note>
   <p>You can use a Templates object for multiple transformations (even 
performed concurrently), but you should use the Templates object to instantiate 
a separate Transformer for each transformation you perform. The Templates 
object contains the stylesheet structure and data and XSLT schema, which are 
immutable, whereas the Transformer tracks state information as it performs the 
transformation.</p>
   </s2><anchor name="transformation"/>
  @@ -122,7 +123,7 @@
   <p>Supply the XML input, a target or "holder" for the transformation output, 
and instruct the Transformer to perform the transformation.</p>
   <p>Just as with the stylesheet, you can supply the XML input in the form of 
a SAX input source (from a URL or stream) or a DOM tree.</p>
   <p>Use the Transformer transform() method with a SAX input source (as in the 
example above), or the transformNode() method with a DOM tree to perform the 
transformation.</p>
  -<p>TRaX provides the holder for the output: trax.Result. You can set up a 
Result object to send the transformation result to a file or stream or to build 
a DOM tree.</p>
  +<p>TRaX provides the holder for the output: org.apache.trax.Result. You can 
set up a Result object to send the transformation result to a file or stream or 
to build a DOM tree.</p>
   <p>The Transformer uses the XMLParser to parse the XML input and sends parse 
events to a SAX ContentHandler, which assembles the input into a DOM tree. Of 
course this operation is unnecessary if the XML input is submitted as a DOM.</p>
   <p>For each node in the XML source, the Transformer uses the Templates 
object to determine which template to apply: one of the templates in the 
Templates object, a default template rule as specified in the XSLT spec, or 
none.</p>
   <p>The Transformer forwards the SAX events produced by this process to the 
appropriate output ContentHandler, a serializer if the Result object has been 
set up to write to a stream or file, a DOMBuilder utility if the output is to 
be a DOM tree.</p>
  @@ -134,17 +135,17 @@
   <ul>
     <li>Set the org.xml.sax.driver system property.<br/><br/>
     You can set system properties from the command line or within your 
application. You can also edit the setting in 
org/apache/xalan/res/XSLTInfo.properties (in xalan.jar). If the 
org.xml.sax.driver system property is not set, &xslt4j; uses this file to set 
it.<br/><br/></li>
  -  <li>Call the trax.Processor.setXMLReader() method.<br/><br/>
  -  If you call this method before you call trax.Processor.process() to 
generate a Templates object, &xslt4j; uses the XMLReader you designate to 
process the stylesheet and the XML input, and ignores the org.xml.sax.driver 
property setting (for the current transformation).<br/><br/></li>
  +  <li>Call the org.apache.trax.Processor.setXMLReader() method.<br/><br/>
  +  If you call this method before you call 
org.apache.trax.Processor.process() to generate a Templates object, &xslt4j; 
uses the XMLReader you designate to process the stylesheet and the XML input, 
and ignores the org.xml.sax.driver property setting (for the current 
transformation).<br/><br/></li>
   </ul>
   <p>Be sure the XMLReader is on the classpath. The &xml4j; XMLReader -- 
org.apache.xerces.parsers.SAXParser -- is in xerces.jar.(</p>
  -<note>Other system properties: The default serializer system property 
settings are in serialize/serializer.properties. The default XSLT stylesheet 
system property setting is in org/apache/xalan/res/XSLTInfo.properties (not in 
trax/trax.properties??). These properties files are in xalan.jar.</note>
  +<note>Other system properties: The default serializer system property 
settings are in org/apache/serialize/serializer.properties. The default XSLT 
stylesheet system property setting is in  org/apache/trax/trax.properties. 
These properties files are in xalan.jar.</note>
   </s2><anchor name="params"/>
   <s2 title="Setting stylesheet parameters">
  -<p>An XSLT stylesheet may include parameters that are set at run time each 
time a transformation takes place. To set a stylesheet parameter, use the 
trax.Transformer <jump 
href="apidocs/trax/Transformer.html#setParameter(java.lang.String,java.lang.String,java.lang.Object)">setParameter(String
 name, String namespace, Object value)</jump> method. If the parameter QName 
only includes a local name (as is often the case), the namespace argument is 
null. For a working example, see UseStylesheetParam.java in the  
java/samples/UseStylesheetParam subdirectory.</p>
  +<p>An XSLT stylesheet may include parameters that are set at run time each 
time a transformation takes place. To set a stylesheet parameter, use the 
org.apache.trax.Transformer <jump 
href="apidocs/org/apache/trax/Transformer.html#setParameter(java.lang.String,java.lang.String,java.lang.Object)">setParameter(String
 name, String namespace, Object value)</jump> method. If the parameter QName 
only includes a local name (as is often the case), the namespace argument is 
null. For a working example, see UseStylesheetParam.java in the  
java/samples/UseStylesheetParam subdirectory.</p>
   <p>You can also set a parameter with the command-line utility by including 
the -param flag. For example:</p>
  -<p><code>java org.apache.xalan.xslt.Process -in foo.xml -xsl foo.xsl -param 
param1 boo</code></p>
  -<p>where <code>param</code> is the parameter name and <code>boo</code> is 
the parameter value. The parameter namespace is null.</p>
  +<p><code>java org.apache.xalan.xslt.Process -in foo.xml -xsl foo.xsl -param 
param1 foobar</code></p>
  +<p>where <code>param</code> is the parameter name and <code>foobar</code> is 
the parameter value. The parameter namespace is null.</p>
   </s2><anchor name="embed"/>
   <s2 title="Working with embedded stylesheets">
   <p>An XML source document may include an <jump 
href="http://www.w3.org/TR/xml-stylesheet/";>xml-stylesheet processing 
instruction</jump> which identifies the stylesheet to be used to process the 
document. As indicated by the processing instruction href attribute, the 
stylesheet itself may be embedded in the XML document or located elsewhere.</p>
  @@ -153,7 +154,8 @@
   <p>The following fragment, uses this instruction to locate the stylesheet 
(foo.xsl in the same directory) and create a Templates object. Note the use of 
the Processor getAssociatedStylesheets() and processMultipleStylesheets() 
methods in steps 2a and 2b.</p>
   <note>An XML document may include more than one xml-stylesheet processing 
instruction, hence the support for working with multiple stylesheets. If more 
than one stylesheet is returned, the other stylesheets are imported into the 
first stylesheet [awaiting clarification from the W3C].</note>
   <source>// 1. Instantiate the stylesheet processor.
  -trax.Processor processor = trax.Processor.newInstance("xslt");
  +org.apache.trax.Processor processor = 
  +                            org.apache.trax.Processor.newInstance("xslt");
   
   // 2a. Get the stylesheet(s) from the XML source (the source may contain
   //     more than one xml-stylesheet processing instruction).
  @@ -161,31 +163,33 @@
   org.xml.sax.InputSource[] stylesheet = processor.getAssociatedStylesheets
                         (new InputSource("foo.xml"), media, title, charset);
   // 2b. Process the stylesheet(s), producing a Templates object.
  -trax.Templates templates = processor.processMultiple(stylesheet);
  +org.apache.trax.Templates templates = processor.processMultiple(stylesheet);
   
   // 3. Use the Templates object to instantiate a Transformer.
  -trax.Transformer transformer = templates.newTransformer();
  +org.apache.trax.Transformer transformer = templates.newTransformer();
   
   // 4. Use the Transformer to apply the Templates object to an XML
   //&nbsp;&nbsp;&nbsp;&nbsp;source and send the output to a Result object.
   transformer.transform
   &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;(new 
org.xml.sax.InputSource("foo.xml"), 
  -&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;new 
trax.Result(new java.io.FileWriter("foo.out")));</source>
  +&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;new 
org.apache.trax.Result(new java.io.FileWriter("foo.out")));</source>
   </s2><anchor name="sax"/>
   <s2 title="Explicitly working with SAX">
     <p>&xslt4j; uses the SAX event model to process stylesheets, to parse XML 
input documents, and to produce output. For each of these operations, an 
XMLReader reads input, firing parse events, and a ContentHandler listens to the 
XMLReader and performs parse event methods.</p>
   <p>When you use the basic procedure described above for performing 
transformations, &xslt4j; takes care of many of the SAX details under the 
covers. You are free to make these details explicit, which simply means that 
you can intervene in the procedure to accommodate any custom conditions in 
which your application operates.</p>
  -<p>Suppose, for example, you are using a custom XMLReader (perhaps doing 
more than just parsing static XML documents) to generate &xslt4j; SAX parse 
events. You can instruct the Transformer to provide the ContentHandler for this 
XMLReader. You might even have a custom reader for producing/processing 
stylesheets, in which case you simply set the trax.TemplatesBuilder 
(implemented by the org.apache.xalan.processor.StylesheetHandler) as the 
ContentHandler for this reader.</p>
  +<p>Suppose, for example, you are using a custom XMLReader (perhaps doing 
more than just parsing static XML documents) to generate &xslt4j; SAX parse 
events. You can instruct the Transformer to provide the ContentHandler for this 
XMLReader. You might even have a custom reader for producing/processing 
stylesheets, in which case you simply set the org.apache.trax.TemplatesBuilder 
(implemented by the org.apache.xalan.processor.StylesheetHandler) as the 
ContentHandler for this reader.</p>
     <p>The following example explicitly sets up the XMLReader and 
ContentHandlers, and replicates the <link anchor="basic">basic steps</link> 
described above.</p>
     <source>// 1. Instantiate  stylesheet processor.
  -trax.Processor processor = trax.Processor.newInstance("xslt");
  +org.apache.trax.Processor processor = 
  +                          org.apache.trax.Processor.newInstance("xslt");
   
   // 2. Process the stylesheet. producing a Templates object.
   // Get the XMLReader.
   org.xml.sax.XMLReader reader = 
  -                  org.xml.sax.helpers.XMLReaderFactory.createXMLReader();
  +                 org.xml.sax.helpers.XMLReaderFactory.createXMLReader();
   // Set the ContentHandler.
  -trax.TemplatesBuilder templatesBuilder = processor.getTemplatesBuilder();
  +org.apache.trax.TemplatesBuilder templatesBuilder = 
  +                                         processor.getTemplatesBuilder();
   reader.setContentHandler(templatesBuilder);
   // Set the ContentHandler to also function as a LexicalHandler, which
   // includes "lexical" (e.g., comments and CDATA) events. The Xalan
  @@ -197,19 +201,20 @@
   // Parse the stylesheet.                       
   reader.parse("foo.xsl");
   //Get the Templates object from the ContentHandler.
  -trax.Templates templates = templatesBuilder.getTemplates();
  +org.apache.trax.Templates templates = templatesBuilder.getTemplates();
   
   // 3. Use the Templates object to instantiate a Transformer.
  -trax.Transformer transformer = templates.newTransformer();
  +org.apache.trax.Transformer transformer = templates.newTransformer();
   
   // 4. Perform the transformation.
   // Set up the ContentHandler (a serializer) for the output.
  -trax.Result result = new trax.Result(new java.io.FileWriter("foo.out"));
  +org.apache.trax.Result result = 
  +          new org.apache.trax.Result(new java.io.FileWriter("foo.out"));
   org.apache.xml.serialize.SerializerFactory sfactory = 
  -      org.apache.xml.serialize.SerializerFactory.getSerializerFactory("xml");
  +  org.apache.xml.serialize.SerializerFactory.getSerializerFactory("xml");
   org.apache.xml.serialize.Serializer serializer = sfactory.makeSerializer
  -                               (result.getCharacterStream(), 
  -                                new org.apache.xml.serialize.OutputFormat());
  +                         ( result.getCharacterStream(), 
  +                           new org.apache.xml.serialize.OutputFormat() );
   transformer.setContentHandler(serializer.asContentHandler());
   // Set up the ContentHandler for the input.
   org.xml.sax.ContentHandler chandler = transformer.getInputContentHandler();
  @@ -225,25 +230,25 @@
   <s2 title="Using transformation output as input for another transformation">
   <p>You can chain together a series of two or more transformations such that 
the output of one transformation provides input for the another transformation. 
&xslt4j; supports two basic strategies for chaining a series of 
transformations:</p>
   <ul>
  -  <li><br/>A Transformer uses a SAX ContentHandler to process input, and 
another ContentHandler to process output. Along these lines, you can use the 
Transformer getInputContentHandler() method to make one Transformer the 
ContentHandler for the XMLReader that parses the input, then use the same 
method make a second Transformer the ContentHandler for the output of the first 
Transformer, and so on. For more detail and an example, see the <link 
idref="samples" anchor="pipe">Pipe</link> sample.<br/><br/></li>
  +  <li>A Transformer uses a SAX ContentHandler to process input, and another 
ContentHandler to process output. Along these lines, you can use the 
Transformer getInputContentHandler() method to make one Transformer the 
ContentHandler for the XMLReader that parses the input, then use the same 
method make a second Transformer the ContentHandler for the output of the first 
Transformer, and so on. For more detail and an example, see the <link 
idref="samples" anchor="pipe">Pipe</link> sample.<br/><br/></li>
     <li>A Transformer extends the SAX XMLFilter interface. Using the 
setParent() method this interface supplies, you can set an XMLReader as the 
parent of the Transformer for the first transformation, then set this 
Transformer as the parent for the Transformer performing the second 
transformation, and so on. You launch the series by instructing the last 
Transformer to parse the input. For more detail and an example, see the <link 
idref="samples" anchor="usexmlfilters">UseXMLFilters</link> sample.</li>
   </ul>
   </s2><anchor name="dom"/>
   <s2 title="Processing and producing DOM trees">
     <p>In some cases, the input and/or desired output for a transformation may 
be a DOM tree object,  rather than a file or stream.</p>
  -<p>To process DOM input, use one of the trax.Transformer <jump 
href="apidocs/trax/Transformer.html#transformNode(org.w3c.dom.Node, 
trax.Result)">transformNode()</jump> methods.</p>
  +<p>To process DOM input, use one of the org.apache.trax.Transformer <jump 
href="apidocs/org/apache/trax/Transformer.html#transformNode(org.w3c.dom.Node, 
org.apache.trax.Result)">transformNode()</jump> methods.</p>
     <p>To produce a transformation result in the form of a DOM tree, use the 
<jump href="http://java.sun.com/xml/docs/api/index.html";>Java API for XML 
Parsing</jump> as indicated below to instantiate an empty DOM Document to hold 
the result tree.</p>
     <ol>
       <li>The javax.xml.parsers.DocumentBuilderFactory abstract class contains 
a static newInstance() method for instantiating a factory designated by the 
javax.xml.parsers.DocumentBuilderFactory system property.<br/><br/></li>
       <li>In turn, the factory provides a newDocumentBuilder() method with 
which you instantiate a DocumentBuilder.<br/><br/></li>
       <li>Use the DocumentBuilder to instantiate an empty DOM 
Document.<br/><br/></li>
  -    <li>Use this DOM Document node to construct the trax.Result object for 
the transformation result tree.</li>
  +    <li>Use this DOM Document node to construct the org.apache.trax.Result 
object for the transformation result tree.</li>
     </ol>
   <source>javax.xml.parsers.DocumentBuilderFactory dfactory =
                         javax.xml.parsers.DocumentBuilderFactory.newInstance();
   javax.xml.parsers.DocumentBuilder docBuilder = dfactory.newDocumentBuilder();
   org.w3c.dom.Document resultDoc = docBuilder.newDocument();
  -trax.Result result = new trax.Result(resultDoc);
  +org.apache.trax.Result result = new org.apache.trax.Result(resultDoc);
   </source>
   </s2><anchor name="xpath"/>
   <s2 title="Working with XPath expressions">
  @@ -307,10 +312,10 @@
   ptl.m_traceTemplates = true;
   
   // Set up the transformation
  -traxProcessor processor = trax.Processor.newInstance("xslt");
  -trax.Templates templates = processor.process
  +traxProcessor processor = org.apache.trax.Processor.newInstance("xslt");
  +org.apache.trax.Templates templates = processor.process
   &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;(new 
org.xml.sax.InputSource("foo.xsl"));
  -trax.Transformer transformer = templates.newTransformer();
  +org.apache.trax.Transformer transformer = templates.newTransformer();
   
   // Cast the Transformer object as TransformerImpl.
   if (transformer instanceof TransformerImpl) {
  @@ -324,8 +329,8 @@
     // Perform the transformation --printing information to
     // the events log during the process.
     transformer.transform
  -  &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;(new 
org.xml.sax.InputSource("foo.xml"), 
  -  &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;new 
trax.Result(new java.io.FileWriter("foo.out")));
  +      ( new org.xml.sax.InputSource("foo.xml"), 
  +        new org.apache.trax.Result(new java.io.FileWriter("foo.out")) );
   }
   // Close the PrintWriter and FileWriter.
   pw.close();
  
  
  
  1.10      +3 -3      xml-xalan/java/xdocs/sources/xalan/whatsnew.xml
  
  Index: whatsnew.xml
  ===================================================================
  RCS file: /home/cvs/xml-xalan/java/xdocs/sources/xalan/whatsnew.xml,v
  retrieving revision 1.9
  retrieving revision 1.10
  diff -u -r1.9 -r1.10
  --- whatsnew.xml      2000/10/12 15:34:17     1.9
  +++ whatsnew.xml      2000/10/16 16:48:08     1.10
  @@ -81,7 +81,7 @@
                <label><jump
        
href="apidocs/org/apache/xalan/processor/package-summary.html">org.apache.xalan.processor</jump></label>
 
                <item>Processes the stylesheet and produces the Templates 
object. This package is responsible for
  -    implementing the <jump 
href="apidocs/trax/Processor.html">trax.Processor</jump> abstract class, which 
  +    implementing the <jump 
href="apidocs/org/apache/trax/Processor.html">org.apache.trax.Processor</jump> 
abstract class, which 
       provides the primary entry point into &xslt4j;.</item> 
         </gloss> 
         <gloss> 
  @@ -89,13 +89,13 @@
        
href="apidocs/org/apache/xalan/templates/package-summary.html">org.apache.xalan.templates</jump></label>
 
                 <item>Defines the structure and content of a stylesheet tree 
(which may include multiple imported and
       included stylesheets). This package is responsible for implementing the 
<jump
  -    href="apidocs/trax/Templates.html">trax.Templates</jump> 
interface.</item> 
  +    
href="apidocs/org/apache/trax/Templates.html">org.apache.trax.Templates</jump> 
interface.</item> 
         </gloss> 
         <gloss> 
                <label><jump
       
href="apidocs/org/apache/xalan/transformer/package-summary.html">org.apache.xalan.transformer</jump></label>
 
                <item>Applies the Templates object to the XML source and 
produces the result tree. This package is
  -     responsible for implementing the <jump 
href="apidocs/trax/Transformer.html">trax.Transformer</jump>
  +     responsible for implementing the <jump 
href="apidocs/org/apache/trax/Transformer.html">org.apache.trax.Transformer</jump>
        interface.</item> 
         </gloss> 
         <gloss> 
  
  
  

Reply via email to