commons-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From bay...@apache.org
Subject svn commit: r763561 - /commons/proper/lang/trunk/src/java/org/apache/commons/lang/ClassUtils.java
Date Thu, 09 Apr 2009 08:38:53 GMT
Author: bayard
Date: Thu Apr  9 08:38:53 2009
New Revision: 763561

URL: http://svn.apache.org/viewvc?rev=763561&view=rev
Log:
Improving getPackageName(Class) to be class.getPackage().getName(). This method then becomes
one of the null-protection only methods... which are imo struggling for justification

Modified:
    commons/proper/lang/trunk/src/java/org/apache/commons/lang/ClassUtils.java

Modified: commons/proper/lang/trunk/src/java/org/apache/commons/lang/ClassUtils.java
URL: http://svn.apache.org/viewvc/commons/proper/lang/trunk/src/java/org/apache/commons/lang/ClassUtils.java?rev=763561&r1=763560&r2=763561&view=diff
==============================================================================
--- commons/proper/lang/trunk/src/java/org/apache/commons/lang/ClassUtils.java (original)
+++ commons/proper/lang/trunk/src/java/org/apache/commons/lang/ClassUtils.java Thu Apr  9
08:38:53 2009
@@ -224,7 +224,7 @@
         if (cls == null) {
             return StringUtils.EMPTY;
         }
-        return getPackageName(cls.getName());
+        return cls.getPackage().getName();
     }
 
     /**



Mime
View raw message