geronimo-xbean-scm mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From djen...@apache.org
Subject svn commit: r1001160 - /geronimo/xbean/trunk/xbean-naming/src/main/java/org/apache/xbean/naming/context/AbstractContext.java
Date Sat, 25 Sep 2010 08:03:23 GMT
Author: djencks
Date: Sat Sep 25 08:03:22 2010
New Revision: 1001160

URL: http://svn.apache.org/viewvc?rev=1001160&view=rev
Log:
improve a couple error messages

Modified:
    geronimo/xbean/trunk/xbean-naming/src/main/java/org/apache/xbean/naming/context/AbstractContext.java

Modified: geronimo/xbean/trunk/xbean-naming/src/main/java/org/apache/xbean/naming/context/AbstractContext.java
URL: http://svn.apache.org/viewvc/geronimo/xbean/trunk/xbean-naming/src/main/java/org/apache/xbean/naming/context/AbstractContext.java?rev=1001160&r1=1001159&r2=1001160&view=diff
==============================================================================
--- geronimo/xbean/trunk/xbean-naming/src/main/java/org/apache/xbean/naming/context/AbstractContext.java
(original)
+++ geronimo/xbean/trunk/xbean-naming/src/main/java/org/apache/xbean/naming/context/AbstractContext.java
Sat Sep 25 08:03:22 2010
@@ -201,7 +201,7 @@ public abstract class AbstractContext im
         if (value == null) {
             throw new NotContextException("The intermediate context " + name.get(name.size()
- 1) + " does not exist");
         } else if (!(value instanceof Context)) {
-            throw new NotContextException("The intermediate context " + name.get(name.size()
- 1) + " does is not a context");
+            throw new NotContextException("The intermediate context " + name.get(name.size()
- 1) + " is not a context");
         } else {
             return (Context) value;
         }
@@ -226,7 +226,7 @@ public abstract class AbstractContext im
 
     protected void addDeepBinding(Name name, Object value, boolean rebind, boolean createIntermediateContexts)
throws NamingException {
         if (name == null) throw new NullPointerException("name is null");
-        if (value == null) throw new NullPointerException("value is null");
+        if (value == null) throw new NullPointerException("value is null for name: " + name);
 
         if (name.isEmpty()) {
             throw new InvalidNameException("Name is empty");



Mime
View raw message