Skip to main content

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] [List Home]
Re: [aspectj-dev] WeavingURLClassLoader does not follow jar Class-Paths

Hi -

Sorry, this looks like another area where WeavingClassLoader 
is more demonstration- than production-quality.  If someone 
wants to make this work, we'd welcome a patch via an enhancement 
request.

Thanks for pointing this out.
Wes

> ------------Original Message------------
> From: Mike Haladin <mike.haladin@xxxxxx>
> To: aspectj-dev@xxxxxxxxxxx
> Date: Tue, Jun-7-2005 7:51 AM
> Subject: [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
> 
> -- 
> 
> _______________________________________________
> aspectj-dev mailing list
> aspectj-dev@xxxxxxxxxxx
> https://dev.eclipse.org/mailman/listinfo/aspectj-dev
> 



Back to the top