[
Date Prev][
Date Next][
Thread Prev][
Thread Next][
Date Index][
Thread Index]
[
List Home]
| 
Re: [platform-ant-dev] Heads up: Eclipse Ant Support will be changing
 | 
The library you specify in that extension point is not a plug-in runtime
library like the ones specified in <runtime>. It is simply an attribute to
that extension point. So, your plug-in's classloader will not have
lib/myjar.jar in its classpath.
For example:
<plugin>
   <runtime>
     <library name="myplugin.jar"/>
   </runtime>
 <extension point="org.eclipse.ant.core.antTasks">
    <antTask name="myTask" class="com.examples.MyTask"
             library="lib/myjar.jar"/>
 </extension>
</plugin>
We'll create a classloader that has lib/myjar.jar in its classpath. If this
new classloader does not find a class in lib/myjar.jar it will ask your
plug-in's classloader for it. That's how MyTask can find plug-in classes.
Hope that helps,
Rodrigo
                                                                                                                              
                      Aldo_Eisma@xxxxxxx                                                                                      
                      Sent by:                        To:      platform-ant-dev@xxxxxxxxxxx                                   
                      platform-ant-dev-admin@         cc:                                                                     
                      eclipse.org                     Subject: Re: [platform-ant-dev] Heads up: Eclipse Ant Support will be   
                                                      changing                                                                
                                                                                                                              
                      04/04/2002 11:35 AM                                                                                     
                      Please respond to                                                                                       
                      platform-ant-dev                                                                                        
                                                                                                                              
                                                                                                                              
Why do I have to specify a library in the new XML element you are
proposing?
> <extension point="org.eclipse.ant.core.antTasks">
>    <antTask name="myTask" class="com.examples.MyTask"
>             library="lib/myjar.jar"/>
> </extension>
>
> The contributions to these extension points are used to automatically
> include
> these library JARs on the Ant classpath, and to fabricate appropriate Ant
> taskdefs. And any plug-in that contributes to these extension points is
> automatically included on the classpath as a collaborating class loader.
You claim that the classloader of a plug-in that contributes to this
extension point is automatically included on the classpath. Doesn't that
mean that class com.examples.MyTask will be found in the plug-in jar?
If not, how can MyTask in turn refer to plug-in classes that are not
in myjar.jar?
-Aldo
_______________________________________________
platform-ant-dev mailing list
platform-ant-dev@xxxxxxxxxxx
http://dev.eclipse.org/mailman/listinfo/platform-ant-dev