lenya/src/webapp/lenya/pubs/docs-new/content/xdocs/docs/concepts usecases.xml,NONE,1.1 standardURI.xml,1.2,1.3

Andreas Hartmann <[email protected]> Mon, 19 May 2003 17:49:37 +0200
Newsgroups gmane.comp.cms.wyona.cvs
Message-ID <[email protected]>
Update of /repository/lenya/src/webapp/lenya/pubs/docs-new/content/xdocs/docs/concepts
In directory erbium:/tmp/cvs-serv32008/src/webapp/lenya/pubs/docs-new/content/xdocs/docs/concepts

Modified Files:
	standardURI.xml 
Added Files:
	usecases.xml 
Log Message:
added separate usecase documentation file

--- NEW FILE: usecases.xml ---
<?xml version="1.0"?>
<!DOCTYPE document PUBLIC "-//APACHE//DTD Documentation V1.1//EN" "document-v11.dtd">
<document> 
  <header> 
    <title>Usecases</title>
    <version major="0" minor="2">Version 0.2</version>
    <authors><person name="Christian Egli" email="[email protected]"/>
      <person name="Felix Maeder" email="[email protected]"/>
      <person name="Andreas Hartmann" email="[email protected]"/>
    </authors> 
    <abstract>Description of the usecase concept and the existing usecases.</abstract> 
  </header> 
  <body> 

    <section>
      <title>Introduction</title>
      <p>
      Usecases are sequences of pages that are orthogonal to the website,
      i.e. they can be executed without leaving the current URI.
      They are mainly used to execute CMS functions, e.g., to publish a page.
      Usecases are specified by
      </p>
      <ul>
      <li>a <strong>name</strong> and</li>
      <li>a set of <strong>steps</strong>.</li>
      </ul>
      <p>
      A usecase is executed using the request parameters <code>lenya.usecase</code> and
      <code>lenya.step</code>.
      </p>
    </section>
    
    <section><title>Matching Usecases</title>
    
    <p>
    To match a usecase in a sitemap, the <code>WildcardRequestParameterMatcher</code>
    is used on the <code>lenya.usecase</code> and <code>lenya.step</code> request
    parameters. The predefined matchers have the types <code>usecase</code> and
    <code>step</code>. A simple example of a usecase pipeline would be:
    </p>
<source>
<![CDATA[<map:match type="usecase" pattern="publish">
      
  <!-- confirmation screen -->
  <map:match type="step" pattern="showscreen">
    <map:generate type="serverpages"
        src="content/publishing/publish-screen-usecase.xsp"/>
    <map:transform src="xslt/publishing/screen.xsl"/>
    <map:serialize/>
  </map:match>

  <!-- call publish task -->
  <map:match type="step" pattern="publish">
    <map:act type="task">
      <map:parameter name="publication-id" value="{../../1}"/>
      <map:parameter name="task-id" value="{request-param:task-id}"/>
      <map:redirect-to uri="{request:requestURI}" session="true"/>
    </map:act>
  </map:match>
        
</map:match>]]>
</source>
    
</section>

<section><title>The Usecase Sitemap</title>

  <p>
  The main usecase sitemap supports a set of generic usecases.
  It is located at <code>lenya/usecase.xmap</code>.
  To implement your publication-specific usecases or to override a generic
  usecase, just add a <code>usecase.xmap</code>
  sitemap to your publication directory. The Lenya usecase sitemap looks for it
  and mounts it before the generic usecases are matched.
  </p>

