On Tue, 26 Nov 2002, robert burrell donkin wrote:
> Date: Tue, 26 Nov 2002 19:12:21 +0000 > From: robert burrell donkin <[EMAIL PROTECTED]> > Reply-To: Jakarta Commons Developers List <[EMAIL PROTECTED]> > To: Jakarta Commons Developers List <[EMAIL PROTECTED]> > Subject: Re: [beanutils] PropertyUtils.setProperty on classes which > extend Map > > On Monday, November 25, 2002, at 11:25 PM, Craig R. McClanahan wrote: > > > On Mon, 25 Nov 2002, robert burrell donkin wrote: > > <snip> > > > AFAIK, we've never promised that the BeanUtils or PropertyUtils code > > formally support Maps as the *destination* of a property set operation, > > even though they are acceptable as the source in certain scenarios. In > > addition, if we're going to support setting via PropertyUtils, we > > certainly should support getting for symmetry. > > i certainly agree with the point above but... just to be clear (which i > probably wasn't before) > > the bug (as far as i understand it) concerns setting normal bean > properties on a bean that extends Hashtable. i have a bean with a property > that is set successfully when the class doesn't extend hashtable. when i > change the class definition so that it extends Hashtable, the property is > no longer set by PropertyUtils. > Not remembering the details, is it possible that by extending Hashtable you're creating a situation where you have a property that violates the JavaBean spec's naming patterns (such as having two setters, or a setter and a getter with different property types)? That would certainly cause a problem like this. > so, it seems that this is a bug and isn't related to supporting maps as > pseudo-beans (i'll create a new thread for that discussion). > > - robert > Craig -- To unsubscribe, e-mail: <mailto:[EMAIL PROTECTED]> For additional commands, e-mail: <mailto:[EMAIL PROTECTED]>