ant-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Peter Donald <pe...@apache.org>
Subject Re: xml namespace support in ant2
Date Thu, 05 Sep 2002 23:08:50 GMT
On Thu, 5 Sep 2002 20:08, Wannheden, Knut wrote:
> I know this topic has been brought up before (e.g. in "Optional tasks"
> thread of last december [1]), but I still wonder what is the actual plan
> for the accepted requirement for Ant2.

I don't think there is any plan for it at this stage. There are too many 
potential uses of namespaces and associated confusion. Do you namespace;
* property names
* types (aka tasks, datatypes, condtions, etc)
* property evaluation (ie "${javascript:performMagic()}"
* target names (ie if you depend on foo:bar target will that execute bar 
target in foo project?)
* aspects (ie add ant:fail-on-error="true" to all tasks)

That is too confusing for me as a developer. I would pity the user who had to 
try and understand a buildfile for that.

> <project xmlns="http://jakarta.apache.org/Ant/v2"
>          xmlns:my="urn:my-ant-tasks"
>          default="test">
>
>  <taskdef qname="my:foo" classname="org.bar.FooTask"/>
>  <taskdef name="baz" ns="urn:my-ant-tasks" classname="org.bar.BazTask"/>
>
>  <target name="test">
>   <echo message="test"/>
>   <my:foo/>
>   <whatever:baz xmlns:whatever="urn:my-ant-tasks"/>
>  </target>
>
> </project>
>
> (Note the two different uses of <taskdef>.)

type aliasing is no problem but I think that is independent of the main issue.

However I think you will find it hard pressed to validate anything without the 
runtime context being present. It may be possible but I think that it would 
need to be seen to be believed ;)

-- 
Cheers,

Peter Donald
----------------------------------------
"Liberty means responsibility. That is 
      why most men dread it." - Locke
---------------------------------------- 


--
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