svn commit: r560940 - in /lenya/docu/src/documentation/content/xdocs/docs/2_0_x/reference/protocols: index.xml lenya-document.xml lenya.xml lenyadoc.xml site.xml

[email protected]
Newsgroups gmane.comp.cms.lenya.cvs
Message-ID <[email protected]>
Author: nettings
Date: Mon Jul 30 05:29:20 2007
New Revision: 560940

URL: http://svn.apache.org/viewvc?view=rev&rev=560940
Log:
updated protocols documentation.
marked lenyadoc: as deprecated in favour of lenya-protocol:.
please review for correctness.


Added:
    lenya/docu/src/documentation/content/xdocs/docs/2_0_x/reference/protocols/lenya-document.xml
      - copied, changed from r560922, lenya/docu/src/documentation/content/xdocs/docs/2_0_x/reference/protocols/site.xml
Modified:
    lenya/docu/src/documentation/content/xdocs/docs/2_0_x/reference/protocols/index.xml
    lenya/docu/src/documentation/content/xdocs/docs/2_0_x/reference/protocols/lenya.xml
    lenya/docu/src/documentation/content/xdocs/docs/2_0_x/reference/protocols/lenyadoc.xml
    lenya/docu/src/documentation/content/xdocs/docs/2_0_x/reference/protocols/site.xml

Modified: lenya/docu/src/documentation/content/xdocs/docs/2_0_x/reference/protocols/index.xml
URL: http://svn.apache.org/viewvc/lenya/docu/src/documentation/content/xdocs/docs/2_0_x/reference/protocols/index.xml?view=diff&rev=560940&r1=560939&r2=560940
==============================================================================
--- lenya/docu/src/documentation/content/xdocs/docs/2_0_x/reference/protocols/index.xml (original)
+++ lenya/docu/src/documentation/content/xdocs/docs/2_0_x/reference/protocols/index.xml Mon Jul 30 05:29:20 2007
@@ -21,13 +21,13 @@
   </header>
   <body>
     <p>Cocoon uses different protocols to access sources. The protocols are handled by a <code>SourceFactory</code> which resolves the
-       given URI to a source. There are two protocols specific to Lenya:
+       given URI to a source. There are a few protocols specific to Lenya:
     </p>
     <ul>
-      <li><a href="site:lenya"><code>lenya:</code></a> Get a <code>RepositorySource</code> in the context of Lenya.</li>
-      <li><a href="site:lenyadoc"><code>lenyadoc:</code></a> Get a <code>RepositorySource</code> of a specific document using the UUID.</li>
-      <li><a href="site:link-management"><code>lenya-document:</code></a> Reference a document.</li>
+      <li><a href="site:lenya-document"><code>lenya-document:</code></a> Reference a document by UUID. The swiss army knife of Lenya. Used for all internal links.</li>
       <li><a href="site:siteprotocol"><code>site:</code></a> Get a <code>RepositorySource</code> using the path of a document in the site structure.</li>
+      <li><a href="site:lenya"><code>lenya:</code></a> Get a <code>RepositorySource</code> in the context of Lenya. Used mainly internally.</li>
+      <li><em>deprecated</em> <a href="site:lenyadoc"><code>lenyadoc:</code></a> Get a <code>RepositorySource</code> of a specific document using the UUID.</li>
     </ul>
   </body>
 </document>

Copied: lenya/docu/src/documentation/content/xdocs/docs/2_0_x/reference/protocols/lenya-document.xml (from r560922, lenya/docu/src/documentation/content/xdocs/docs/2_0_x/reference/protocols/site.xml)
URL: http://svn.apache.org/viewvc/lenya/docu/src/documentation/content/xdocs/docs/2_0_x/reference/protocols/lenya-document.xml?view=diff&rev=560940&p1=lenya/docu/src/documentation/content/xdocs/docs/2_0_x/reference/protocols/site.xml&r1=560922&p2=lenya/docu/src/documentation/content/xdocs/docs/2_0_x/reference/protocols/lenya-document.xml&r2=560940
==============================================================================
--- lenya/docu/src/documentation/content/xdocs/docs/2_0_x/reference/protocols/site.xml (original)
+++ lenya/docu/src/documentation/content/xdocs/docs/2_0_x/reference/protocols/lenya-document.xml Mon Jul 30 05:29:20 2007
@@ -17,51 +17,17 @@
 <!DOCTYPE document PUBLIC "-//APACHE//DTD Documentation V2.0//EN" "http://forrest.apache.org/dtd/document-v20.dtd">
 <document> 
   <header> 
-    <title>site: Protocol</title> 
+    <title>lenya-document: Protocol</title> 
   </header>
   <body>
     <p>
-      The <code>site:</code> protocol allows to access the source of a Lenya document without knowing the
-      underlying storage structure. If the relative syntax is used, only the language and the path of
-      the document in the site structure are needed.
-      If the absolute syntax is used, the publication id and the area has to be specified additionally.
+      The <code>lenya-document:</code> protocol allows to access the source of a Lenya document <strong>by
+      its UUID, publication ID, area, language and revision</strong>, regardless of the sitetree layout.
+      All Lenya-internal links use it, so that links will not break when documents are moved around
+      in the sitetree. 
+    </p>
+    <p>
+      Since it is such a fundamental concept, it is documented in detail under <a href="site:link-management">Link Management</a>.
     </p>
