On Fri, 15 Nov 2002, Zaretzke, Peter wrote:

>       public void setList( String value ) {
>               list.add ( value );
>       }
> 
> does not work because it does not meet the parameter expectations (
> List vs. String ) for beans. I know that I can write more setZZZ()
> methods to add something to the List but it breaks somehow the naming
> conventions for beans (getXxx, setXxx). And how to add a new entry to
> the map?

Unless you're happy with writing a new setXxx() method that modifies a
collection (which is a clever idea but still something of a hack because
it violates the intent of the JavaBeans specification), it's actually
quite hard to manage collections in this way with JSTL.  Since JSTL is
focused on presentation -- on reading data structures rather than writing
them -- it's likely going to be easier to modify collections in a back-end
servlet (or with a new custom tag you write -- one that's specific to your
own custom data).

Shawn


--
To unsubscribe, e-mail:   <mailto:taglibs-user-unsubscribe@;jakarta.apache.org>
For additional commands, e-mail: <mailto:taglibs-user-help@;jakarta.apache.org>

Reply via email to