Go Back   Velocity Reviews > Newsgroups > Java
User Name
Password
Register FAQ Members List Calendar Search Today's Posts Mark Forums Read

Reply

Java - Schema for build.xml in Ant: Is there one?

 
Thread Tools Search this Thread
Old 10-02-2004, 01:18 AM   #1
Default Schema for build.xml in Ant: Is there one?


I'm trying to use Ant, and I don't see a schema for build.xml. Is it
defined anywhere?
Thanks!
ion


Ion Chalmers Freeman
  Reply With Quote
Old 10-02-2004, 09:15 AM   #2
Tor Iver Wilhelmsen
 
Posts: n/a
Default Re: Schema for build.xml in Ant: Is there one?
(Ion Chalmers Freeman) writes:

> I'm trying to use Ant, and I don't see a schema for build.xml. Is it
> defined anywhere?


No.

To quote
http://phd.netcomp.monash.edu.au/Rob...l/default.asp:

"Ant build files must be well formed XML documents. However, there
are no formal DTD's or XML Schemas for Ant build files. Ant doesn't
have DTD's or XML Schemas essentially because the rules for a valid
Ant build file can change so easily. For example, Ant allows you to
create your own types of XML elements and use them in your build
files - which would immediately make your build file invalid
according to the 'standard' DTD or XML Schema."

So the reason is that ant is a collection of custom rules, with ant
tasks (new tags) "plugged in" as needed. It would be hell if every
task was another namespace, which would be the consequence of
requiring a schema or DTD.


Tor Iver Wilhelmsen
  Reply With Quote
Old 10-02-2004, 03:34 PM   #3
Dave Glasser
 
Posts: n/a
Default Re: Schema for build.xml in Ant: Is there one?
(Ion Chalmers Freeman) wrote on 1 Oct 2004
17:18:34 -0700 in comp.lang.java.programmer:

>I'm trying to use Ant, and I don't see a schema for build.xml. Is it
>defined anywhere?



You can generate a DTD for a build.xml file with the antstructure
task:

<target name="dtd">
<antstructure output="project.dtd"/>
</target>


--
Check out QueryForm, a free, open source, Java/Swing-based
front end for relational databases.

http://qform.sourceforge.net

If you're a musician, check out RPitch Relative Pitch
Ear Training Software.

http://rpitch.sourceforge.net


Dave Glasser
  Reply With Quote
Old 01-07-2005, 04:45 PM   #4
ion
 
Posts: n/a
Default Re: Schema for build.xml in Ant: Is there one?
Well, that's ... interesting. Thanks!



ion
  Reply With Quote
Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are Off
Pingbacks are Off
Refbacks are Off




SEO by vBSEO 3.3.2 ©2009, Crawlability, Inc.

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46