geronimo-xbean-scm mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From xuhaih...@apache.org
Subject svn commit: r1160131 - in /geronimo/xbean/trunk: xbean-bundleutils/src/main/java/org/apache/xbean/osgi/bundle/util/ xbean-finder/src/main/java/org/apache/xbean/finder/
Date Mon, 22 Aug 2011 07:07:20 GMT
Author: xuhaihong
Date: Mon Aug 22 07:07:20 2011
New Revision: 1160131

URL: http://svn.apache.org/viewvc?rev=1160131&view=rev
Log:
XBEAN-181 Unwrap the bundle while using searching classes

Modified:
    geronimo/xbean/trunk/xbean-bundleutils/src/main/java/org/apache/xbean/osgi/bundle/util/BundleClassFinder.java
    geronimo/xbean/trunk/xbean-bundleutils/src/main/java/org/apache/xbean/osgi/bundle/util/BundleResourceFinder.java
    geronimo/xbean/trunk/xbean-finder/src/main/java/org/apache/xbean/finder/BundleAnnotationFinder.java

Modified: geronimo/xbean/trunk/xbean-bundleutils/src/main/java/org/apache/xbean/osgi/bundle/util/BundleClassFinder.java
URL: http://svn.apache.org/viewvc/geronimo/xbean/trunk/xbean-bundleutils/src/main/java/org/apache/xbean/osgi/bundle/util/BundleClassFinder.java?rev=1160131&r1=1160130&r2=1160131&view=diff
==============================================================================
--- geronimo/xbean/trunk/xbean-bundleutils/src/main/java/org/apache/xbean/osgi/bundle/util/BundleClassFinder.java
(original)
+++ geronimo/xbean/trunk/xbean-bundleutils/src/main/java/org/apache/xbean/osgi/bundle/util/BundleClassFinder.java
Mon Aug 22 07:07:20 2011
@@ -77,7 +77,7 @@ public class BundleClassFinder {
 
     public BundleClassFinder(PackageAdmin packageAdmin, Bundle bundle, ClassDiscoveryFilter
discoveryFilter) {
         this.packageAdmin = packageAdmin;
-        this.bundle = bundle;
+        this.bundle = BundleUtils.unwrapBundle(bundle);
         this.discoveryFilter = discoveryFilter;
     }
 

Modified: geronimo/xbean/trunk/xbean-bundleutils/src/main/java/org/apache/xbean/osgi/bundle/util/BundleResourceFinder.java
URL: http://svn.apache.org/viewvc/geronimo/xbean/trunk/xbean-bundleutils/src/main/java/org/apache/xbean/osgi/bundle/util/BundleResourceFinder.java?rev=1160131&r1=1160130&r2=1160131&view=diff
==============================================================================
--- geronimo/xbean/trunk/xbean-bundleutils/src/main/java/org/apache/xbean/osgi/bundle/util/BundleResourceFinder.java
(original)
+++ geronimo/xbean/trunk/xbean-bundleutils/src/main/java/org/apache/xbean/osgi/bundle/util/BundleResourceFinder.java
Mon Aug 22 07:07:20 2011
@@ -69,7 +69,7 @@ public class BundleResourceFinder {
      */
     public BundleResourceFinder(PackageAdmin packageAdmin, Bundle bundle, String prefix,
String suffix, ResourceDiscoveryFilter discoveryFilter) {
         this.packageAdmin = packageAdmin;
-        this.bundle = bundle;
+        this.bundle = BundleUtils.unwrapBundle(bundle);
         this.prefix = addSlash(prefix.trim());
         this.suffix = suffix.trim();
         int pos = this.suffix.lastIndexOf("/");

Modified: geronimo/xbean/trunk/xbean-finder/src/main/java/org/apache/xbean/finder/BundleAnnotationFinder.java
URL: http://svn.apache.org/viewvc/geronimo/xbean/trunk/xbean-finder/src/main/java/org/apache/xbean/finder/BundleAnnotationFinder.java?rev=1160131&r1=1160130&r2=1160131&view=diff
==============================================================================
--- geronimo/xbean/trunk/xbean-finder/src/main/java/org/apache/xbean/finder/BundleAnnotationFinder.java
(original)
+++ geronimo/xbean/trunk/xbean-finder/src/main/java/org/apache/xbean/finder/BundleAnnotationFinder.java
Mon Aug 22 07:07:20 2011
@@ -30,6 +30,7 @@ import java.util.Set;
 import java.util.zip.ZipEntry;
 
 import org.apache.xbean.osgi.bundle.util.BundleResourceFinder;
+import org.apache.xbean.osgi.bundle.util.BundleUtils;
 import org.apache.xbean.osgi.bundle.util.ResourceDiscoveryFilter;
 import org.osgi.framework.Bundle;
 import org.osgi.service.packageadmin.PackageAdmin;
@@ -50,8 +51,8 @@ public class BundleAnnotationFinder exte
     }
 
     public BundleAnnotationFinder(PackageAdmin packageAdmin, Bundle bundle, ResourceDiscoveryFilter
discoveryFilter, Set<String> paths) throws Exception {
-        this.bundle = bundle;
-        BundleResourceFinder bundleResourceFinder = new BundleResourceFinder(packageAdmin,
bundle, "", ".class", discoveryFilter);
+        this.bundle = BundleUtils.unwrapBundle(bundle);
+        BundleResourceFinder bundleResourceFinder = new BundleResourceFinder(packageAdmin,
this.bundle, "", ".class", discoveryFilter);
         bundleResourceFinder.find(new AnnotationFindingCallback());
         this.paths = paths;
     }



Mime
View raw message