kpiroumian    2002/12/05 12:31:19

  Modified:    src/java/org/apache/cocoon/components/language/markup/xsp/java
                        Tag: cocoon_2_0_3_branch input.xsl
               src/documentation/xdocs/userdocs/concepts Tag:
                        cocoon_2_0_3_branch modules.xml
  Log:
  Make input logicsheet markup consistent with implementation interfaces.
  
  Revision  Changes    Path
  No                   revision
  
  
  No                   revision
  
  
  1.1.2.2   +13 -13    
xml-cocoon2/src/java/org/apache/cocoon/components/language/markup/xsp/java/input.xsl
  
  Index: input.xsl
  ===================================================================
  RCS file: 
/home/cvs/xml-cocoon2/src/java/org/apache/cocoon/components/language/markup/xsp/java/input.xsl,v
  retrieving revision 1.1.2.1
  retrieving revision 1.1.2.2
  diff -u -r1.1.2.1 -r1.1.2.2
  --- input.xsl 30 Nov 2002 10:20:44 -0000      1.1.2.1
  +++ input.xsl 5 Dec 2002 20:31:19 -0000       1.1.2.2
  @@ -96,10 +96,10 @@
       </xsp:page>
     </xsl:template>
   
  -  <xsl:template match="input:get-parameter">
  +  <xsl:template match="input:get-attribute">
       <!-- InputModule short-hand, defaults to "request-param" -->
       <xsl:variable name="module">
  -      <xsl:call-template name="get-string-parameter">
  +      <xsl:call-template name="get-string-attribute">
           <xsl:with-param name="name">module</xsl:with-param>
           <xsl:with-param name="default">request-param</xsl:with-param>
           <xsl:with-param name="required">false</xsl:with-param>
  @@ -107,21 +107,21 @@
       </xsl:variable>
       <!-- parameter name, no default, required -->
       <xsl:variable name="name">
  -      <xsl:call-template name="get-string-parameter">
  +      <xsl:call-template name="get-string-attribute">
           <xsl:with-param name="name">name</xsl:with-param>
           <xsl:with-param name="required">true</xsl:with-param>
         </xsl:call-template>
       </xsl:variable>
       <!-- default value, defaults to empty string -->
       <xsl:variable name="default">
  -      <xsl:call-template name="get-string-parameter">
  +      <xsl:call-template name="get-string-attribute">
           <xsl:with-param name="name">default</xsl:with-param>
           <xsl:with-param name="required">false</xsl:with-param>
         </xsl:call-template>
       </xsl:variable>
       <!-- return type: object / string / xml, defaults to object -->
       <xsl:variable name="as">
  -      <xsl:call-template name="get-parameter">
  +      <xsl:call-template name="get-attribute">
           <xsl:with-param name="name">as</xsl:with-param>
           <xsl:with-param name="default">object</xsl:with-param>
           <xsl:with-param name="required">false</xsl:with-param>
  @@ -149,10 +149,10 @@
     </xsl:template>
   
   
  -  <xsl:template match="input:get-parameter-values">
  +  <xsl:template match="input:get-attribute-values">
       <!-- InputModule short-hand, defaults to "request-param" -->
       <xsl:variable name="module">
  -      <xsl:call-template name="get-string-parameter">
  +      <xsl:call-template name="get-string-attribute">
           <xsl:with-param name="name">module</xsl:with-param>
           <xsl:with-param name="default">request-param</xsl:with-param>
           <xsl:with-param name="required">false</xsl:with-param>
  @@ -160,14 +160,14 @@
       </xsl:variable>
       <!-- parameter name, no default, required -->
       <xsl:variable name="name">
  -      <xsl:call-template name="get-string-parameter">
  +      <xsl:call-template name="get-string-attribute">
           <xsl:with-param name="name">name</xsl:with-param>
           <xsl:with-param name="required">true</xsl:with-param>
         </xsl:call-template>
       </xsl:variable>
       <!-- return type: object / array / string / xml, defaults to object -->
       <xsl:variable name="as">
  -      <xsl:call-template name="get-parameter">
  +      <xsl:call-template name="get-attribute">
           <xsl:with-param name="name">as</xsl:with-param>
           <xsl:with-param name="default">object</xsl:with-param>
           <xsl:with-param name="required">false</xsl:with-param>
  @@ -193,10 +193,10 @@
   
   
   
  -  <xsl:template match="input:get-parameter-names">
  +  <xsl:template match="input:get-attribute-names">
       <!-- InputModule short-hand, defaults to "request-param" -->
       <xsl:variable name="module">
  -      <xsl:call-template name="get-string-parameter">
  +      <xsl:call-template name="get-string-attribute">
           <xsl:with-param name="name">module</xsl:with-param>
           <xsl:with-param name="default">request-param</xsl:with-param>
           <xsl:with-param name="required">false</xsl:with-param>
  @@ -204,7 +204,7 @@
       </xsl:variable>
       <!-- return type: object / string / xml, defaults to object -->
       <xsl:variable name="as">
  -      <xsl:call-template name="get-parameter">
  +      <xsl:call-template name="get-attribute">
           <xsl:with-param name="name">as</xsl:with-param>
           <xsl:with-param name="default">object</xsl:with-param>
           <xsl:with-param name="required">false</xsl:with-param>
  
  
  
  No                   revision
  
  
  No                   revision
  
  
  1.1.2.6   +14 -5     
