What were your thoughts on JSTL EL validator rule?

You commented on BSF and OGNL, but not the JSTL EL validator rule, which I
actually wrote. The others just seem like a good idea.


Regarding:
"This is a General suggestion you have probably given many times yourself
First off then if this is something you would find useful for your work 
then do create the tag and develop the code. That way you would have a
personal investment in  it and continue to improve and maintain it. Then
maybe I would be able to see the entire impact on Struts/commons-validator."

I am using the JSTL EL Validator that I wrote, but not the BSF or OGNL ones
I suggested. I just think they would be a good idea. I'll try the BSF tag
since I don't know much about OGNL. I like the idea of using the same
JavaScript on the client side and the server side, but for now it is just an
idea. I'll try it out.

More comments below....


Rick Hightower
Chief Technology Officer
Trivera Technologies
http://www.triveratech.com
520 290 6855 (Phone)
520 977 8605 (Mobile)
 

-----Original Message-----
From: Robert Leland [mailto:[EMAIL PROTECTED] 
Sent: Monday, August 25, 2003 6:45 PM
To: Struts Developers List
Subject: Re: JSTL EL Validator rule: A better requiredif and validatewhen
using JSTL

Rick Hightower wrote:

>I think there is room for a tag that uses OGNL. OGNL gets used by tapestry
>and WebWork2. Perhaps yet another validator rule could use the BSF
>(BeanScriptingFramework) this would allow the validate expression to be
>written in Rhino (JavaScript for Java), Jython (Python for Java),
BeanShell,
>Perl and more. I think using BSF would be nice. You could have the client
>and server side validation using the same JavaScript code. I am willing to
>contribute the above as well as write a rule that uses BSF and OGNL.
>  
>

Having equalivent client side and servide side validtaion would be very 
nice ! 

** I agree. What did you think of the JSTL validator rule?


One of the
changes in the 1.1.X series of commons-validator is moving the 
Javascript part of validations
from struts to commons-validator. However, now those validations need to 
be unit tested,
and I have just started looking at jsunit for this. Originally the 
Validation code for  Java and Javascript
were almost  line for line identical. Now there are many differences 
between them so maintance
is complicated. 

** I was not aware. I actually thought about doing this type of validation
in the past. I have never done it, but it seems like it would be cool. The
validator framework seems like the right vehicle for this type of shared
JavaScript code between the server and client.

I would be open to using a common set of validation 
routines. I believe the Mozilla
license and the Apache License is fairly compatable so creating a 
dependancy on Rhino shouldn't
impact users of Struts.

** Yep.

I just took a very quick look at OGNL it looks interesting, though I am 
confused, probably becasue I
haven't taken the time to look at all the docs or examples. It says

    *

      A binding language between GUI elements (textfield, combobox,
      etc.) to model objects. Transformations are made easier by OGNL's
      TypeConverter mechanism to convert values from one type to another
      (String to numeric types, for example).


  Does this mean BeanUtils would not be used to introspect 
loading/unloading values to/from
  ActionForm elements. I am not against this, or for it just want to 
assess the impact.

** I am not an OGNL expert. It seems cool, but I don't know all the reasons
why. Like I said, it gets used by WebWork2 and Tapestry.

Also there are alot of new terms here I am not familar with seems to 
require
BeanScriptingFramework requires JRuby which I am also not familar with...

** I don't think BSF requires JRuby unless you plan on using Ruby. I've used
BSF in the past to add JavaScript and Python support to a program I wrote.
It is easy to use, and would not be much different to validateel (JSTL EL).


This is a General suggestion you have probably given many times yourself
First off then if this is something you would find useful for your work 
then do create the tag
and develop the code. 

** I found the JSTL EL validateel useful so I wrote it. I think the BSF
would have been useful a few times and I am willing to try it out.

That way you would have a personal investment in 
it and continue to improve
and maintain it. Then maybe I would be able to see the entire impact on 
Struts/commons-validator.

** I have a personal investment in all the code I write.

Sorry for such a shorty answer, I am interested.

** Cool.

-Rob

> 
>
>Thoughts?
>
> 
>
>--Rick Hightower 
>
> 
>
>
>  
>



---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to