David, Thanks for your input. I guess I didn't give you enough specifics about the app that I'm developing for my question 1. It is a wizard-like app that allow user to go "Back" and "Next". While I started out using several beans broken up logically to maintain the data, say bean1 and bean2, I found out that some screens has fields from both beans. As far as I know, struts only allow 1 form bean to be associated with a form action, I changed my design to use 1 single bean for all screen. This way, it's a lot easier to handle the "Back" situation where the previously entered data needs to be populated in the right fields. What I'm really asking is that, other than it might not be the easiest thing to maintain a bean with 100+, for those of you who've used such bean, is there any technical issue like performance, or session capacity, etc.?
-----Original Message----- From: David Graham [mailto:[EMAIL PROTECTED] Sent: Thursday, July 03, 2003 9:38 AM To: Struts Users Mailing List Subject: Re: Big Javabean? --- "Poon, Johnny" <[EMAIL PROTECTED]> wrote: > Hi > > There are 2 quick questions. > > 1) I'm considering making one huge javabean that will have 100+ fields. > This bean will be share in the session across up to 23 different screen. > I > think this is probably the cleanest way, as the same field might show up > in > different screens. I don't think this will be a problem, however, I > have > never heard or made one single bean with that many fields. Have you > seen or > done that? Have you heard of any problem that might or have cause? It will be confusing for people to maintain a class that large. You should break your beans into logically separate classes. > > 2) Also, since I'm on this note, I noticed if I have a variable name > "mI" > (stands for middle initial), therefore having getMI() and setMI(..), > struts > does not recognize those getter and setter because it is actually > expecting > getiM() and setiM(). I got around it by renaming my variable > "middleInitial", so that the getter and setter are getMiddleInitial() > and > setMiddleInitial(). This works fine. I'm just wondering if anyone out > there aware of this or am I missing anything in the JavaBean standard? Struts relies on commons-beanutils to find the bean properties. Having a variable named mI is an absolutely terrible idea anyways and middleInitial is much more descriptive. David > > Thanks. > > > --------------------------------------------------------------------- > To unsubscribe, e-mail: [EMAIL PROTECTED] > For additional commands, e-mail: [EMAIL PROTECTED] > __________________________________ Do you Yahoo!? SBC Yahoo! DSL - Now only $29.95 per month! http://sbc.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]