From: "Rick Reumann" <[EMAIL PROTECTED]>
>
> My question is how does Struts/BeanUtils handle two get methods that
> have different signatures but the same method name, and what exactly is
> going on?
>

See section 7.2 of the JavaBeans Specification for info on indexed
properties.  The indexed get/set methods are optional.  "A component MAY
also expose an indexed property as a single array value." (emphasis mine).
(They also must be arrays-- BeanUtils extends the spec to allow Lists.)

In light of that, I would bet the BeanUtils code always uses the
getWhatever() method, and then gets/sets the requested index directly on the
List or array.  Seems logical to me, but I have not run it in a debugger or
looked at the code to be certain.

-- 
Wendy Smoak


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

Reply via email to