Added bundle info to CNFE message. (FELIX-1022)


git-svn-id: https://svn.apache.org/repos/asf/felix/trunk@991305 13f79535-47bb-0310-9956-ffa450edef68
diff --git a/framework/src/main/java/org/apache/felix/framework/ModuleImpl.java b/framework/src/main/java/org/apache/felix/framework/ModuleImpl.java
index 9cba896..99f6a9f 100644
--- a/framework/src/main/java/org/apache/felix/framework/ModuleImpl.java
+++ b/framework/src/main/java/org/apache/felix/framework/ModuleImpl.java
@@ -732,7 +732,9 @@
                     // cause of the exception, since this would
                     // potentially leak internal module information.
                     throw new ClassNotFoundException(
-                        name + ": cannot resolve package "
+                        name + " not found because "
+                        + getBundle()
+                        + " cannot resolve: "
                         + ex.getRequirement());
                 }
                 else
@@ -748,7 +750,9 @@
 
                     // We need to throw a resource not found exception.
                     throw new ResourceNotFoundException(
-                        name + ": cannot resolve package "
+                        name + " not found because "
+                        + getBundle()
+                        + " cannot resolve: "
                         + ex.getRequirement());
                 }
             }
@@ -769,11 +773,13 @@
         {
             if (isClass)
             {
-                throw new ClassNotFoundException(name);
+                throw new ClassNotFoundException(
+                    name + " not found by " + this.getBundle());
             }
             else
             {
-                throw new ResourceNotFoundException(name);
+                throw new ResourceNotFoundException(
+                    name + " not found by " + this.getBundle());
             }
         }