RE : jelly core:while

classic Classic list List threaded Threaded
3 messages Options
Reply | Threaded
Open this post in threaded view
|

RE : jelly core:while

Marc DeXeT (DSI)

> -----Message d'origine-----
> De : Pavel Reich [mailto:[hidden email]]
> Envoyé : mardi 21 juin 2005 14:59
> À : [hidden email]
> Objet : jelly core:while
>
>
> Some questions regarding
> http://jakarta.apache.org/commons/jelly/ project.
> I use jelly for jameleon tests.
> Does anybody know, how to organize loop with core:while?
> For example, count from 1 to 10 and print it.
> http://jakarta.apache.org/commons/jelly/tags.html documentation is
> very short and haven't any examples.

<j:jelly xmlns:j="jelly:core">
        <j:set var="c" value="0"/>
        <j:while test="${c lt 10}">
                I'am equal to ${c}
                <j:set var="c" value="${c+1}"/>
        </j:while>
</j:jelly>

Direct from my left neuron (right is sleeping).
It would be correct.

--
Marc DeXeT
CNRS/DSI/BEST
<http://www.dsi.cnrs.fr>
Reply | Threaded
Open this post in threaded view
|

Re: RE : jelly core:while

Pavel Reich
Thanks, but i have exception:

[jmln-test-vm] Jun 21, 2005 5:14:40 PM
org.apache.commons.jelly.expression.jexl.JexlExpression evaluate
[jmln-test-vm] WARNING: Caught exception evaluating:
org.apache.commons.jexl.ExpressionImpl@3bb2b8. Reason:
java.lang.Exception: Invalid comparison : LT
[jmln-test-vm] java.lang.Exception: Invalid comparison : LT
[jmln-test-vm] at
org.apache.commons.jexl.parser.ASTLTNode.value(ASTLTNode.java:105)



On 6/21/05, Marc DEXET <[hidden email]> wrote:

>
> > -----Message d'origine-----
> > De : Pavel Reich [mailto:[hidden email]]
> > Envoyé : mardi 21 juin 2005 14:59
> > À : [hidden email]
> > Objet : jelly core:while
> >
> >
> > Some questions regarding
> > http://jakarta.apache.org/commons/jelly/ project.
> > I use jelly for jameleon tests.
> > Does anybody know, how to organize loop with core:while?
> > For example, count from 1 to 10 and print it.
> > http://jakarta.apache.org/commons/jelly/tags.html documentation is
> > very short and haven't any examples.
>
> <j:jelly xmlns:j="jelly:core">
>         <j:set var="c" value="0"/>
>         <j:while test="${c lt 10}">
>                 I'am equal to ${c}
>                 <j:set var="c" value="${c+1}"/>
>         </j:while>
> </j:jelly>
>
> Direct from my left neuron (right is sleeping).
> It would be correct.
>
> --
> Marc DeXeT
> CNRS/DSI/BEST
> <http://www.dsi.cnrs.fr>
>
>

---------------------------------------------------------------------
To unsubscribe, e-mail: [hidden email]
For additional commands, e-mail: [hidden email]

Reply | Threaded
Open this post in threaded view
|

Re: RE : jelly core:while

Pavel Reich
Just update jexl to commons-jexl-1.0-RC1.jar  and it will be work
       <core:set var="c" value="0"/>
       <core:while test="${c lt 10}">
<!-- our custom tag for out.println -->
               <j:ng-echo functionId="now we have" message="c:${c}" />
               <core:set var="c" value="${c+1}"/>
       </core:while>


On 6/21/05, Pavel Reich <[hidden email]> wrote:

> Thanks, but i have exception:
>
> [jmln-test-vm] Jun 21, 2005 5:14:40 PM
> org.apache.commons.jelly.expression.jexl.JexlExpression evaluate
> [jmln-test-vm] WARNING: Caught exception evaluating:
> org.apache.commons.jexl.ExpressionImpl@3bb2b8. Reason:
> java.lang.Exception: Invalid comparison : LT
> [jmln-test-vm] java.lang.Exception: Invalid comparison : LT
> [jmln-test-vm]  at
> org.apache.commons.jexl.parser.ASTLTNode.value(ASTLTNode.java:105)
>
>
>
> On 6/21/05, Marc DEXET <[hidden email]> wrote:
> >
> > > -----Message d'origine-----
> > > De : Pavel Reich [mailto:[hidden email]]
> > > Envoyé : mardi 21 juin 2005 14:59
> > > À : [hidden email]
> > > Objet : jelly core:while
> > >
> > >
> > > Some questions regarding
> > > http://jakarta.apache.org/commons/jelly/ project.
> > > I use jelly for jameleon tests.
> > > Does anybody know, how to organize loop with core:while?
> > > For example, count from 1 to 10 and print it.
> > > http://jakarta.apache.org/commons/jelly/tags.html documentation is
> > > very short and haven't any examples.
> >
> > <j:jelly xmlns:j="jelly:core">
> >         <j:set var="c" value="0"/>
> >         <j:while test="${c lt 10}">
> >                 I'am equal to ${c}
> >                 <j:set var="c" value="${c+1}"/>
> >         </j:while>
> > </j:jelly>
> >
> > Direct from my left neuron (right is sleeping).
> > It would be correct.
> >
> > --
> > Marc DeXeT
> > CNRS/DSI/BEST
> > <http://www.dsi.cnrs.fr>
> >
> >
>

---------------------------------------------------------------------
To unsubscribe, e-mail: [hidden email]
For additional commands, e-mail: [hidden email]