Here's the spec:

http://sunsdlc1-1.sjc-colo.bbnplanet.com/servlet/EComFileServlet/main_products/SDLC//ESD4/JSCDL/javabeans/1.01/beans.101.pdf?ActionId=verify&TicketId=Cl5Z%2BEmLVFM%3D&TicketServerUrl=UMdnxpfbimnVhsPzHcxQH1vcfpnakcdixIDR8grWSV9U3HLSgqDMYN%2BV1osLy1dXQQ%3D%3D&GroupName=5PoE

Ahhh.  Beans.  :|

m

--- David Graham <[EMAIL PROTECTED]> wrote:
> Section 8.8 of the JavaBeans spec details the
> capitalization rules.  My
> guess is that it can't find your property because it
> starts with 2 upper
> case letters and assumes the rest is upper case
> (which getLName isn't). 
> Use "lastName" and everything will work fine :-).
> 
> David
> 
> --- Wes Rood <[EMAIL PROTECTED]> wrote:
> > Could you point me to more information on this
> behavior?
> > 
> > I'm still confused as to why it will capitailze
> the "f" in "fax" to 
> > locate the getFax() method, but it will not
> capitalize the "l" in 
> > "lName" to locate the getLName() method.
> > 
> > Thanks!
> > 
> > David Graham wrote:
> > 
> > >This is standard JavaBean behavior.  Regardless,
> I encourage you to use
> > >lastName instead because lName is rather ugly and
> confusing.
> > >
> > >David
> > >
> > >--- Wes Rood <[EMAIL PROTECTED]> wrote:
> > >  
> > >
> > >>I have an object as follows
> > >>
> > >>public class Contact {
> > >>...
> > >>    private String lName;  // the contact's last
> name
> > >>    private String fax; // the contact's fax
> number
> > >>...
> > >>    public String getLName() {
> > >>        return lName;
> > >>    }
> > >>
> > >>    public String getFax() {
> > >>        return fax;
> > >>    }
> > >>...
> > >>}
> > >>
> > >>Then I use <nested:iterate> to go through a list
> of Contact objects
> > and 
> > >>attempt to access the lName and the fax
> attributes.  I observe the 
> > >>following behavior:
> > >>
> > >><nested:write property="fax" />   correctly
> displays the value of the 
> > >>"fax" attribute
> > >>while:
> > >><nested:write property="Fax" />   causes 
> > >>org.apache.jasper.JasperException: No getter
> method for property 
> > >>contacts[0].Fax of bean ...
> > >>
> > >>Apparently it is uppercasing the "f" in "fax" to
> call getFax(), but
> > when
> > >>
> > >>the "F" is already in caps, it doesn't see the
> attribute.  This is
> > fine,
> > >>
> > >>but then I tried accessing the "lName" property:
> > >>
> > >><nested:write property="lName"/>  causes 
> > >>org.apache.jasper.JasperException: No getter
> method for property 
> > >>contacts[0].lName of bean ...
> > >>while:
> > >><nested:write property="LName" /> correctly
> displays the value of the 
> > >>"lName" attribute
> > >>
> > >>I also rewrote the jsp logic using
> <logic:iterate> and <bean:write>
> > and 
> > >>the same thing happened.
> > >>
> > >>What is going on here?  It appears that the "N"
> in the lName property
> > is
> > >>
> > >>affecting how the "L" is handled.  Any ideas?
> > >>
> > >>
> > >>
> >
>
>>---------------------------------------------------------------------
> > >>To unsubscribe, e-mail:
> [EMAIL PROTECTED]
> > >>For additional commands, e-mail:
> [EMAIL PROTECTED]
> > >>
> > >>    
> > >>
> > >
> > >
> > >__________________________________
> > >Do you Yahoo!?
> > >Yahoo! SiteBuilder - Free, easy-to-use web site
> design software
> > >http://sitebuilder.yahoo.com
> > >
> >
>
>---------------------------------------------------------------------
> > >To unsubscribe, e-mail:
> [EMAIL PROTECTED]
> > >For additional commands, e-mail:
> [EMAIL PROTECTED]
> > >
> > >  
> > >
> > 
> > 
> >
>
---------------------------------------------------------------------
> > To unsubscribe, e-mail:
> [EMAIL PROTECTED]
> > For additional commands, e-mail:
> [EMAIL PROTECTED]
> > 
> 
> 
> __________________________________
> Do you Yahoo!?
> Yahoo! SiteBuilder - Free, easy-to-use web site
> design software
> http://sitebuilder.yahoo.com
> 
>
---------------------------------------------------------------------
> To unsubscribe, e-mail:
> [EMAIL PROTECTED]
> For additional commands, e-mail:
> [EMAIL PROTECTED]
> 


__________________________________
Do you Yahoo!?
Yahoo! SiteBuilder - Free, easy-to-use web site design software
http://sitebuilder.yahoo.com

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

Reply via email to