xml-cocoon2/src/documentation/xdocs/userdocs/concepts/modules.xml
  
  Index: modules.xml
  ===================================================================
  RCS file: 
/home/cvs/xml-cocoon2/src/documentation/xdocs/userdocs/concepts/modules.xml,v
  retrieving revision 1.1.2.5
  retrieving revision 1.1.2.6
  diff -u -r1.1.2.5 -r1.1.2.6
  --- modules.xml       4 Dec 2002 09:51:09 -0000       1.1.2.5
  +++ modules.xml       5 Dec 2002 20:31:19 -0000       1.1.2.6
  @@ -1,5 +1,5 @@
   <?xml version="1.0" encoding="UTF-8"?>
  -<!DOCTYPE document PUBLIC "-//APACHE//DTD Documentation V1.0//EN" 
"../../dtd/document-v10.dtd">
  +<!DOCTYPE document PUBLIC "-//APACHE//DTD Documentation V1.0//EN" 
"document-v10.dtd">
   
   <document>
   
  @@ -31,14 +31,14 @@
       <s1 title="Types of Modules">
         <p>
           Currently, three different types of modules exist: Input modules
  -        provide means to enumerate parameters and to retrieve them, output
  +        provide means to enumerate attributes and to retrieve them, output
           modules allow storing of data and exhibit transaction like semantics,
           database modules encapsulate different mechanisms for auto increment
           columns of various database management systems. Please refer to the
           javadoc documentation of these interfaces.
         </p>
         <p>
  -        Input modules are modelled after request parameters. The main
  +        Input modules are modelled after request attributes. The main
           difference is, that every method takes two additional arguments, the
           request object and a configuration object. The configuration object is
           used to allow arbitrarily complex instructions for the input module.
  @@ -169,6 +169,15 @@
      <map:transform src="resources/stylesheets/{default:skin}.xsl"/>
   ]]>
             </source>
  +          <p>
  +            Some of the input modules are JXPath-enabled, so you can use
  +            XPath expressions to access values (see Input Modules sample for 
details).
  +            The following example demonstrates the use of XPath function 
  +            with <code>system-property</code> module.
  +          </p>
  +<![CDATA[
  +    <map:parameter name="users-home-base" 
value="{system-property:substring-before(user.home, user.name)}"/>
  +]]>
           </s3>
           <s3 title="Step 2b: Use it on an XSP">
             <p>
  @@ -190,11 +199,11 @@
     <title>Testing InputModules</title>
   
       <p>
  -      Parameter name=<input:get-parameter module="request-param"
  +      Parameter name=<input:get-attribute module="request-param"
                          as="string" name="module" default="John Doe"/>;
       </p>
       <p>
  -      Parameter cars=<input:get-parameter-values module="request-param" 
  +      Parameter cars=<input:get-attribute-values module="request-param" 
                          as="xml" name="car"/>;
       </p>
     </page>
  
  
  

----------------------------------------------------------------------
In case of troubles, e-mail:     [EMAIL PROTECTED]
To unsubscribe, e-mail:          [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to