Hi Paul,
The question is really what will BeanUtils do because Struts uses
BeanUtils to populate the form.
Looking at the docs, I see this:
java.lang.IllegalAccessException - if the caller does not have access to
the property accessor method
java.lang.IllegalArgumentException - if bean or name is null
java.lang.reflect.InvocationTargetException - if the property accessor
method throws an exception
java.lang.NoSuchMethodException - if an accessor method for this propety
cannot be found
...in the docs for PropertyUtilsBean.setProperty(), which is I believe
what is ultimately used to set a given property. So, my bet is you'd
get IllegalAccessException thrown, or possibly NoSuchMethodException.
Then again, there *is* IIRC some special handling for read-only
properties, and I would think that is determined by whether there is an
accessible getter.
Well, I suppose in the end I'm not really sure what the answer is
without actually testing it, but BeanUtils is where you should be
looking in any case :)
Frank
Paul Benedict wrote:
When struts auto populates the form, does it look for set methods? And does it check
that the methods are public? For instance, if the "foo" parameter comes in and
my setFoo method is protected or private, will it ignore it?
Paul
---------------------------------
Brings words and photos together (easily) with
PhotoMail - it's free and works with Yahoo! Mail.
------------------------------------------------------------------------
No virus found in this incoming message.
Checked by AVG Free Edition.
Version: 7.1.375 / Virus Database: 267.15.0/249 - Release Date: 2/2/2006
--
Frank W. Zammetti
Founder and Chief Software Architect
Omnytex Technologies
http://www.omnytex.com
AIM: fzammetti
Yahoo: fzammetti
MSN: [EMAIL PROTECTED]
---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]