commons-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From ohe...@apache.org
Subject svn commit: r1532073 - /commons/proper/beanutils/branches/java5/src/main/java/org/apache/commons/beanutils/BasicDynaClass.java
Date Mon, 14 Oct 2013 20:28:47 GMT
Author: oheger
Date: Mon Oct 14 20:28:47 2013
New Revision: 1532073

URL: http://svn.apache.org/r1532073
Log:
Added generics.

Modified:
    commons/proper/beanutils/branches/java5/src/main/java/org/apache/commons/beanutils/BasicDynaClass.java

Modified: commons/proper/beanutils/branches/java5/src/main/java/org/apache/commons/beanutils/BasicDynaClass.java
URL: http://svn.apache.org/viewvc/commons/proper/beanutils/branches/java5/src/main/java/org/apache/commons/beanutils/BasicDynaClass.java?rev=1532073&r1=1532072&r2=1532073&view=diff
==============================================================================
--- commons/proper/beanutils/branches/java5/src/main/java/org/apache/commons/beanutils/BasicDynaClass.java
(original)
+++ commons/proper/beanutils/branches/java5/src/main/java/org/apache/commons/beanutils/BasicDynaClass.java
Mon Oct 14 20:28:47 2013
@@ -58,7 +58,7 @@ public class BasicDynaClass implements D
      * @param name Name of this DynaBean class
      * @param dynaBeanClass The implementation class for new instances
      */
-    public BasicDynaClass(String name, Class dynaBeanClass) {
+    public BasicDynaClass(String name, Class<?> dynaBeanClass) {
 
         this(name, dynaBeanClass, null);
 
@@ -72,7 +72,7 @@ public class BasicDynaClass implements D
      * @param dynaBeanClass The implementation class for new intances
      * @param properties Property descriptors for the supported properties
      */
-    public BasicDynaClass(String name, Class dynaBeanClass,
+    public BasicDynaClass(String name, Class<?> dynaBeanClass,
                           DynaProperty[] properties) {
 
         super();
@@ -97,14 +97,14 @@ public class BasicDynaClass implements D
      * The constructor of the <code>dynaBeanClass</code> that we will use
      * for creating new instances.
      */
-    protected transient Constructor constructor = null;
+    protected transient Constructor<?> constructor = null;
 
 
     /**
      * The method signature of the constructor we will use to create
      * new DynaBean instances.
      */
-    protected static Class[] constructorTypes = { DynaClass.class };
+    protected static Class<?>[] constructorTypes = { DynaClass.class };
 
 
     /**
@@ -118,7 +118,7 @@ public class BasicDynaClass implements D
      * The <code>DynaBean</code> implementation class we will use for
      * creating new instances.
      */
-    protected Class dynaBeanClass = BasicDynaBean.class;
+    protected Class<?> dynaBeanClass = BasicDynaBean.class;
 
 
     /**
@@ -138,7 +138,7 @@ public class BasicDynaClass implements D
      * keyed by the property name.  Individual descriptor instances will
      * be the same instances as those in the <code>properties</code> list.
      */
-    protected HashMap propertiesMap = new HashMap();
+    protected HashMap<String, DynaProperty> propertiesMap = new HashMap<String,
DynaProperty>();
 
 
     // ------------------------------------------------------ DynaClass Methods
@@ -175,7 +175,7 @@ public class BasicDynaClass implements D
             throw new IllegalArgumentException
                     ("No property name specified");
         }
-        return ((DynaProperty) propertiesMap.get(name));
+        return propertiesMap.get(name);
 
     }
 
@@ -237,7 +237,7 @@ public class BasicDynaClass implements D
      *
      * @return The class of the {@link DynaBean}
      */
-    public Class getDynaBeanClass() {
+    public Class<?> getDynaBeanClass() {
 
         return (this.dynaBeanClass);
 
@@ -257,7 +257,7 @@ public class BasicDynaClass implements D
      * @exception IllegalArgumentException if the specified Class does not
      *  implement the <code>DynaBean</code> interface
      */
-    protected void setDynaBeanClass(Class dynaBeanClass) {
+    protected void setDynaBeanClass(Class<?> dynaBeanClass) {
 
         // Validate the argument type specified
         if (dynaBeanClass.isInterface()) {



Mime
View raw message