You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@commons.apache.org by si...@apache.org on 2012/01/21 17:32:00 UTC
svn commit: r1234359 -
/commons/sandbox/beanutils2/trunk/src/main/java/org/apache/commons/beanutils2/AccessibleObjectsRegistry.java
Author: simonetripodi
Date: Sat Jan 21 16:32:00 2012
New Revision: 1234359
URL: http://svn.apache.org/viewvc?rev=1234359&view=rev
Log:
put method now returns the storing AccessibleObject
Modified:
commons/sandbox/beanutils2/trunk/src/main/java/org/apache/commons/beanutils2/AccessibleObjectsRegistry.java
Modified: commons/sandbox/beanutils2/trunk/src/main/java/org/apache/commons/beanutils2/AccessibleObjectsRegistry.java
URL: http://svn.apache.org/viewvc/commons/sandbox/beanutils2/trunk/src/main/java/org/apache/commons/beanutils2/AccessibleObjectsRegistry.java?rev=1234359&r1=1234358&r2=1234359&view=diff
==============================================================================
--- commons/sandbox/beanutils2/trunk/src/main/java/org/apache/commons/beanutils2/AccessibleObjectsRegistry.java (original)
+++ commons/sandbox/beanutils2/trunk/src/main/java/org/apache/commons/beanutils2/AccessibleObjectsRegistry.java Sat Jan 21 16:32:00 2012
@@ -54,10 +54,11 @@ final class AccessibleObjectsRegistry<AO
// this class cannot be instantiated
}
- public void put( AO accessibleObject, boolean exact, Class<?> cls, String methodName, Class<?>... paramTypes )
+ public AO put( AO accessibleObject, boolean exact, Class<?> cls, String methodName, Class<?>... paramTypes )
{
cache.put( new AccessibleObjectDescriptor( exact, cls, methodName, paramTypes ),
new WeakReference<AO>( accessibleObject ) );
+ return accessibleObject;
}
public AO get( boolean exact, Class<?> cls, String methodName, Class<?>... paramTypes )
@@ -71,7 +72,7 @@ final class AccessibleObjectsRegistry<AO
}
/**
- * Represents the key to looking up a Method by reflection.
+ * Represents the key to looking up an AccessibleObject by reflection.
*/
private static final class AccessibleObjectDescriptor
{