Is it better than Commons beanutils? The type conversion there is VERY
simple, and it's nice to have a registry to register converters with
instead of having to subclass the TypeConverter to add more
converters... This is actually the area I worry about most in Ognl.

> -----Original Message-----
> From: Pat Lightbody [mailto:[EMAIL PROTECTED] 
> Sent: Friday, May 30, 2003 1:11 PM
> To: [EMAIL PROTECTED]
> Subject: Re: [OS-webwork] Newbie: Please help with array/list 
> of objects ...
> 
> 
> Well, Ognl is MUCH more powerful, and it's type conversion 
> stuff is leaps and bounds better than anything else out there.
> 
> -Pat
> 
> ----- Original Message -----
> From: "Heng Sin Low" <[EMAIL PROTECTED]>
> To: <[EMAIL PROTECTED]>
> Sent: Thursday, May 29, 2003 10:56 PM
> Subject: Re: [OS-webwork] Newbie: Please help with array/list 
> of objects ...
> 
> 
> > Is there any reason why Ognl is prefer over jstl el ? 
> Thought it might 
> > be better to go with the standard approach.
> >
> > --- Pat Lightbody <[EMAIL PROTECTED]> wrote:
> > > I don't think is yet supported by Ognl. The Ognl mailing list has 
> > > been
> VERY
> > > quiet lately... it's starting to worry me a bit...
> > >
> > > Drew? You still around? Need any help? :)
> > >
> > > -Pat
> > >
> > > ----- Original Message -----
> > > From: "Jason Carreira" <[EMAIL PROTECTED]>
> > > To: <[EMAIL PROTECTED]>
> > > Sent: Thursday, May 29, 2003 9:32 AM
> > > Subject: RE: [OS-webwork] Newbie: Please help with array/list of 
> > > objects
> ...
> > >
> > >
> > > > Try having indexed getters and setters, like so:
> > > >
> > > > public Kardon getKardon(int index)
> > > > public void setKardon(int index, Kardon kardon)
> > > >
> > > > This might allow you to to use the index notation (not 
> making any 
> > > > promises :-))
> > > >
> > > > Jason
> > > >
> > > > > -----Original Message-----
> > > > > From: Buorn, Yoway [mailto:[EMAIL PROTECTED]
> > > > > Sent: Thursday, May 29, 2003 12:05 PM
> > > > > To: '[EMAIL PROTECTED]'
> > > > > Subject: [OS-webwork] Newbie: Please help with array/list of 
> > > > > objects ...
> > > > >
> > > > >
> > > > > Hi.  I'm having a little trouble posting an array of 
> objects to 
> > > > > an Action.  I have container class that contains a 
> few Vectors 
> > > > > of other container classes, like so:
> > > > >
> > > > > public class Harman
> > > > > {
> > > > > private Vector kardons;
> > > > > // Omit getters and setters for brevity.
> > > > >
> > > > > public Harman( )
> > > > > {
> > > > > kardons = new Vector();
> > > > > }
> > > > > }
> > > > >
> > > > > public class Kardon
> > > > > {
> > > > > private String value;
> > > > > // Omit getters and setters for brevity.
> > > > > }
> > > > >
> > > > > Then I created an Action class that contains a Harman 
> object and 
> > > > > I use BeanUtil.setProperties() to populate the fields of the 
> > > > > object, like so:
> > > > >
> > > > > public class HarmanAction extends ActionSupport
> > > > > {
> > > > > private Harman harman;
> > > > > // Omit getters and setters for brevity.
> > > > >
> > > > > public HarmanAction( )
> > > > > {
> > > > > harman = new Harman();
> > > > > }
> > > > >
> > > > > public String doExecute( ) throws Exception
> > > > > {
> > > > > parameters =
> > > > > ActionContext.getSingleValueParameters();
> > > > > BeanUtil.setProperties(parameters,harman);
> > > > > return SUCCESS;
> > > > > }
> > > > > }
> > > > >
> > > > > Now the problem is that I can't figure out how to 
> populate the 
> > > > > field value inside one of the Kardon objects in the kardons 
> > > > > Vector.  The first thing I tried was having the name in my 
> > > > > <ui:textfield/> set to index into the Vector, like so:
> > > > >
> > > > > ... some HTML with a form ...
> > > > > <ui:textfield name="'kardons[0]/value'" 
> label="'unimportant'"/> 
> > > > > ... some HTML with the form submit button, etc. ...
> > > > >
> > > > > Now this spews the following when I try to submit the form:
> > > > >
> > > > > Could not set parameter
> > > > > "kardons[0]/value":java.lang.IllegalArgumentException: The 
> > > > > target object for property 'kardons[0]/value'. The 
> target object 
> > > > > needs to be initialized to a non-null value in order 
> to set this 
> > > > > property.
> > > > >
> > > > > I tried omitting the index because that seemed to work when I 
> > > > > had an array of Strings.  However, in this case, the 
> value was 
> > > > > just ignored and didn't populate the field.  I also tried 
> > > > > changing the Vector to an array and also a List.  
> Each time, I 
> > > > > still got the same error.  So my question is, how can 
> a post an 
> > > > > array of objects?
> > > > >
> > > > > Yoway Buorn
> > > > > Software Engineer
> > > > > Imagery Systems Engineering
> > > > >
> > > > > GENERAL DYNAMICS
> > > > > Advanced Information Systems
> > > > >
> > > > > 112 Lakeview Canyon Road
> > > > > Thousand Oaks, CA 91362-5027
> > > > > Tel 805 497 5074
> > > > > Fax 805 497 5050
> > > > > [EMAIL PROTECTED]
> > > > >
> > > > > -=[ c o l l e c t i v e - b a s s - j u n e 2 0 ]=-
> > > > >
> > > > >
> > > > >
> > > > > -------------------------------------------------------
> > > > > This SF.net email is sponsored by: eBay
> > > > > Get office equipment for less on eBay! 
> > > > > http://adfarm.mediaplex.com/ad/ck/711-11697-> 6916-5
> > > > >
> > > > > _______________________________________________
> > > > >
> > > > > Opensymphony-webwork mailing list 
> > > > > [EMAIL PROTECTED]
> > > > > 
> https://lists.sourceforge.net/lists/listinfo/opensymphony-webwor
> > > > > k
> > > > >
> > > >
> > > >
> > > > -------------------------------------------------------
> > > > This SF.net email is sponsored by: eBay
> > > > Get office equipment for less on eBay! 
> > > > http://adfarm.mediaplex.com/ad/ck/711-11697-6916-5
> > > > _______________________________________________
> > > > Opensymphony-webwork mailing list 
> > > > [EMAIL PROTECTED]
> > > > 
> https://lists.sourceforge.net/lists/listinfo/o> pensymphony-webwork
> > >
> > >
> > >
> > > -------------------------------------------------------
> > > This SF.net email is sponsored by: eBay
> > > Get office equipment for less on eBay! 
> > > http://adfarm.mediaplex.com/ad/ck/711-11697-6916-5
> > > _______________________________________________
> > > Opensymphony-webwork mailing list 
> > > [EMAIL PROTECTED]
> > > https://lists.sourceforge.net/lists/listinfo/opensymphony-webwork
> >
> >
> > __________________________________
> > Do you Yahoo!?
> > Yahoo! Calendar - Free online calendar with sync to Outlook(TM). 
> > http://calendar.yahoo.com
> >
> >
> > -------------------------------------------------------
> > This SF.net email is sponsored by: eBay
> > Get office equipment for less on eBay! 
> > http://adfarm.mediaplex.com/ad/ck/711-11697-6916-5
> > _______________________________________________
> > Opensymphony-webwork mailing list 
> > [EMAIL PROTECTED]
> > https://lists.sourceforge.net/lists/listinfo/opensymphony-webwork
> 
> 
> 
> -------------------------------------------------------
> This SF.net email is sponsored by: eBay
> Get office equipment for less on eBay! 
> http://adfarm.mediaplex.com/ad/ck/711-11697-> 6916-5
> 
> _______________________________________________
> 
> Opensymphony-webwork mailing list 
> [EMAIL PROTECTED]
> https://lists.sourceforge.net/lists/listinfo/opensymphony-webwork
> 


-------------------------------------------------------
This SF.net email is sponsored by: eBay
Get office equipment for less on eBay!
http://adfarm.mediaplex.com/ad/ck/711-11697-6916-5
_______________________________________________
Opensymphony-webwork mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/opensymphony-webwork

Reply via email to