-    <section>
-      <title>Relative Syntax</title>
-      <p>
-        The relative syntax is used to access Lenya documents in the current context, i.e. the
-        current publication and area is used to resolve the document's location.
-      </p>
-      <p>
-        <em>Syntax: </em><code>site:/&lt;language&gt;&lt;path&gt;</code>
-      </p>
-      <p>
-        <strong>Example</strong>
-      </p>
-<source xml:space="preserve"><![CDATA[
-<!-- match authoring/{path}_{language}.html -->
-<map:match pattern="authoring/**_*.html">
-  <map:generate src="site:/{2}/{1}"/>
-  ...
-</map:match>
-]]></source>
-    </section>
-    <section>
-      <title>Absolute Syntax</title>
-      <p>
-        The absolute syntax allows to specify the document's publication and the area.
-      </p>
-      <p>
-        <em>Syntax: </em><code>site://&lt;publication&gt;/&lt;area&gt;/&lt;language&gt;&lt;path&gt;</code>
-      </p>
-      <p><strong>Example</strong></p>
-<source><![CDATA[
-<!-- match {pubId}/{area}/{path}_{language}.html -->
-<map:match pattern="*/*/**_*.html">
-  <map:generate src="site://{1}/{2}/{4}/{3}"/>
-  ...
-</map:match>
-]]></source>
-    </section>
   </body>
 </document>

Modified: lenya/docu/src/documentation/content/xdocs/docs/2_0_x/reference/protocols/lenya.xml
URL: http://svn.apache.org/viewvc/lenya/docu/src/documentation/content/xdocs/docs/2_0_x/reference/protocols/lenya.xml?view=diff&rev=560940&r1=560939&r2=560940
==============================================================================
--- lenya/docu/src/documentation/content/xdocs/docs/2_0_x/reference/protocols/lenya.xml (original)
+++ lenya/docu/src/documentation/content/xdocs/docs/2_0_x/reference/protocols/lenya.xml Mon Jul 30 05:29:20 2007
@@ -22,9 +22,10 @@
   <body>
     <p>
       The <code>lenya:</code> protocol creates a <a href="http://lenya.apache.org/apidocs/1.4/org/apache/lenya/cms/cocoon/source/RepositorySource.html">
-      <code>RepositorySource</code></a> which is a transactionable source
+      <code>RepositorySource</code></a>, which is a 
       <a href="http://lenya.apache.org/apidocs/1.4/org/apache/lenya/cms/cocoon/source/TransactionableSource.html"><code>TransactionableSource</code></a>.
-      The resolution of the URI is based on the <code>context:</code> protocol handler.
+      The resolution of the URI is based on the <code>context:</code> protocol
+      handler, i.e. you are accessing files under the webapp base directory.
     </p>
   </body>
 </document>

Modified: lenya/docu/src/documentation/content/xdocs/docs/2_0_x/reference/protocols/lenyadoc.xml
URL: http://svn.apache.org/viewvc/lenya/docu/src/documentation/content/xdocs/docs/2_0_x/reference/protocols/lenyadoc.xml?view=diff&rev=560940&r1=560939&r2=560940
==============================================================================
--- lenya/docu/src/documentation/content/xdocs/docs/2_0_x/reference/protocols/lenyadoc.xml (original)
+++ lenya/docu/src/documentation/content/xdocs/docs/2_0_x/reference/protocols/lenyadoc.xml Mon Jul 30 05:29:20 2007
@@ -20,6 +20,11 @@
     <title>lenyadoc: Protocol</title> 
   </header>
   <body>
+    <warning>
+      The <code>lenyadoc:</code> protocol is deprecated and being phased out in favour of the much more
+      versatile <a href="site:lenya-document"><code>lenya-document:</code> protocol.<br />
+      New code should not use it anymore. This documentation remains here to help people make sense of legacy code.
+    </warning>
     <p>
       The <code>lenyadoc:</code> protocol allows to access the source of a Lenya document without knowing the
       underlying storage structure. If the relative syntax is used, only the language and the UUID

Modified: lenya/docu/src/documentation/content/xdocs/docs/2_0_x/reference/protocols/site.xml
URL: http://svn.apache.org/viewvc/lenya/docu/src/documentation/content/xdocs/docs/2_0_x/reference/protocols/site.xml?view=diff&rev=560940&r1=560939&r2=560940
==============================================================================
--- lenya/docu/src/documentation/content/xdocs/docs/2_0_x/reference/protocols/site.xml (original)
+++ lenya/docu/src/documentation/content/xdocs/docs/2_0_x/reference/protocols/site.xml Mon Jul 30 05:29:20 2007
@@ -21,7 +21,7 @@
   </header>
   <body>
     <p>
-      The <code>site:</code> protocol allows to access the source of a Lenya document without knowing the
+      The <code>site:</code> protocol allows to access the source of a Lenya document <strong>by its sitetree path</strong> without knowing the
       underlying storage structure. If the relative syntax is used, only the language and the path of
       the document in the site structure are needed.
       If the absolute syntax is used, the publication id and the area has to be specified additionally.
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.