aspose file tools*
The moose likes Struts and the fly likes about indexed properties Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of Java 8 in Action this week in the Java 8 forum!
JavaRanch » Java Forums » Frameworks » Struts
Bookmark "about indexed properties" Watch "about indexed properties" New topic
Author

about indexed properties

Marco Vanoli
Ranch Hand

Joined: Jan 12, 2005
Posts: 99
In a form bean i create an indexed properties as this:


the problem is that in Struts tutorial there is only the get method and not the set one

I am doing the right thing to adding the set methods, otherwise how works indexed properties?

tnks
[ October 06, 2005: Message edited by: Marco Vanoli ]

bye, <br />Marco
Vani Bandargal
Ranch Hand

Joined: Oct 06, 2005
Posts: 82
try this:

public void setPar(int index,LabelValueBean bean)
{
labelValueList.set(index,bean);
}
Marc Peabody
pie sneak
Sheriff

Joined: Feb 05, 2003
Posts: 4727

The BeanUtils (which Struts uses to populate the ActionForms) calls the getter and takes the collection returned to set all the individual values on its own.

It does not use a setter.


A good workman is known by his tools.
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: about indexed properties
 
Similar Threads
Select Tag
Setting the valus of variable present in an Arraylist which is present in another arraylist
Problems with Indexed Properties, Hidden Values and Logic Iterate Tag
Pre-select collection of options (drop-downs)
I want to use indexed properties