cocoon-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Bernhard Huber" <bh22...@i-one.at>
Subject more docs
Date Sun, 02 Sep 2001 21:03:30 GMT
Hi
As I was trying using cocoon2 generators, I missed docs about
profile generator, and more detailed docs about directory generator,
and status generator.
Profile Generator is a great tool, but w/o docs nearly no one
will use it.

I added documentation. 
I made diffs to xdocs of snapshot xml-cocoon2_20010809161514,
hope it helps using all the great code.

cvs diff directory-generator.xml docs-book.xml generators.xml site-
book.xml status-generator.xml (in directory D:\projects\apache-xml\xml-
cocoon2\xdocs)
Index: directory-generator.xml
===================================================================
RCS file: d:\cvsroot/xml-cocoon2/xdocs/directory-generator.xml,v
retrieving revision 1.1.1.1
diff -r1.1.1.1 directory-generator.xml
17,37c17,39
<  <p>
<  The root node of the generated document will normally be a
<  <code>directory</code> node, and a directory node can contain zero
<  or more <code>file</code> or <code>directory</code> nodes. A
file 
node has no
<  children. Each node will contain the following attributes:</p>
<    <ul>
< 	<li>name : the name of the file or directory</li>
<       <li>lastModified : the time the file was last modified, 
measured as the number of
<    milliseconds since the epoch (as in java.io.File.lastModified)</li>
<       <li>date (optional) : the time the file was last modified in 
human-readable form</li>
<    </ul>
< 	<p>All generated elements have the namespace
<          <code>http://apache.org/cocoon/directory/2.0</code>. The 
root <code>directory</code>
<          node has the attribute <code>requested</code> with the value 
<code>true</code>.</p>
< 			<ul>
< 				<li>Name : directory</li>
< 				<li>Class: 
org.apache.cocoon.generation.DirectoryGenerator</li>
< 				<li>Cacheable: no.</li>
< 			</ul>
< <source>
<      <![CDATA[
---
>       <p>
>         The root node of the generated document will normally be a
>         <code>directory</code> node, and a directory node can contain 
zero
>         or more <code>file</code> or <code>directory</code> nodes.
A 
file node has no
>         children. Each node will contain the following attributes:
>       </p>
>       <ul>
>         <li>name : the name of the file or directory</li>
>         <li>lastModified : the time the file was last modified, 
measured as the number of
>         milliseconds since the epoch (as in java.io.File.lastModified)
</li>
>         <li>date (optional) : the time the file was last modified in 
human-readable form</li>
>       </ul>
>       <p>All generated elements have the namespace
>         <code>http://apache.org/cocoon/directory/2.0</code>.
>         The root <code>directory</code>
>         node has the attribute <code>requested</code> with the value 
<code>true</code>.
>       </p>
>       <ul>
>         <li>Name : directory</li>
>         <li>Class: 
org.apache.cocoon.generation.DirectoryGenerator</li>
>         <li>Cacheable: no.</li>
>       </ul>
> <source><![CDATA[
39,40c41
<      ]]>
< </source>
---
> ]]></source>
42,56c43,96
< <s1 title="Configuration">
< <p>The following parameter can be specified in the pipeline for 
<    the generate command:</p>
< <ul>
< <li>depth (optional) : Sets how deep Directory Generator should delve 
into the
<  directory structure. If set to 1 (the default), only the starting
<  directory's immediate contents will be returned.</li>
< <li>dateFormat (optional) :  Sets the format for the date attribute 
of each node, as
<  described in java.text.SimpleDateFormat. If unset, the default
<  format for the current locale will be used.</li>
< <li>root (optional) : The root pattern</li>
< <li>include (optional) : The include pattern</li>
< <li>exclude (optional) : The exclude pattern</li>
< </ul>
< </s1>
---
>     <s1 title="Configuration">
>       <p>The following parameter can be specified in the pipeline for 
>          the generate command:
>       </p>
>       <ul>
>         <li>depth (optional) : Sets how deep Directory Generator 
should delve into the
>          directory structure. If set to 1 (the default), only the 
starting
>          directory's immediate contents will be returned.</li>
>         <li>dateFormat (optional) :  Sets the format for the date 
attribute of each node, as
>          described in java.text.SimpleDateFormat. If unset, the 
default
>          format for the current locale will be used.</li>
>         <li>root (optional) : The root pattern</li>
>         <li>include (optional) : The include pattern</li>
>         <li>exclude (optional) : The exclude pattern</li>
>       </ul>
>     </s1>
>     <s1 title="DTD">
>       <p>XML generated by directory generator uses namespace
>         <code>http://apache.org/cocoon/status/2.0</code>. The DTD
>         of XML generated by directory generator:
>       </p>
> <source><![CDATA[
>   <!ELEMENT directory (directory|file)*>
>   <!ATTLIST directroy
>     name         CDATA #REQUIRED
>     lastModified CDATA #REQUIRED
>     date         CDATA #IMPLIED
>     requested    CDATA #IMPLIED>
>   
>   <!ELEMENt file #EMPTY>
>   <!ATTLIST file
>     name         CDATA #REQUIRED
>     lastModified CDATA #REQUIRED
>     date         CDATA #IMPLIED>
> ]]></source>
>     </s1>
>     <s1 title="Example">
>       <p>
>         The current directory generator may generate following xml:
>       </p>
> <source><![CDATA[
> <directory xmlns="http://apache.org/cocoon/directory/2.0" 
>   name="stylesheets" lastModified="999425490000" 
>   date="02.09.01 12:11" 
>   requested="true">
>   <directory name="sites" 
>     lastModified="999425490000" date="02.09.01 12:11"/>
>   <file name="dynamic-page2html.xsl" 
>     lastModified="999425490000" date="02.09.01 12:11"/>
>   <file name="simple-xml2html.xsl" 
>     lastModified="999425490000" date="02.09.01 12:11"/>
> </directory>
> ]]></source>
>     </s1>
Index: docs-book.xml
===================================================================
RCS file: d:\cvsroot/xml-cocoon2/xdocs/docs-book.xml,v
retrieving revision 1.1.1.2
diff -r1.1.1.2 docs-book.xml
30a31
>   <hidden id="profile-generator" label="Profile Generator" 
source="profile-generator.xml"/>
Index: generators.xml
===================================================================
RCS file: d:\cvsroot/xml-cocoon2/xdocs/generators.xml,v
retrieving revision 1.1.1.2
diff -r1.1.1.2 generators.xml
37a38
> 				<li><link href="profile-
generator.html">Profile Generator</link></li>
Index: site-book.xml
===================================================================
RCS file: d:\cvsroot/xml-cocoon2/xdocs/site-book.xml,v
retrieving revision 1.1.1.2
diff -r1.1.1.2 site-book.xml
33a34
>   <hidden id="profile-generator" label="Profile Generator" 
source="profile-generator.xml"/>
Index: status-generator.xml
===================================================================
RCS file: d:\cvsroot/xml-cocoon2/xdocs/status-generator.xml,v
retrieving revision 1.1.1.1
diff -r1.1.1.1 status-generator.xml
37a38,62
>                 <s1 title="DTD">
>                 <p>XML generated by status generator uses namespace 
>                   <code>http://apache.org/cocoon/status/2.0</code>. 
The DTD of XML
>                   generated by status generator:
>                 </p>
> <source><![CDATA[
> <!ELEMENT statusinfo (group|value)*>
> 
> <!ATTLIST statusinfo
>    date CDATA #IMPLIED
>    host CDATA #IMPLIED
> >
> 
> <!ELEMENT group (group|value)*>
> <!ATTLIST group
>    name CDATA #IMPLIED
> >
> 
> <!ELEMENT value (line)+>
> <!ATTLIST value
>    name CDATA #REQUIRED
> 
> <!ELEMENT line (#PCDATA)+>
> ]]></source>
>                 </s1>

*****CVS exited normally with code 1*****



Mime
View raw message