commons-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From d...@apache.org
Subject cvs commit: jakarta-commons/jexl/xdocs/reference examples.xml
Date Tue, 24 Aug 2004 02:27:25 GMT
dion        2004/08/23 19:27:25

  Modified:    jexl/xdocs/reference examples.xml
  Log:
  details on method calling
  
  Revision  Changes    Path
  1.12      +17 -2     jakarta-commons/jexl/xdocs/reference/examples.xml
  
  Index: examples.xml
  ===================================================================
  RCS file: /home/cvs/jakarta-commons/jexl/xdocs/reference/examples.xml,v
  retrieving revision 1.11
  retrieving revision 1.12
  diff -u -r1.11 -r1.12
  --- examples.xml	23 Aug 2004 13:00:48 -0000	1.11
  +++ examples.xml	24 Aug 2004 02:27:25 -0000	1.12
  @@ -106,10 +106,25 @@
           </source>
           <p>Arithmetic expressions can use variables. <code>null</code>
is treated as a zero for arithmetic.</p>
         </subsection>
  -      <subsection name="Calling methods"></subsection>
  +      <subsection name="Calling methods">
  +        <p>
  +          JEXL allows you to call any method on a Java object using the same syntax.
  +          If you have a string in the context under the name <code>aString</code>,
  +          you could call it's <code>length</code> 
  +          method like this:
  +          <source>
  +aString.length()
  +aString.substring(6)
  +          </source>
  +        </p>
  +        <p>
  +          Often the values you want to pass to a method are other variables or expressions.
  +          If you have a number in the context named <code>i</code>, you could
use it
  +          in a method call:
  +        </p>
  +      </subsection>
         <subsection name="Accessing properties"></subsection>
         <subsection name="Arrays, Collections and Maps"></subsection>
       </section>
     </body>
   </document>
  -    
  \ No newline at end of file
  
  
  

---------------------------------------------------------------------
To unsubscribe, e-mail: commons-dev-unsubscribe@jakarta.apache.org
For additional commands, e-mail: commons-dev-help@jakarta.apache.org


Mime
View raw message