On Saturday 17 May 2003 20:13, Costin Manolache wrote: > peter reilly wrote: > > for example: > > > > <typedef resource="org/acme/mydefinitions.xml" classpath="classes"/> > > > > to allow loading of tasks/types from different 3rd party with some tasks > > haveing the same name, I have added a "prefix" attribute. > > > > <taskdef resource="net/sf/antcontrib/antcontrib.properties" > > prefix="antcontrib."/> > > <taskdef resource=".../antelope.properties" prefix="antelope"/> > > What is the prefix doing ? Is it related with NS, or are you using > it with non-namespaces ant ? > > I don't think it's a good idea to try to support both NS and > "prefix.element" notation. For simple antfiles, just place all > elements in the default NS ( i.e. no ns is used ). If name conflicts - > use the standard mechanism to resolve name conflicts, which in XML is > the namespaces. > > It would be confusing to have "another" way to solve name conflicts.
+1 After playing with the code, I have found that the build script visible prefix is not needed and it is not a good idea (i.e. confusing). My current code has removed the "prefix" and "antlib" attributes to typedef. The "uri" attribute is left to allow the build script author to place the definitions in a different XML NS if required. Peter