[
Date Prev][
Date Next][
Thread Prev][
Thread Next][
Date Index][
Thread Index]
[
List Home]
[aspectj-dev] WeavingURLClassLoader does not follow jar Class-Paths
|
Hello,
I am attempting to replace my project's customized URLClassLoader with
the WeavingURLClassLoader. However I find this difficult as it appears
that WeavingURLClassLoader does not follow the class-path in the
manifest of the provided jar files.
Do I need to give it a full list of all jar files needed to the
WeavingURLClassLoader? (In my code below this would be libs)
or is there a way to force WeavingURLClassLoader to also weave and load
the jars in the manifest Class-Path of the jars passed to it in variable
libs?
pointcut classloaderurl(URL[] libs, ClassLoader parent): call
(URLClassLoader.new(..)) && args(libs, parent) && !this(classweaver);
URLClassLoader around (URL[] libs, ClassLoader parent) :
classloaderurl(libs,parent)
{
URL[] aspectURLs;
URL url = null;
List urlList = new ArrayList();
try
{
url = makeURL("myaspect.jar");
if (url != null) urlList.add(url);
}
catch(URISyntaxException e)
{
}
// Add the Aspect URLs
aspectURLs = new URL[urlList.size()];
return(new WeavingURLClassLoader (libs, aspectURLs, parent));
}
thanks,
Mike Haladin
--