</section>

  <section>
    <title>Overview of use cases</title>
    <p>The following use cases are known:</p>

    <table>
      <tr>
        <th>Use case</th>
        <th><code>lenya.usecase=</code></th>
        <th><code>lenya.step=</code></th>
        <th>Comment</th>
      </tr>
      <tr>
        <td>Publish</td>
        <td>publish</td>
        <td>showscreen</td>
        <td>Confirm the publication of this document</td>
      </tr>
      <tr>
        <td></td>
        <td></td>
        <td>publish</td>
        <td>Publish this document</td>
      </tr>
      <tr>
        <td>Create</td>
        <td>create</td>
        <td>showscreen</td>
        <td>Show a form allowing to specify the parameters for
        creation of a document</td> 
      </tr>
      <tr>
        <td></td>
        <td></td>
        <td>create</td>
        <td>Create the document</td>
      </tr>
      <tr>
        <td>Resource upload</td>
        <td>upload</td>
        <td>showscreen</td>
        <td>Show a form allowing to specify the parameters for
          uploading of a resource</td>
      </tr>
      <tr>
        <td></td>
        <td></td>
        <td>upload</td>
        <td>Upload the resource</td>
      </tr>
      <tr>
        <td>Rollback</td>
        <td>rollback</td>
        <td>showscreen</td>
        <td>Show a list of all versions of this document</td>
      </tr>
      <tr>
        <td></td>
        <td></td>
        <td>view</td>
        <td>View a particular version of this document</td>
      </tr>
      <tr>
        <td></td>
        <td></td>
        <td>rollback</td>
        <td>Roll back to a particular version of this document</td>
      </tr>
      <tr>
        <td>Checkin</td>
        <td>checkin</td>
        <td>showscreen</td>
        <td>Confirm the checkin of this document</td>
      </tr>
      <tr>
        <td></td>
        <td></td>
        <td>checkin</td>
        <td></td>
      </tr>
      <tr>
        <td>Checkout</td>
        <td>checkout</td>
        <td>showscreen</td>
        <td>Confirm the checkout of this document</td>
      </tr>
      <tr>
        <td></td>
        <td></td>
        <td>checkout</td>
        <td></td>
      </tr>
      <tr>
        <td>Schedule</td>
        <td>schedule</td>
        <td>showscreen</td>
        <td>Show a list of all task scheduled for this document</td>
      </tr>
      <tr>
        <td></td>
        <td></td>
        <td>add</td>
        <td>Add a new task</td>
      </tr>
      <tr>
        <td></td>
        <td></td>
        <td>modify</td>
        <td>Modify an existing task</td>
      </tr>
      <tr>
        <td></td>
        <td></td>
        <td>delete</td>
        <td>Delete an existing task</td>
      </tr>
      <tr>
        <td>Edit</td>
        <td></td>
        <td></td>
        <td></td>
      </tr>
      <tr>
        <td>User Admin</td>
        <td>user-admin</td>
        <td>showscreen</td>
        <td>Show an overview page listing all users</td>
      </tr>
      <tr>
        <td></td>
        <td></td>
        <td>add</td>
        <td>Add a user</td>
      </tr>
      <tr>
        <td></td>
        <td></td>
        <td>modify</td>
        <td>Modify a user</td>
      </tr>
      <tr>
        <td></td>
        <td></td>
        <td>delete</td>
        <td>Delete a user</td>
      </tr>
      <tr>
        <td>Logout</td>
        <td>logout</td>
        <td>showscreen</td>
        <td>Confirm the logout</td>
      </tr>
      <tr>
        <td>View Logs</td>
        <td>view-logs</td>
        <td>overview</td>
        <td>Show the logfile list for this publication</td>
      </tr>
      <tr>
        <td>&#160;</td>
        <td>&#160;</td>
        <td>log</td>
        <td>Show a single logfile</td>
      </tr>
    </table>

    <fixme author="ce">Can the authenticate process done in a
      similar way?</fixme>

  </section>

  <section>
    <title>Use cases</title>

    <section>
      <title>Resource upload</title>

      <p><code>lenya.usecase=upload</code></p>

      <table>
        <tr>
          <th><code>lenya.step=</code></th>
          <th>additional parameters</th>
          <th>sample value</th>
        </tr>
        <tr>
          <td>showscreen</td>
          <td>xpath</td>
          <td>/NewsML/body.content/block[1]/*[1]</td>
        </tr>
        <tr>
          <td></td>
          <td>insertBefore [optional]</td>
          <td>true</td>
        </tr>

        <tr>
          <td>upload</td>
          <td>documentid</td>
          <td></td>
        </tr>
        <tr>
          <td></td>
          <td>xpath</td>
          <td></td>
        </tr>
        <tr>
          <td></td>
          <td>insertBefore [optional]</td>
          <td></td>
        </tr>
        <tr>
          <td></td>
          <td>uploadFile</td>
          <td></td>
        </tr>
        <tr>
          <td></td>
          <td>identifier [optional]</td>
          <td></td>
        </tr>
        <tr>
          <td></td>
          <td colspan="2">All Dublin core identifiers are also accepted</td>
        </tr>
      </table>
      <fixme author="ce">We assume that we can get the documentid
        from the request URI (given the standardized <link
          href="#uri_definition">URI definition</link>). Is this
        ok?</fixme>
    </section>

    <section>
      <title>Create</title>

      <p><code>lenya.usecase=create</code></p>

      <table>
        <tr>
          <th><code>lenya.step=</code></th>
          <th>additional parameters</th>
          <th>sample value</th>
        </tr>
        <tr>
          <td>showscreen</td>
          <td>parentid</td>
          <td>/dossiers/2003</td>
        </tr>
        <tr>
          <td></td>
          <td>doctype</td>
          <td>Dossier</td>
        </tr>
        <tr>
          <td>create</td>
          <td>parentid</td>
          <td></td>
        </tr>
        <tr>
          <td></td>
          <td>childid</td>
          <td></td>
        </tr>
        <tr>
          <td></td>
          <td>doctype</td>
          <td></td>
        </tr>
      </table>

    </section>

    <section>
      <title>Rollback</title>

      <p><code>lenya.usecase=rollback</code></p>

      <table>
        <tr>
          <th><code>lenya.step=</code></th>
          <th>additional parameters</th>
          <th>sample value</th>
        </tr>
        <tr>
          <td>showscreen</td>
          <td></td>
          <td></td>
        </tr>
        <tr>
          <td>view</td>
          <td>version</td>
          <td></td>
        </tr>
      </table>
    </section>

    <section>
      <title>View Logs</title>

      <p><code>lenya.usecase=view-logs</code></p>

      <table>
        <tr>
          <th><code>lenya.step=</code></th>
          <th>additional parameters</th>
          <th>sample value</th>
        </tr>
        <tr>
          <td>overview</td>
          <td></td>
          <td></td>
        </tr>
        <tr>
          <td>log</td>
          <td>logfile</td>
          <td>2003-05-13-18-34-00-314.xml</td>
        </tr>
      </table>
    </section>

    <fixme author="ce">Add remaining use cases</fixme>
  </section>
      
  </body> 
  <footer> 
    <legal>© 200 wyona.org</legal> 
  </footer>
</document>

Index: standardURI.xml
===================================================================
RCS file: /repository/lenya/src/webapp/lenya/pubs/docs-new/content/xdocs/docs/concepts/standardURI.xml,v
retrieving revision 1.2
retrieving revision 1.3
diff -C2 -d -r1.2 -r1.3
*** standardURI.xml	13 May 2003 17:26:06 -0000	1.2
--- standardURI.xml	19 May 2003 15:49:35 -0000	1.3
***************
*** 42,45 ****
--- 42,48 ----
  	    e.g. "showscreen"</dd> 
  	</dl>
+         <p>
+         For further information about usecases, see section <link href="usecases.html">Usecases</link>.
+         </p>
        </section>
        
***************
*** 102,429 ****
        consolidated and standardized.</fixme>
      </section>
      <section>
        <title>Dynamic URIs</title>
  
!       <section>
! 	<title>Overview of use cases</title>
! 	<p>The following use cases are known:</p>
! 	
! 	<table>
! 	  <tr>
! 	    <th>Use case</th>
! 	    <th><code>lenya.usecase=</code></th>
! 	    <th><code>lenya.step=</code></th>
! 	    <th>Comment</th>
! 	  </tr>
! 	  <tr>
! 	    <td>Publish</td>
! 	    <td>publish</td>
! 	    <td>showscreen</td>
! 	    <td>Confirm the publication of this document</td>
! 	  </tr>
! 	  <tr>
! 	    <td></td>
! 	    <td></td>
! 	    <td>publish</td>
! 	    <td>Publish this document</td>
! 	  </tr>
! 	  <tr>
! 	    <td>Create</td>
! 	    <td>create</td>
! 	    <td>showscreen</td>
! 	    <td>Show a form allowing to specify the parameters for
! 	    creation of a document</td> 
! 	  </tr>
! 	  <tr>
! 	    <td></td>
! 	    <td></td>
! 	    <td>create</td>
! 	    <td>Create the document</td>
! 	  </tr>
! 	  <tr>
! 	    <td>Resource upload</td>
! 	    <td>upload</td>
! 	    <td>showscreen</td>
! 	    <td>Show a form allowing to specify the parameters for
! 	      uploading of a resource</td>
! 	  </tr>
! 	  <tr>
! 	    <td></td>
! 	    <td></td>
! 	    <td>upload</td>
! 	    <td>Upload the resource</td>
! 	  </tr>
! 	  <tr>
! 	    <td>Rollback</td>
! 	    <td>rollback</td>
! 	    <td>showscreen</td>
! 	    <td>Show a list of all versions of this document</td>
! 	  </tr>
! 	  <tr>
! 	    <td></td>
! 	    <td></td>
! 	    <td>view</td>
! 	    <td>View a particular version of this document</td>
! 	  </tr>
! 	  <tr>
! 	    <td></td>
! 	    <td></td>
! 	    <td>rollback</td>
! 	    <td>Roll back to a particular version of this document</td>
! 	  </tr>
! 	  <tr>
! 	    <td>Checkin</td>
! 	    <td>checkin</td>
! 	    <td>showscreen</td>
! 	    <td>Confirm the checkin of this document</td>
! 	  </tr>
! 	  <tr>
! 	    <td></td>
! 	    <td></td>
! 	    <td>checkin</td>
! 	    <td></td>
! 	  </tr>
! 	  <tr>
! 	    <td>Checkout</td>
! 	    <td>checkout</td>
! 	    <td>showscreen</td>
! 	    <td>Confirm the checkout of this document</td>
! 	  </tr>
! 	  <tr>
! 	    <td></td>
! 	    <td></td>
! 	    <td>checkout</td>
! 	    <td></td>
! 	  </tr>
! 	  <tr>
! 	    <td>Schedule</td>
! 	    <td>schedule</td>
! 	    <td>showscreen</td>
! 	    <td>Show a list of all task scheduled for this document</td>
! 	  </tr>
! 	  <tr>
! 	    <td></td>
! 	    <td></td>
! 	    <td>add</td>
! 	    <td>Add a new task</td>
! 	  </tr>
! 	  <tr>
! 	    <td></td>
! 	    <td></td>
! 	    <td>modify</td>
! 	    <td>Modify an existing task</td>
! 	  </tr>
! 	  <tr>
! 	    <td></td>
! 	    <td></td>
! 	    <td>delete</td>
! 	    <td>Delete an existing task</td>
! 	  </tr>
! 	  <tr>
! 	    <td>Edit</td>
! 	    <td></td>
! 	    <td></td>
! 	    <td></td>
! 	  </tr>
! 	  <tr>
! 	    <td>User Admin</td>
! 	    <td>user-admin</td>
! 	    <td>showscreen</td>
! 	    <td>Show an overview page listing all users</td>
! 	  </tr>
! 	  <tr>
! 	    <td></td>
! 	    <td></td>
! 	    <td>add</td>
! 	    <td>Add a user</td>
! 	  </tr>
! 	  <tr>
! 	    <td></td>
! 	    <td></td>
! 	    <td>modify</td>
! 	    <td>Modify a user</td>
! 	  </tr>
! 	  <tr>
! 	    <td></td>
! 	    <td></td>
! 	    <td>delete</td>
! 	    <td>Delete a user</td>
! 	  </tr>
! 	  <tr>
! 	    <td>Logout</td>
! 	    <td>logout</td>
! 	    <td>showscreen</td>
! 	    <td>Confirm the logout</td>
! 	  </tr>
!           <tr>
!             <td>View Logs</td>
!             <td>view-logs</td>
!             <td>overview</td>
!             <td>Show the logfile list for this publication</td>
!           </tr>
!           <tr>
!             <td>&#160;</td>
!             <td>&#160;</td>
!             <td>log</td>
!             <td>Show a single logfile</td>
!           </tr>
! 	</table>
! 	
! 	<fixme author="ce">Can the authenticate process done in a
! 	  similar way?</fixme>
! 	
!       </section>
        
-       <section>
- 	<title>Use cases</title>
- 	
- 	<section>
- 	  <title>Resource upload</title>
- 	  
- 	  <p><code>lenya.usecase=upload</code></p>
- 	  
- 	  <table>
- 	    <tr>
- 	      <th><code>lenya.step=</code></th>
- 	      <th>additional parameters</th>
- 	      <th>sample value</th>
- 	    </tr>
- 	    <tr>
- 	      <td>showscreen</td>
- 	      <td>xpath</td>
- 	      <td>/NewsML/body.content/block[1]/*[1]</td>
- 	    </tr>
- 	    <tr>
- 	      <td></td>
- 	      <td>insertBefore [optional]</td>
- 	      <td>true</td>
- 	    </tr>
- 	    
- 	    <tr>
- 	      <td>upload</td>
- 	      <td>documentid</td>
- 	      <td></td>
- 	    </tr>
- 	    <tr>
- 	      <td></td>
- 	      <td>xpath</td>
- 	      <td></td>
- 	    </tr>
- 	    <tr>
- 	      <td></td>
- 	      <td>insertBefore [optional]</td>
- 	      <td></td>
- 	    </tr>
- 	    <tr>
- 	      <td></td>
- 	      <td>uploadFile</td>
- 	      <td></td>
- 	    </tr>
- 	    <tr>
- 	      <td></td>
- 	      <td>identifier [optional]</td>
- 	      <td></td>
- 	    </tr>
- 	    <tr>
- 	      <td></td>
- 	      <td colspan="2">All Dublin core identifiers are also accepted</td>
- 	    </tr>
- 	  </table>
- 	  <fixme author="ce">We assume that we can get the documentid
- 	    from the request URI (given the standardized <link
- 	      href="#uri_definition">URI definition</link>). Is this
- 	    ok?</fixme>
- 	</section>
- 
- 	<section>
- 	  <title>Create</title>
- 
- 	  <p><code>lenya.usecase=create</code></p>
- 
- 	  <table>
- 	    <tr>
- 	      <th><code>lenya.step=</code></th>
- 	      <th>additional parameters</th>
- 	      <th>sample value</th>
- 	    </tr>
- 	    <tr>
- 	      <td>showscreen</td>
- 	      <td>parentid</td>
- 	      <td>/dossiers/2003</td>
- 	    </tr>
- 	    <tr>
- 	      <td></td>
- 	      <td>doctype</td>
- 	      <td>Dossier</td>
- 	    </tr>
- 	    <tr>
- 	      <td>create</td>
- 	      <td>parentid</td>
- 	      <td></td>
- 	    </tr>
- 	    <tr>
- 	      <td></td>
- 	      <td>childid</td>
- 	      <td></td>
- 	    </tr>
- 	    <tr>
- 	      <td></td>
- 	      <td>doctype</td>
- 	      <td></td>
- 	    </tr>
- 	  </table>
- 
- 	</section>
- 	
- 	<section>
- 	  <title>Rollback</title>
- 
- 	  <p><code>lenya.usecase=rollback</code></p>
- 
- 	  <table>
- 	    <tr>
- 	      <th><code>lenya.step=</code></th>
- 	      <th>additional parameters</th>
- 	      <th>sample value</th>
- 	    </tr>
- 	    <tr>
- 	      <td>showscreen</td>
- 	      <td></td>
- 	      <td></td>
- 	    </tr>
- 	    <tr>
- 	      <td>view</td>
- 	      <td>version</td>
- 	      <td></td>
- 	    </tr>
- 	  </table>
- 	</section>
- 
- 	<section>
- 	  <title>View Logs</title>
- 
- 	  <p><code>lenya.usecase=view-logs</code></p>
- 
- 	  <table>
- 	    <tr>
- 	      <th><code>lenya.step=</code></th>
- 	      <th>additional parameters</th>
- 	      <th>sample value</th>
- 	    </tr>
- 	    <tr>
- 	      <td>overview</td>
- 	      <td></td>
- 	      <td></td>
- 	    </tr>
- 	    <tr>
- 	      <td>log</td>
- 	      <td>logfile</td>
- 	      <td>2003-05-13-18-34-00-314.xml</td>
- 	    </tr>
- 	  </table>
- 	</section>
- 
- 	<fixme author="ce">Add remaining use cases</fixme>
-       </section>
      </section>
    </body> 
--- 105,116 ----
        consolidated and standardized.</fixme>
      </section>
+     
      <section>
        <title>Dynamic URIs</title>
  
!         <p>The dynamic URIs that are used for usecases are explained in the
!         section <link href="usecases.html">Usecases</link>.
!         </p>
        
      </section>
    </body>