cocoon-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Robin Green" <gree...@hotmail.com>
Subject Re: Additions to XSP util:* taglib
Date Tue, 02 May 2000 09:06:17 GMT
>Kevin,
>
>I like it for 2 reasons:
>1. Target langauge independent (doesn't mutter Java/JS/C/C++/Perl/TCL
>etc...)

But either you reimplement the tags in each possible language (!!! lots of 
maintenance for the Cocoon project), or you only implement it in 
Java(possible, but mix-and-match languages in that way is not a good idea 
for performance and clarity - because of basic differences in languages as 
already mentioned).

Ask yourself - why do we need to reinvent the wheel here? To simplify 
Java/JS/C etc. programming? No, it doesn't simplify it. To ease transition 
from XSLT? Well, sorry, IMO if people are going to use real programming 
languages they should use real programming languages, not wrappers around 
them.

>For example: I can write:
>
><util:case>
>     <util:when test="a!=b">
>         A!=B
>     </util:when>
>     <util:otherwise>
>         A==B
>     </util:otherwise>
></util:case>
>
>and then XSP will compile it to Java
>then if I'll want to switch to JavaScript or C++ :), then I need only to
>write new logicsheet ...

But you are not actually programming in Java/JS/C++, you are programming in 
"Zvis' tag language".

>2. Much less verbose, than writing many times <xsp:logic> tags with
><[CDATA[ ... ]]> inside :)
>compare between:
>
><util:if test="a &gt; b">
>    <h1>A greater than B!</h1>
></util:if>
>
>and
>
><xsp:logic>
><[CDATA[
>if(a>b){
>]]>
></xsp:logic>
>    <h1>A greater than B!</h1>
><xsp:logic>
>}
></xsp:logic>
>

No, that's not correct. You can use &gt; inside xsp:logic as well.

-1

--
Robin

270+ Open Source Java links! 
http://directory.mozilla.org/Computers/Programming/Languages/Java/Open_Source/

________________________________________________________________________
Get Your Private, Free E-mail from MSN Hotmail at http://www.hotmail.com


Mime
View raw message