Java Mailing List Archive

http://www.ant-tasks.com/

Apache Ant Archive

» Ant Users List
» Ant Developers List
Any examples of how we can simplify ant build.xml with templa tes (?)

Any examples of how we can simplify ant build.xml with templa tes (?)

2004-02-04       - By Erik Hatcher
Reply:     1     2  

On Feb 4, 2004, at 1:15 AM, Jan.Materne@(protected) wrote:
> child/build.xml
> - import the template.xml
> - override targets, if needed (see "Target overriding" in import?s
> manual)
>     class Super { void meth(); }
>     class Sub
>       extends Super {          -->  <import>
>         void newMeth();        -->  <target>
>         void meth() {
>              super.meth();     -->  <antcall target="Super.meth"/>
>         }
>     }

Is there a way to call "super" in this scenario without using <antcall>?

Another interesting trick is to define "abstract" targets in the super
build which require implementation in the sub build.  So rather than
overriding targets, I think I prefer to define pre abstract targets.

  Erik


---------------------------------------------------------------------
To unsubscribe, e-mail: user-unsubscribe@(protected)
For additional commands, e-mail: user-help@(protected)



©2008 ant-tasks.com - Jax Systems, LLC, U.S.A.