ant-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Keith Wannamaker" <Ke...@Wannamaker.org>
Subject RE: classloader for factories
Date Sat, 18 May 2002 15:58:19 GMT
Ok, of course the earlier attempt won't work because JspC
will be deferred to the parent classloader.

This is the solution I came up with is this:

I extended JspC to create my own dummy jspc task.
Since this new class lives in my custom task jar, any
classes (adapters) it loads will be loaded from the
taskdef classpath rather than the system classpath.

However, can this change be made, so the new stub jspc
class does at least one useful thing (sets the default
compiler)?

Thanks,
Keith


Index: src/main/org/apache/tools/ant/taskdefs/optional/jsp/JspC.java
===================================================================
RCS file: /home/cvs/jakarta-ant/src/main/org/apache/tools/ant/taskdefs/optional/
jsp/JspC.java,v
retrieving revision 1.16
diff -u -r1.16 JspC.java
--- src/main/org/apache/tools/ant/taskdefs/optional/jsp/JspC.java       15 Apr 2
002 14:56:33 -0000      1.16
+++ src/main/org/apache/tools/ant/taskdefs/optional/jsp/JspC.java       18 May 2
002 14:50:36 -0000
@@ -117,7 +117,7 @@
     private File destDir;
     private String packageName ;
     /** name of the compiler to use */
-    private String compilerName = "jasper";
+    protected String compilerName = "jasper";

     /**
      *  -ieplugin <clsid>Java Plugin classid for Internet Explorer



--
To unsubscribe, e-mail:   <mailto:ant-dev-unsubscribe@jakarta.apache.org>
For additional commands, e-mail: <mailto:ant-dev-help@jakarta.apache.org>


Mime
View raw message