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


Win a copy of Spring in Action this week in the Spring forum!
JavaRanch » Java Forums » Frameworks » Struts
Bookmark "Indexed Properties" Watch "Indexed Properties" New topic
Author

Indexed Properties

Thara Visu
Ranch Hand

Joined: May 17, 2005
Posts: 87


I am using struts 1.2.9 and i get the error no getter method for property submissions. (JDK 1.3)

if i remove the methods which take index as parameters, it works fine.

Where exactly is the problem?
Thanks in advance


Thara<br />SCJP 1.4 96%<br />SCBCD 1.3 96%
Merrill Higginson
Ranch Hand

Joined: Feb 15, 2005
Posts: 4864
In the past, I've had problems with Struts not dealing with overloaded methods properly in ActionForm beans. I'm not sure if the bug has been fixed or not, but I always make it a practice to name the indexed getter and setter something different than the non-indexed ones.

In your example, I'd have a getSubmissions and setSubmissions method to deal with the entire collection, and a getSubmission and setSubmission method to deal with a single indexed entity.


Merrill
Consultant, Sima Solutions
Thara Visu
Ranch Hand

Joined: May 17, 2005
Posts: 87
Thanks Merrill.
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: Indexed Properties