13.07.2015 Views

Java™ Application Development on Linux - Dator

Java™ Application Development on Linux - Dator

Java™ Application Development on Linux - Dator

SHOW MORE
SHOW LESS

You also want an ePaper? Increase the reach of your titles

YUMPU automatically turns print PDFs into web optimized ePapers that Google loves.

9.4 A Sample Ant Buildfile227debugIndicates whether the source should be compiled with debug informati<strong>on</strong>;defaults to off. If set to off, -g:n<strong>on</strong>e will be passed <strong>on</strong> the commandline to compilers that support it (for other compilers, no command-lineargument will be used). If set to true, the value of the debuglevelattribute determines the command-line argument.debuglevelKeyword list to be appended to the -g command-line switch. This will beignored by all implementati<strong>on</strong>s except modern and classic (versi<strong>on</strong> 1.2 andmore recent). Legal values are n<strong>on</strong>e or a comma-separated list of the followingkeywords: lines, vars, and source. If debuglevel is notspecified (by default) nothing will be appended to -g. If debug is notturned <strong>on</strong>, this attribute will be ignored.optimizeIndicates whether compilati<strong>on</strong> should include optimizati<strong>on</strong>; defaultsto off.deprecati<strong>on</strong>Indicates whether source should be compiled with deprecati<strong>on</strong> informati<strong>on</strong>;defaults to off.verboseAsks the compiler for verbose output; defaults to no.dependEnables dependency tracking for compilers that support this (Jikes andclassic).The jar task. The jar task makes a JAR file.The javadoc task. One of the greatest benefits of developing in Java is thenearly automatic generati<strong>on</strong> of thorough and correct documentati<strong>on</strong>. Javadocis the tool that does the job, and the javadoc task is the way to automatedocument producti<strong>on</strong> in ant. This tag has a number of attributes that specifywhere the source to be documented is located, how the documentati<strong>on</strong> is to beproduced, and where the documentati<strong>on</strong> is to be placed.The copy and mkdir tasks. These tasks are used to copy files and makedirectories.

Hooray! Your file is uploaded and ready to be published.

Saved successfully!

Ooh no, something went wrong!