commons-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From jcar...@apache.org
Subject svn commit: r1507552 - /commons/proper/proxy/branches/version-2.0-work/core/src/main/java/org/apache/commons/proxy2/ProxyUtils.java
Date Sat, 27 Jul 2013 01:58:43 GMT
Author: jcarman
Date: Sat Jul 27 01:58:43 2013
New Revision: 1507552

URL: http://svn.apache.org/r1507552
Log:
Renaming static final fields to use all-caps.

Modified:
    commons/proper/proxy/branches/version-2.0-work/core/src/main/java/org/apache/commons/proxy2/ProxyUtils.java

Modified: commons/proper/proxy/branches/version-2.0-work/core/src/main/java/org/apache/commons/proxy2/ProxyUtils.java
URL: http://svn.apache.org/viewvc/commons/proper/proxy/branches/version-2.0-work/core/src/main/java/org/apache/commons/proxy2/ProxyUtils.java?rev=1507552&r1=1507551&r2=1507552&view=diff
==============================================================================
--- commons/proper/proxy/branches/version-2.0-work/core/src/main/java/org/apache/commons/proxy2/ProxyUtils.java
(original)
+++ commons/proper/proxy/branches/version-2.0-work/core/src/main/java/org/apache/commons/proxy2/ProxyUtils.java
Sat Jul 27 01:58:43 2013
@@ -39,8 +39,8 @@ public final class ProxyUtils
 
     public static final Object[] EMPTY_ARGUMENTS = new Object[0];
     public static final Class<?>[] EMPTY_ARGUMENT_TYPES = new Class[0];
-    private static final Map<Class<?>, Class<?>> wrapperClassMap = new
HashMap<Class<?>, Class<?>>();
-    private static Map<Class<?>, Object> nullValueMap = new HashMap<Class<?>,
Object>();
+    private static final Map<Class<?>, Class<?>> WRAPPER_CLASS_MAP = new
HashMap<Class<?>, Class<?>>();
+    private static final Map<Class<?>, Object> NULL_VALUE_MAP = new HashMap<Class<?>,
Object>();
 
 //**********************************************************************************************************************
 // Static Methods
@@ -48,26 +48,26 @@ public final class ProxyUtils
 
     static
     {
-        wrapperClassMap.put(Integer.TYPE, Integer.class);
-        wrapperClassMap.put(Character.TYPE, Character.class);
-        wrapperClassMap.put(Boolean.TYPE, Boolean.class);
-        wrapperClassMap.put(Short.TYPE, Short.class);
-        wrapperClassMap.put(Long.TYPE, Long.class);
-        wrapperClassMap.put(Float.TYPE, Float.class);
-        wrapperClassMap.put(Double.TYPE, Double.class);
-        wrapperClassMap.put(Byte.TYPE, Byte.class);
+        WRAPPER_CLASS_MAP.put(Integer.TYPE, Integer.class);
+        WRAPPER_CLASS_MAP.put(Character.TYPE, Character.class);
+        WRAPPER_CLASS_MAP.put(Boolean.TYPE, Boolean.class);
+        WRAPPER_CLASS_MAP.put(Short.TYPE, Short.class);
+        WRAPPER_CLASS_MAP.put(Long.TYPE, Long.class);
+        WRAPPER_CLASS_MAP.put(Float.TYPE, Float.class);
+        WRAPPER_CLASS_MAP.put(Double.TYPE, Double.class);
+        WRAPPER_CLASS_MAP.put(Byte.TYPE, Byte.class);
     }
 
     static
     {
-        nullValueMap.put(Integer.TYPE, 0);
-        nullValueMap.put(Long.TYPE, (long) 0);
-        nullValueMap.put(Short.TYPE, (short) 0);
-        nullValueMap.put(Byte.TYPE, (byte) 0);
-        nullValueMap.put(Float.TYPE, 0.0f);
-        nullValueMap.put(Double.TYPE, 0.0);
-        nullValueMap.put(Character.TYPE, (char) 0);
-        nullValueMap.put(Boolean.TYPE, Boolean.FALSE);
+        NULL_VALUE_MAP.put(Integer.TYPE, 0);
+        NULL_VALUE_MAP.put(Long.TYPE, (long) 0);
+        NULL_VALUE_MAP.put(Short.TYPE, (short) 0);
+        NULL_VALUE_MAP.put(Byte.TYPE, (byte) 0);
+        NULL_VALUE_MAP.put(Float.TYPE, 0.0f);
+        NULL_VALUE_MAP.put(Double.TYPE, 0.0);
+        NULL_VALUE_MAP.put(Character.TYPE, (char) 0);
+        NULL_VALUE_MAP.put(Boolean.TYPE, Boolean.FALSE);
     }
 
     /**
@@ -164,7 +164,7 @@ public final class ProxyUtils
      */
     public static Class<?> getWrapperClass(Class<?> primitiveType)
     {
-        return wrapperClassMap.get(primitiveType);
+        return WRAPPER_CLASS_MAP.get(primitiveType);
     }
 
     /**
@@ -176,7 +176,7 @@ public final class ProxyUtils
     @SuppressWarnings("unchecked")
     public static <T> T nullValue(Class<T> type)
     {
-        return (T) nullValueMap.get(type);
+        return (T) NULL_VALUE_MAP.get(type);
     }
 
     /**



Mime
View raw message