commons-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Scott Sanders" <ssand...@nextance.com>
Subject RE: [PATCH] - bug 5639
Date Fri, 04 Jan 2002 21:23:41 GMT
In the current cvs with set support and tests :)

Scott

> -----Original Message-----
> From: Arron Bates [mailto:arron@keyboardmonkey.com] 
> Sent: Thursday, January 03, 2002 3:47 PM
> To: Jakarta Commons Developers List
> Subject: [PATCH] - bug 5639
> 
> 
>   Attached is the diff for the patch on PropertyUtils.java.
> The code is tested and works great.
> 
> Or if that don't work (heaven forbid), replace lines 419 to 423 
> (inclusive) with the code below.
> 
> 
> Object value = readMethod.invoke(bean, new Object[0]);
> if (!value.getClass().isArray()) {
> if (!(value instanceof java.util.List)) {
> throw new IllegalArgumentException("Property '" + name
> + "' is not indexed");
> } else {
> return ((java.util.List)value).get(index);
> }
> }
> return (Array.get(value, index));
> 
> 
> 

--
To unsubscribe, e-mail:   <mailto:commons-dev-unsubscribe@jakarta.apache.org>
For additional commands, e-mail: <mailto:commons-dev-help@jakarta.apache.org>


Mime
View raw message