1 <?xml version="1.0" encoding="UTF-8"?>
3 *** GENERATED FROM project.xml - DO NOT EDIT ***
4 *** EDIT ../build.xml INSTEAD ***
6 For the purpose of easier reading the script
7 is divided into following sections:
20 <project xmlns:webproject1="http://www.netbeans.org/ns/web-project/1" xmlns:webproject2="http://www.netbeans.org/ns/web-project/2" xmlns:webproject3="http://www.netbeans.org/ns/web-project/3" basedir=".." default="default" name="pizzaservice-war-impl">
21 <import file="ant-deploy.xml"/>
22 <fail message="Please build using Ant 1.7.1 or higher.">
25 <antversion atleast="1.7.1"/>
29 <target depends="dist,javadoc" description="Build whole project." name="default"/>
31 INITIALIZATION SECTION
33 <target name="-pre-init">
34 <!-- Empty placeholder for easier customization. -->
35 <!-- You can override this target in the ../build.xml file. -->
37 <target depends="-pre-init" name="-init-private">
38 <property file="nbproject/private/private.properties"/>
40 <target name="-pre-init-libraries">
41 <property location="./lib/nblibraries.properties" name="libraries.path"/>
42 <dirname file="${libraries.path}" property="libraries.dir.nativedirsep"/>
43 <pathconvert dirsep="/" property="libraries.dir">
44 <path path="${libraries.dir.nativedirsep}"/>
46 <basename file="${libraries.path}" property="libraries.basename" suffix=".properties"/>
47 <available file="${libraries.dir}/${libraries.basename}-private.properties" property="private.properties.available"/>
49 <target depends="-pre-init-libraries" if="private.properties.available" name="-init-private-libraries">
50 <loadproperties encoding="ISO-8859-1" srcfile="${libraries.dir}/${libraries.basename}-private.properties">
52 <replacestring from="$${base}" to="${libraries.dir}"/>
57 <target depends="-pre-init,-init-private,-init-private-libraries" name="-init-libraries">
58 <loadproperties encoding="ISO-8859-1" srcfile="${libraries.path}">
60 <replacestring from="$${base}" to="${libraries.dir}"/>
65 <target depends="-pre-init,-init-private,-init-libraries" name="-init-user">
66 <property file="${user.properties.file}"/>
67 <!-- The two properties below are usually overridden -->
68 <!-- by the active platform. Just a fallback. -->
69 <property name="default.javac.source" value="1.4"/>
70 <property name="default.javac.target" value="1.4"/>
72 <target depends="-pre-init,-init-private,-init-libraries,-init-user" name="-init-project">
73 <property file="nbproject/project.properties"/>
75 <target depends="-pre-init,-init-private,-init-user,-init-project,-init-macrodef-property" if="dist.ear.dir" name="-do-ear-init"/>
76 <target depends="-pre-init,-init-private,-init-libraries,-init-user,-init-project,-init-macrodef-property" name="-do-init">
77 <condition property="have.tests">
79 <available file="${test.src.dir}"/>
82 <condition property="have.sources">
84 <available file="${src.dir}"/>
87 <condition property="netbeans.home+have.tests">
89 <isset property="netbeans.home"/>
90 <isset property="have.tests"/>
93 <condition property="no.javadoc.preview">
94 <isfalse value="${javadoc.preview}"/>
96 <property name="javac.compilerargs" value=""/>
97 <condition property="no.deps">
99 <istrue value="${no.dependencies}"/>
102 <condition property="no.dist.ear.dir">
104 <isset property="dist.ear.dir"/>
107 <property name="build.web.excludes" value="${build.classes.excludes}"/>
108 <condition property="do.compile.jsps">
109 <istrue value="${compile.jsps}"/>
111 <condition property="do.debug.server">
114 <isset property="debug.server"/>
116 <istrue value="${debug.server}"/>
119 <istrue value="${debug.server}"/>
122 <istrue value="${debug.client}"/>
127 <condition property="do.debug.client">
128 <istrue value="${debug.client}"/>
130 <condition property="do.display.browser">
131 <istrue value="${display.browser}"/>
133 <condition property="do.display.browser.debug.old">
135 <isset property="do.display.browser"/>
137 <isset property="do.debug.client"/>
140 <isset property="browser.context"/>
144 <condition property="do.display.browser.debug">
146 <isset property="do.display.browser"/>
148 <isset property="do.debug.client"/>
150 <isset property="browser.context"/>
153 <available file="${conf.dir}/MANIFEST.MF" property="has.custom.manifest"/>
154 <available file="${persistence.xml.dir}/persistence.xml" property="has.persistence.xml"/>
155 <condition property="do.war.package.with.custom.manifest">
156 <isset property="has.custom.manifest"/>
158 <condition property="do.war.package.without.custom.manifest">
160 <isset property="has.custom.manifest"/>
163 <condition property="do.tmp.war.package.with.custom.manifest">
165 <isset property="has.custom.manifest"/>
167 <isfalse value="${directory.deployment.supported}"/>
168 <isset property="dist.ear.dir"/>
172 <condition property="do.tmp.war.package.without.custom.manifest">
175 <isset property="has.custom.manifest"/>
178 <isfalse value="${directory.deployment.supported}"/>
179 <isset property="dist.ear.dir"/>
183 <condition property="do.tmp.war.package">
185 <isfalse value="${directory.deployment.supported}"/>
186 <isset property="dist.ear.dir"/>
189 <property name="build.meta.inf.dir" value="${build.web.dir}/META-INF"/>
190 <condition else="" property="application.args.param" value="${application.args}">
192 <isset property="application.args"/>
194 <equals arg1="${application.args}" arg2="" trim="true"/>
198 <property name="source.encoding" value="${file.encoding}"/>
199 <condition property="javadoc.encoding.used" value="${javadoc.encoding}">
201 <isset property="javadoc.encoding"/>
203 <equals arg1="${javadoc.encoding}" arg2=""/>
207 <property name="javadoc.encoding.used" value="${source.encoding}"/>
208 <property name="includes" value="**"/>
209 <property name="excludes" value=""/>
210 <property name="runmain.jvmargs" value=""/>
211 <path id="endorsed.classpath.path" path="${endorsed.classpath}"/>
212 <condition else="" property="endorsed.classpath.cmd.line.arg" value="-Xbootclasspath/p:'${toString:endorsed.classpath.path}'">
214 <isset property="endorsed.classpath"/>
215 <length length="0" string="${endorsed.classpath}" when="greater"/>
218 <condition else="false" property="jdkBug6558476">
220 <matches pattern="1\.[56]" string="${java.specification.version}"/>
226 <property name="javac.fork" value="${jdkBug6558476}"/>
227 <condition property="junit.available">
229 <available classname="org.junit.Test" classpath="${run.test.classpath}"/>
230 <available classname="junit.framework.Test" classpath="${run.test.classpath}"/>
233 <condition property="testng.available">
234 <available classname="org.testng.annotations.Test" classpath="${run.test.classpath}"/>
236 <condition property="junit+testng.available">
238 <istrue value="${junit.available}"/>
239 <istrue value="${testng.available}"/>
242 <condition else="testng" property="testng.mode" value="mixed">
243 <istrue value="${junit+testng.available}"/>
245 <condition else="" property="testng.debug.mode" value="-mixed">
246 <istrue value="${junit+testng.available}"/>
249 <target depends="init" name="-init-cos" unless="deploy.on.save">
250 <condition property="deploy.on.save" value="true">
252 <istrue value="${j2ee.deploy.on.save}"/>
253 <istrue value="${j2ee.compile.on.save}"/>
257 <target name="-post-init">
258 <!-- Empty placeholder for easier customization. -->
259 <!-- You can override this target in the ../build.xml file. -->
261 <target depends="-pre-init,-init-private,-init-libraries,-init-user,-init-project,-do-init" name="-init-check">
262 <fail unless="src.dir">Must set src.dir</fail>
263 <fail unless="test.src.dir">Must set test.src.dir</fail>
264 <fail unless="build.dir">Must set build.dir</fail>
265 <fail unless="build.web.dir">Must set build.web.dir</fail>
266 <fail unless="build.generated.dir">Must set build.generated.dir</fail>
267 <fail unless="dist.dir">Must set dist.dir</fail>
268 <fail unless="build.classes.dir">Must set build.classes.dir</fail>
269 <fail unless="dist.javadoc.dir">Must set dist.javadoc.dir</fail>
270 <fail unless="build.test.classes.dir">Must set build.test.classes.dir</fail>
271 <fail unless="build.test.results.dir">Must set build.test.results.dir</fail>
272 <fail unless="build.classes.excludes">Must set build.classes.excludes</fail>
273 <fail unless="dist.war">Must set dist.war</fail>
274 <condition property="missing.j2ee.server.home">
276 <matches pattern="j2ee.server.home" string="${j2ee.platform.classpath}"/>
278 <isset property="j2ee.server.home"/>
282 <fail if="missing.j2ee.server.home">
283 The Java EE server classpath is not correctly set up - server home directory is missing.
284 Either open the project in the IDE and assign the server or setup the server classpath manually.
285 For example like this:
286 ant -Dj2ee.server.home=<app_server_installation_directory>
288 <fail unless="j2ee.platform.classpath">
289 The Java EE server classpath is not correctly set up. Your active server type is ${j2ee.server.type}.
290 Either open the project in the IDE and assign the server or setup the server classpath manually.
291 For example like this:
292 ant -Duser.properties.file=<path_to_property_file> (where you put the property "j2ee.platform.classpath" in a .properties file)
293 or ant -Dj2ee.platform.classpath=<server_classpath> (where no properties file is used)
296 <target name="-init-macrodef-property">
297 <macrodef name="property" uri="http://www.netbeans.org/ns/web-project/1">
298 <attribute name="name"/>
299 <attribute name="value"/>
301 <property name="@{name}" value="${@{value}}"/>
305 <target depends="-init-ap-cmdline-properties" if="ap.supported.internal" name="-init-macrodef-javac-with-processors">
306 <macrodef name="javac" uri="http://www.netbeans.org/ns/web-project/2">
307 <attribute default="${src.dir}" name="srcdir"/>
308 <attribute default="${build.classes.dir}" name="destdir"/>
309 <attribute default="${javac.classpath}:${j2ee.platform.classpath}" name="classpath"/>
310 <attribute default="${javac.processorpath}" name="processorpath"/>
311 <attribute default="${build.generated.sources.dir}/ap-source-output" name="apgeneratedsrcdir"/>
312 <attribute default="${includes}" name="includes"/>
313 <attribute default="${excludes}" name="excludes"/>
314 <attribute default="${javac.debug}" name="debug"/>
315 <attribute default="${empty.dir}" name="gensrcdir"/>
316 <element name="customize" optional="true"/>
318 <property location="${build.dir}/empty" name="empty.dir"/>
319 <mkdir dir="${empty.dir}"/>
320 <mkdir dir="@{apgeneratedsrcdir}"/>
321 <javac debug="@{debug}" deprecation="${javac.deprecation}" destdir="@{destdir}" encoding="${source.encoding}" excludes="@{excludes}" fork="${javac.fork}" includeantruntime="false" includes="@{includes}" source="${javac.source}" srcdir="@{srcdir}" target="${javac.target}">
323 <dirset dir="@{gensrcdir}" erroronmissingdir="false">
328 <path path="@{classpath}"/>
330 <compilerarg line="${endorsed.classpath.cmd.line.arg}"/>
331 <compilerarg line="${javac.compilerargs}"/>
332 <compilerarg value="-processorpath"/>
333 <compilerarg path="@{processorpath}:${empty.dir}"/>
334 <compilerarg line="${ap.processors.internal}"/>
335 <compilerarg value="-s"/>
336 <compilerarg path="@{apgeneratedsrcdir}"/>
337 <compilerarg line="${ap.proc.none.internal}"/>
343 <target depends="-init-ap-cmdline-properties" name="-init-macrodef-javac-without-processors" unless="ap.supported.internal">
344 <macrodef name="javac" uri="http://www.netbeans.org/ns/web-project/2">
345 <attribute default="${src.dir}" name="srcdir"/>
346 <attribute default="${build.classes.dir}" name="destdir"/>
347 <attribute default="${javac.classpath}:${j2ee.platform.classpath}" name="classpath"/>
348 <attribute default="${javac.processorpath}" name="processorpath"/>
349 <attribute default="${build.generated.sources.dir}/ap-source-output" name="apgeneratedsrcdir"/>
350 <attribute default="${includes}" name="includes"/>
351 <attribute default="${excludes}" name="excludes"/>
352 <attribute default="${javac.debug}" name="debug"/>
353 <attribute default="${empty.dir}" name="gensrcdir"/>
354 <element name="customize" optional="true"/>
356 <property location="${build.dir}/empty" name="empty.dir"/>
357 <mkdir dir="${empty.dir}"/>
358 <javac debug="@{debug}" deprecation="${javac.deprecation}" destdir="@{destdir}" encoding="${source.encoding}" excludes="@{excludes}" includeantruntime="false" includes="@{includes}" source="${javac.source}" srcdir="@{srcdir}" target="${javac.target}">
360 <dirset dir="@{gensrcdir}" erroronmissingdir="false">
365 <path path="@{classpath}"/>
367 <compilerarg line="${endorsed.classpath.cmd.line.arg}"/>
368 <compilerarg line="${javac.compilerargs}"/>
374 <target depends="-init-macrodef-javac-with-processors,-init-macrodef-javac-without-processors" name="-init-macrodef-javac">
375 <macrodef name="depend" uri="http://www.netbeans.org/ns/web-project/2">
376 <attribute default="${src.dir}" name="srcdir"/>
377 <attribute default="${build.classes.dir}" name="destdir"/>
378 <attribute default="${javac.classpath}:${j2ee.platform.classpath}" name="classpath"/>
380 <depend cache="${build.dir}/depcache" destdir="@{destdir}" excludes="${excludes}" includes="${includes}" srcdir="@{srcdir}">
382 <path path="@{classpath}"/>
387 <macrodef name="force-recompile" uri="http://www.netbeans.org/ns/web-project/2">
388 <attribute default="${build.classes.dir}" name="destdir"/>
390 <fail unless="javac.includes">Must set javac.includes</fail>
391 <pathconvert pathsep="${line.separator}" property="javac.includes.binary">
393 <filelist dir="@{destdir}" files="${javac.includes}"/>
395 <globmapper from="*.java" to="*.class"/>
397 <tempfile deleteonexit="true" property="javac.includesfile.binary"/>
398 <echo file="${javac.includesfile.binary}" message="${javac.includes.binary}"/>
400 <files includesfile="${javac.includesfile.binary}"/>
402 <delete file="${javac.includesfile.binary}"/>
406 <target if="${junit.available}" name="-init-macrodef-junit-init">
407 <condition else="false" property="nb.junit.batch" value="true">
409 <istrue value="${junit.available}"/>
411 <isset property="test.method"/>
415 <condition else="false" property="nb.junit.single" value="true">
417 <istrue value="${junit.available}"/>
418 <isset property="test.method"/>
422 <target name="-init-test-properties">
423 <property name="test.binaryincludes" value="<nothing>"/>
424 <property name="test.binarytestincludes" value=""/>
425 <property name="test.binaryexcludes" value=""/>
427 <target if="${nb.junit.single}" name="-init-macrodef-junit-single" unless="${nb.junit.batch}">
428 <macrodef name="junit" uri="http://www.netbeans.org/ns/web-project/2">
429 <attribute default="${includes}" name="includes"/>
430 <attribute default="${excludes}" name="excludes"/>
431 <attribute default="**" name="testincludes"/>
432 <attribute default="" name="testmethods"/>
433 <element name="customize" optional="true"/>
435 <junit dir="${basedir}" errorproperty="tests.failed" failureproperty="tests.failed" fork="true" showoutput="true" tempdir="${java.io.tmpdir}">
436 <test methods="@{testmethods}" name="@{testincludes}" todir="${build.test.results.dir}"/>
438 <propertyref prefix="test-sys-prop."/>
439 <mapper from="test-sys-prop.*" to="*" type="glob"/>
441 <formatter type="brief" usefile="false"/>
442 <formatter type="xml"/>
443 <jvmarg value="-ea"/>
449 <target depends="-init-test-properties" if="${nb.junit.batch}" name="-init-macrodef-junit-batch" unless="${nb.junit.single}">
450 <macrodef name="junit" uri="http://www.netbeans.org/ns/web-project/2">
451 <attribute default="${includes}" name="includes"/>
452 <attribute default="${excludes}" name="excludes"/>
453 <attribute default="**" name="testincludes"/>
454 <attribute default="" name="testmethods"/>
455 <element name="customize" optional="true"/>
457 <property name="run.jvmargs.ide" value=""/>
458 <junit dir="${basedir}" errorproperty="tests.failed" failureproperty="tests.failed" fork="true" showoutput="true" tempdir="${build.dir}">
459 <batchtest todir="${build.test.results.dir}">
460 <fileset dir="${test.src.dir}" excludes="@{excludes},${excludes}" includes="@{includes}">
461 <filename name="@{testincludes}"/>
463 <fileset dir="${build.test.classes.dir}" excludes="@{excludes},${excludes},${test.binaryexcludes}" includes="${test.binaryincludes}">
464 <filename name="${test.binarytestincludes}"/>
468 <propertyref prefix="test-sys-prop."/>
469 <mapper from="test-sys-prop.*" to="*" type="glob"/>
471 <formatter type="brief" usefile="false"/>
472 <formatter type="xml"/>
473 <jvmarg value="-ea"/>
474 <jvmarg line="${run.jvmargs.ide}"/>
480 <target depends="-init-macrodef-junit-init,-init-macrodef-junit-single, -init-macrodef-junit-batch" if="${junit.available}" name="-init-macrodef-junit"/>
481 <target if="${testng.available}" name="-init-macrodef-testng">
482 <macrodef name="testng" uri="http://www.netbeans.org/ns/web-project/2">
483 <attribute default="${includes}" name="includes"/>
484 <attribute default="${excludes}" name="excludes"/>
485 <attribute default="**" name="testincludes"/>
486 <attribute default="" name="testmethods"/>
487 <element name="customize" optional="true"/>
489 <condition else="" property="testng.methods.arg" value="@{testincludes}.@{testmethods}">
490 <isset property="test.method"/>
492 <union id="test.set">
493 <fileset dir="${test.src.dir}" excludes="@{excludes},**/*.xml,${excludes}" includes="@{includes}">
494 <filename name="@{testincludes}"/>
497 <taskdef classname="org.testng.TestNGAntTask" classpath="${run.test.classpath}" name="testng"/>
498 <testng classfilesetref="test.set" failureProperty="tests.failed" listeners="org.testng.reporters.VerboseReporter" methods="${testng.methods.arg}" mode="${testng.mode}" outputdir="${build.test.results.dir}" suitename="pizzaservice-war" testname="TestNG tests" workingDir="${basedir}">
499 <xmlfileset dir="${build.test.classes.dir}" includes="@{testincludes}"/>
501 <propertyref prefix="test-sys-prop."/>
502 <mapper from="test-sys-prop.*" to="*" type="glob"/>
509 <target name="-init-macrodef-test-impl">
510 <macrodef name="test-impl" uri="http://www.netbeans.org/ns/web-project/2">
511 <attribute default="${includes}" name="includes"/>
512 <attribute default="${excludes}" name="excludes"/>
513 <attribute default="**" name="testincludes"/>
514 <attribute default="" name="testmethods"/>
515 <element implicit="true" name="customize" optional="true"/>
517 <echo>No tests executed.</echo>
521 <target depends="-init-macrodef-junit" if="${junit.available}" name="-init-macrodef-junit-impl">
522 <macrodef name="test-impl" uri="http://www.netbeans.org/ns/web-project/2">
523 <attribute default="${includes}" name="includes"/>
524 <attribute default="${excludes}" name="excludes"/>
525 <attribute default="**" name="testincludes"/>
526 <attribute default="" name="testmethods"/>
527 <element implicit="true" name="customize" optional="true"/>
529 <webproject2:junit excludes="@{excludes}" includes="@{includes}" testincludes="@{testincludes}" testmethods="@{testmethods}">
535 <target depends="-init-macrodef-testng" if="${testng.available}" name="-init-macrodef-testng-impl">
536 <macrodef name="test-impl" uri="http://www.netbeans.org/ns/web-project/2">
537 <attribute default="${includes}" name="includes"/>
538 <attribute default="${excludes}" name="excludes"/>
539 <attribute default="**" name="testincludes"/>
540 <attribute default="" name="testmethods"/>
541 <element implicit="true" name="customize" optional="true"/>
543 <webproject2:testng excludes="@{excludes}" includes="@{includes}" testincludes="@{testincludes}" testmethods="@{testmethods}">
545 </webproject2:testng>
549 <target depends="-init-macrodef-test-impl,-init-macrodef-junit-impl,-init-macrodef-testng-impl" name="-init-macrodef-test">
550 <macrodef name="test" uri="http://www.netbeans.org/ns/web-project/2">
551 <attribute default="${includes}" name="includes"/>
552 <attribute default="${excludes}" name="excludes"/>
553 <attribute default="**" name="testincludes"/>
554 <attribute default="" name="testmethods"/>
556 <webproject2:test-impl excludes="@{excludes}" includes="@{includes}" testincludes="@{testincludes}" testmethods="@{testmethods}">
559 <path path="${run.test.classpath}:${j2ee.platform.classpath}:${j2ee.platform.embeddableejb.classpath}"/>
561 <jvmarg line="${endorsed.classpath.cmd.line.arg}"/>
562 <jvmarg line="${runmain.jvmargs}"/>
564 </webproject2:test-impl>
568 <target if="${junit.available}" name="-init-macrodef-junit-debug" unless="${nb.junit.batch}">
569 <macrodef name="junit-debug" uri="http://www.netbeans.org/ns/web-project/2">
570 <attribute default="${includes}" name="includes"/>
571 <attribute default="${excludes}" name="excludes"/>
572 <attribute default="**" name="testincludes"/>
573 <attribute default="" name="testmethods"/>
574 <element name="customize" optional="true"/>
576 <junit dir="${basedir}" errorproperty="tests.failed" failureproperty="tests.failed" fork="true" showoutput="true" tempdir="${java.io.tmpdir}">
577 <test methods="@{testmethods}" name="@{testincludes}" todir="${build.test.results.dir}"/>
579 <propertyref prefix="test-sys-prop."/>
580 <mapper from="test-sys-prop.*" to="*" type="glob"/>
582 <formatter type="brief" usefile="false"/>
583 <formatter type="xml"/>
584 <jvmarg value="-ea"/>
585 <jvmarg value="-agentlib:jdwp=transport=${debug-transport},address=${jpda.address}"/>
591 <target depends="-init-test-properties" if="${nb.junit.batch}" name="-init-macrodef-junit-debug-batch">
592 <macrodef name="junit-debug" uri="http://www.netbeans.org/ns/web-project/2">
593 <attribute default="${includes}" name="includes"/>
594 <attribute default="${excludes}" name="excludes"/>
595 <attribute default="**" name="testincludes"/>
596 <attribute default="" name="testmethods"/>
597 <element name="customize" optional="true"/>
599 <property name="run.jvmargs.ide" value=""/>
600 <junit dir="${basedir}" errorproperty="tests.failed" failureproperty="tests.failed" fork="true" showoutput="true" tempdir="${build.dir}">
601 <batchtest todir="${build.test.results.dir}">
602 <fileset dir="${test.src.dir}" excludes="@{excludes},${excludes}" includes="@{includes}">
603 <filename name="@{testincludes}"/>
605 <fileset dir="${build.test.classes.dir}" excludes="@{excludes},${excludes},${test.binaryexcludes}" includes="${test.binaryincludes}">
606 <filename name="${test.binarytestincludes}"/>
610 <propertyref prefix="test-sys-prop."/>
611 <mapper from="test-sys-prop.*" to="*" type="glob"/>
613 <formatter type="brief" usefile="false"/>
614 <formatter type="xml"/>
615 <jvmarg value="-ea"/>
616 <jvmarg line="${run.jvmargs.ide}"/>
617 <jvmarg value="-agentlib:jdwp=transport=${debug-transport},address=${jpda.address}"/>
623 <target depends="-init-macrodef-junit-debug,-init-macrodef-junit-debug-batch" if="${junit.available}" name="-init-macrodef-junit-debug-impl">
624 <macrodef name="test-debug-impl" uri="http://www.netbeans.org/ns/web-project/2">
625 <attribute default="${includes}" name="includes"/>
626 <attribute default="${excludes}" name="excludes"/>
627 <attribute default="**" name="testincludes"/>
628 <attribute default="" name="testmethods"/>
629 <element implicit="true" name="customize" optional="true"/>
631 <webproject2:junit-debug excludes="@{excludes}" includes="@{includes}" testincludes="@{testincludes}" testmethods="@{testmethods}">
633 </webproject2:junit-debug>
637 <target if="${testng.available}" name="-init-macrodef-testng-debug">
638 <macrodef name="testng-debug" uri="http://www.netbeans.org/ns/web-project/2">
639 <attribute default="${main.class}" name="testClass"/>
640 <attribute default="" name="testMethod"/>
641 <element name="customize2" optional="true"/>
643 <condition else="-testclass @{testClass}" property="test.class.or.method" value="-methods @{testClass}.@{testMethod}">
644 <isset property="test.method"/>
646 <condition else="-suitename pizzaservice-war -testname @{testClass} ${test.class.or.method}" property="testng.cmd.args" value="@{testClass}">
647 <matches pattern=".*\.xml" string="@{testClass}"/>
649 <delete dir="${build.test.results.dir}" quiet="true"/>
650 <mkdir dir="${build.test.results.dir}"/>
651 <webproject1:debug args="${testng.cmd.args}" classname="org.testng.TestNG" classpath="${debug.test.classpath}:${j2ee.platform.embeddableejb.classpath}">
654 <jvmarg value="-ea"/>
655 <arg line="${testng.debug.mode}"/>
656 <arg line="-d ${build.test.results.dir}"/>
657 <arg line="-listener org.testng.reporters.VerboseReporter"/>
663 <target depends="-init-macrodef-testng-debug" if="${testng.available}" name="-init-macrodef-testng-debug-impl">
664 <macrodef name="testng-debug-impl" uri="http://www.netbeans.org/ns/web-project/2">
665 <attribute default="${main.class}" name="testClass"/>
666 <attribute default="" name="testMethod"/>
667 <element implicit="true" name="customize2" optional="true"/>
669 <webproject2:testng-debug testClass="@{testClass}" testMethod="@{testMethod}">
671 </webproject2:testng-debug>
675 <target depends="-init-macrodef-junit-debug-impl" if="${junit.available}" name="-init-macrodef-test-debug-junit">
676 <macrodef name="test-debug" uri="http://www.netbeans.org/ns/web-project/2">
677 <attribute default="${includes}" name="includes"/>
678 <attribute default="${excludes}" name="excludes"/>
679 <attribute default="**" name="testincludes"/>
680 <attribute default="" name="testmethods"/>
681 <attribute default="${main.class}" name="testClass"/>
682 <attribute default="" name="testMethod"/>
684 <webproject2:test-debug-impl excludes="@{excludes}" includes="@{includes}" testincludes="@{testincludes}" testmethods="@{testmethods}">
687 <path path="${run.test.classpath}:${j2ee.platform.classpath}:${j2ee.platform.embeddableejb.classpath}"/>
689 <jvmarg line="${endorsed.classpath.cmd.line.arg}"/>
690 <jvmarg line="${runmain.jvmargs}"/>
692 </webproject2:test-debug-impl>
696 <target depends="-init-macrodef-testng-debug-impl" if="${testng.available}" name="-init-macrodef-test-debug-testng">
697 <macrodef name="test-debug" uri="http://www.netbeans.org/ns/web-project/2">
698 <attribute default="${includes}" name="includes"/>
699 <attribute default="${excludes}" name="excludes"/>
700 <attribute default="**" name="testincludes"/>
701 <attribute default="" name="testmethods"/>
702 <attribute default="${main.class}" name="testClass"/>
703 <attribute default="" name="testMethod"/>
705 <webproject2:testng-debug-impl testClass="@{testClass}" testMethod="@{testMethod}">
708 <propertyref prefix="test-sys-prop."/>
709 <mapper from="test-sys-prop.*" to="*" type="glob"/>
712 </webproject2:testng-debug-impl>
716 <target depends="-init-macrodef-test-debug-junit,-init-macrodef-test-debug-testng" name="-init-macrodef-test-debug"/>
717 <target name="-init-macrodef-java">
718 <macrodef name="java" uri="http://www.netbeans.org/ns/web-project/1">
719 <attribute default="${main.class}" name="classname"/>
720 <attribute default="${debug.classpath}" name="classpath"/>
721 <element name="customize" optional="true"/>
723 <java classname="@{classname}" fork="true">
724 <jvmarg line="${endorsed.classpath.cmd.line.arg}"/>
725 <jvmarg line="${runmain.jvmargs}"/>
727 <path path="@{classpath}:${j2ee.platform.classpath}"/>
730 <propertyref prefix="run-sys-prop."/>
731 <mapper from="run-sys-prop.*" to="*" type="glob"/>
738 <target name="-init-macrodef-nbjsdebug">
739 <macrodef name="nbjsdebugstart" uri="http://www.netbeans.org/ns/web-project/1">
740 <attribute default="${client.url}" name="webUrl"/>
742 <nbjsdebugstart urlPart="${client.urlPart}" webUrl="@{webUrl}"/>
746 <target depends="-init-debug-args" name="-init-macrodef-nbjpda">
747 <macrodef name="nbjpdastart" uri="http://www.netbeans.org/ns/web-project/1">
748 <attribute default="${main.class}" name="name"/>
749 <attribute default="${debug.classpath}:${j2ee.platform.classpath}" name="classpath"/>
751 <nbjpdastart addressproperty="jpda.address" name="@{name}" transport="${debug-transport}">
753 <path path="@{classpath}"/>
758 <macrodef name="nbjpdareload" uri="http://www.netbeans.org/ns/web-project/1">
759 <attribute default="${build.classes.dir}" name="dir"/>
762 <fileset dir="@{dir}" includes="${fix.classes}">
763 <include name="${fix.includes}*.class"/>
768 <macrodef name="nbjpdaappreloaded" uri="http://www.netbeans.org/ns/web-project/1">
774 <target name="-init-debug-args">
775 <condition else="dt_socket" property="debug-transport-by-os" value="dt_shmem">
776 <os family="windows"/>
778 <condition else="${debug-transport-by-os}" property="debug-transport" value="${debug.transport}">
779 <isset property="debug.transport"/>
782 <target depends="-init-debug-args" name="-init-macrodef-debug">
783 <macrodef name="debug" uri="http://www.netbeans.org/ns/web-project/1">
784 <attribute default="${main.class}" name="classname"/>
785 <attribute default="${debug.classpath}:${j2ee.platform.classpath}" name="classpath"/>
786 <attribute default="${application.args.param}" name="args"/>
787 <element name="customize" optional="true"/>
789 <java classname="@{classname}" fork="true">
790 <jvmarg line="${endorsed.classpath.cmd.line.arg}"/>
791 <jvmarg value="-agentlib:jdwp=transport=${debug-transport},address=${jpda.address}"/>
792 <jvmarg line="${runmain.jvmargs}"/>
794 <path path="@{classpath}"/>
797 <propertyref prefix="run-sys-prop."/>
798 <mapper from="run-sys-prop.*" to="*" type="glob"/>
800 <arg line="@{args}"/>
806 <target name="-init-taskdefs">
807 <fail unless="libs.CopyLibs.classpath">
808 The libs.CopyLibs.classpath property is not set up.
809 This property must point to
810 org-netbeans-modules-java-j2seproject-copylibstask.jar file which is part
811 of NetBeans IDE installation and is usually located at
812 <netbeans_installation>/java<version>/ant/extra folder.
813 Either open the project in the IDE and make sure CopyLibs library
814 exists or setup the property manually. For example like this:
815 ant -Dlibs.CopyLibs.classpath=a/path/to/org-netbeans-modules-java-j2seproject-copylibstask.jar
817 <taskdef classpath="${libs.CopyLibs.classpath}" resource="org/netbeans/modules/java/j2seproject/copylibstask/antlib.xml"/>
819 <target name="-init-ap-cmdline-properties">
820 <property name="annotation.processing.enabled" value="true"/>
821 <property name="annotation.processing.processors.list" value=""/>
822 <property name="annotation.processing.run.all.processors" value="true"/>
823 <property name="javac.processorpath" value="${javac.classpath}"/>
824 <property name="javac.test.processorpath" value="${javac.test.classpath}"/>
825 <condition property="ap.supported.internal" value="true">
827 <matches pattern="1\.[0-5](\..*)?" string="${javac.source}"/>
831 <target depends="-init-ap-cmdline-properties" if="ap.supported.internal" name="-init-ap-cmdline-supported">
832 <condition else="" property="ap.processors.internal" value="-processor ${annotation.processing.processors.list}">
833 <isfalse value="${annotation.processing.run.all.processors}"/>
835 <condition else="" property="ap.proc.none.internal" value="-proc:none">
836 <isfalse value="${annotation.processing.enabled}"/>
839 <target depends="-init-ap-cmdline-properties,-init-ap-cmdline-supported" name="-init-ap-cmdline">
840 <property name="ap.cmd.line.internal" value=""/>
843 pre NB7.2 profiling section; consider it deprecated
845 <target depends="-profile-pre-init, init, -profile-post-init, -profile-init-check" if="profiler.info.jvmargs.agent" name="profile-init"/>
846 <target if="profiler.info.jvmargs.agent" name="-profile-pre-init">
847 <!-- Empty placeholder for easier customization. -->
848 <!-- You can override this target in the ../build.xml file. -->
850 <target if="profiler.info.jvmargs.agent" name="-profile-post-init">
851 <!-- Empty placeholder for easier customization. -->
852 <!-- You can override this target in the ../build.xml file. -->
854 <target depends="-profile-pre-init, init, -profile-post-init" if="profiler.info.jvmargs.agent" name="-profile-init-check">
855 <fail unless="profiler.info.jvm">Must set JVM to use for profiling in profiler.info.jvm</fail>
856 <fail unless="profiler.info.jvmargs.agent">Must set profiler agent JVM arguments in profiler.info.jvmargs.agent</fail>
859 end of pre NB7.2 profiling section
861 <target depends="-pre-init,-init-private,-init-libraries,-init-user,-init-project,-do-init,-post-init,-init-check,-init-macrodef-property,-init-macrodef-javac,-init-macrodef-test,-init-macrodef-test-debug,-init-macrodef-java,-init-macrodef-nbjpda,-init-macrodef-nbjsdebug,-init-macrodef-debug,-init-taskdefs,-init-ap-cmdline" name="init"/>
865 <target depends="init" if="no.dist.ear.dir" name="deps-module-jar" unless="no.deps">
866 <ant antfile="${project.pizzaservice-core}/build.xml" inheritall="false" target="jar">
867 <property name="deploy.on.save" value="false"/>
869 <ant antfile="${project.pizzaservice-lib}/build.xml" inheritall="false" target="jar">
870 <property name="deploy.on.save" value="false"/>
873 <target depends="init" if="dist.ear.dir" name="deps-ear-jar" unless="no.deps">
874 <ant antfile="${project.pizzaservice-core}/build.xml" inheritall="false" target="jar">
875 <property name="deploy.on.save" value="false"/>
877 <ant antfile="${project.pizzaservice-lib}/build.xml" inheritall="false" target="jar">
878 <property name="deploy.on.save" value="false"/>
881 <target depends="init, deps-module-jar, deps-ear-jar" name="deps-jar" unless="no.deps"/>
882 <target depends="init,deps-jar" name="-pre-pre-compile">
883 <mkdir dir="${build.classes.dir}"/>
885 <target name="-pre-compile">
886 <!-- Empty placeholder for easier customization. -->
887 <!-- You can override this target in the ../build.xml file. -->
889 <target name="-copy-webdir">
890 <copy todir="${build.web.dir}">
891 <fileset dir="${web.docbase.dir}" excludes="${build.web.excludes},${excludes}" includes="${includes}"/>
893 <copy todir="${build.web.dir}/WEB-INF">
894 <fileset dir="${webinf.dir}" excludes="${build.web.excludes}"/>
897 <target depends="init, deps-jar, -pre-pre-compile, -pre-compile, -copy-manifest, -copy-persistence-xml, -copy-webdir, library-inclusion-in-archive,library-inclusion-in-manifest" if="have.sources" name="-do-compile">
898 <webproject2:javac destdir="${build.classes.dir}" gensrcdir="${build.generated.sources.dir}"/>
899 <copy todir="${build.classes.dir}">
900 <fileset dir="${src.dir}" excludes="${build.classes.excludes},${excludes}" includes="${includes}"/>
903 <target if="has.custom.manifest" name="-copy-manifest">
904 <mkdir dir="${build.meta.inf.dir}"/>
905 <copy todir="${build.meta.inf.dir}">
906 <fileset dir="${conf.dir}" includes="MANIFEST.MF"/>
909 <target if="has.persistence.xml" name="-copy-persistence-xml">
910 <mkdir dir="${build.web.dir}/WEB-INF/classes/META-INF"/>
911 <copy todir="${build.web.dir}/WEB-INF/classes/META-INF">
912 <fileset dir="${persistence.xml.dir}" includes="persistence.xml orm.xml"/>
915 <target name="-post-compile">
916 <!-- Empty placeholder for easier customization. -->
917 <!-- You can override this target in the ../build.xml file. -->
919 <target depends="init,deps-jar,-pre-pre-compile,-pre-compile,-do-compile,-post-compile" description="Compile project." name="compile"/>
920 <target name="-pre-compile-single">
921 <!-- Empty placeholder for easier customization. -->
922 <!-- You can override this target in the ../build.xml file. -->
924 <target depends="init,deps-jar,-pre-pre-compile" name="-do-compile-single">
925 <fail unless="javac.includes">Must select some files in the IDE or set javac.includes</fail>
926 <webproject2:javac excludes="" gensrcdir="${build.generated.sources.dir}" includes="${javac.includes}"/>
927 <copy todir="${build.classes.dir}">
928 <fileset dir="${src.dir}" excludes="${build.classes.excludes},${excludes}" includes="${includes}"/>
931 <target name="-post-compile-single">
932 <!-- Empty placeholder for easier customization. -->
933 <!-- You can override this target in the ../build.xml file. -->
935 <target depends="init,deps-jar,-pre-pre-compile,-pre-compile-single,-do-compile-single,-post-compile-single" name="compile-single"/>
936 <property name="jspc.schemas" value="/resources/schemas/"/>
937 <property name="jspc.dtds" value="/resources/dtds/"/>
938 <target depends="compile" description="Test compile JSP pages to expose compilation errors." if="do.compile.jsps" name="compile-jsps">
939 <mkdir dir="${build.generated.dir}/src"/>
940 <java classname="org.netbeans.modules.web.project.ant.JspC" failonerror="true" fork="true">
941 <arg value="-uriroot"/>
942 <arg file="${basedir}/${build.web.dir}"/>
944 <arg file="${basedir}/${build.generated.dir}/src"/>
946 <arg value="-schemas ${jspc.schemas}"/>
947 <arg value="-dtds ${jspc.dtds}"/>
948 <arg value="-compilerSourceVM ${javac.source}"/>
949 <arg value="-compilerTargetVM ${javac.target}"/>
950 <arg value="-javaEncoding ${source.encoding}"/>
951 <arg value="-sysClasspath ${libs.jsp-compilation-syscp.classpath}"/>
952 <classpath path="${java.home}/../lib/tools.jar:${libs.jsp-compiler.classpath}:${libs.jsp-compilation.classpath}"/>
954 <mkdir dir="${build.generated.dir}/classes"/>
955 <webproject2:javac classpath="${build.classes.dir}:${libs.jsp-compilation.classpath}:${javac.classpath}:${j2ee.platform.classpath}" destdir="${build.generated.dir}/classes" srcdir="${build.generated.dir}/src"/>
957 <target depends="compile" if="jsp.includes" name="-do-compile-single-jsp">
958 <fail unless="javac.jsp.includes">Must select some files in the IDE or set javac.jsp.includes</fail>
959 <mkdir dir="${build.generated.dir}/src"/>
960 <java classname="org.netbeans.modules.web.project.ant.JspCSingle" failonerror="true" fork="true">
961 <arg value="-uriroot"/>
962 <arg file="${basedir}/${build.web.dir}"/>
964 <arg file="${basedir}/${build.generated.dir}/src"/>
966 <arg value="-schemas ${jspc.schemas}"/>
967 <arg value="-dtds ${jspc.dtds}"/>
968 <arg value="-sysClasspath ${libs.jsp-compilation-syscp.classpath}"/>
969 <arg value="-jspc.files"/>
970 <arg path="${jsp.includes}"/>
971 <arg value="-compilerSourceVM ${javac.source}"/>
972 <arg value="-compilerTargetVM ${javac.target}"/>
973 <arg value="-javaEncoding ${source.encoding}"/>
974 <classpath path="${java.home}/../lib/tools.jar:${libs.jsp-compiler.classpath}:${libs.jsp-compilation.classpath}"/>
976 <mkdir dir="${build.generated.dir}/classes"/>
977 <webproject2:javac classpath="${build.classes.dir}:${libs.jsp-compilation.classpath}:${javac.classpath}:${j2ee.platform.classpath}" destdir="${build.generated.dir}/classes" srcdir="${build.generated.dir}/src">
979 <patternset includes="${javac.jsp.includes}"/>
983 <target name="compile-single-jsp">
984 <fail unless="jsp.includes">Must select a file in the IDE or set jsp.includes</fail>
985 <antcall target="-do-compile-single-jsp"/>
988 DIST BUILDING SECTION
990 <target name="-pre-dist">
991 <!-- Empty placeholder for easier customization. -->
992 <!-- You can override this target in the ../build.xml file. -->
994 <target depends="init,compile,compile-jsps,-pre-dist" if="do.war.package.without.custom.manifest" name="-do-dist-without-manifest">
995 <dirname file="${dist.war}" property="dist.jar.dir"/>
996 <mkdir dir="${dist.jar.dir}"/>
997 <jar compress="${jar.compress}" jarfile="${dist.war}">
998 <fileset dir="${build.web.dir}" excludes="WEB-INF/classes/.netbeans_*,${dist.archive.excludes}"/>
1001 <target depends="init,compile,compile-jsps,-pre-dist" if="do.war.package.with.custom.manifest" name="-do-dist-with-manifest">
1002 <dirname file="${dist.war}" property="dist.jar.dir"/>
1003 <mkdir dir="${dist.jar.dir}"/>
1004 <jar compress="${jar.compress}" jarfile="${dist.war}" manifest="${build.meta.inf.dir}/MANIFEST.MF">
1005 <fileset dir="${build.web.dir}" excludes="WEB-INF/classes/.netbeans_*,${dist.archive.excludes}"/>
1008 <target depends="init,compile,compile-jsps,-pre-dist" if="do.tmp.war.package.without.custom.manifest" name="-do-tmp-dist-without-manifest">
1009 <dirname file="${dist.war}" property="dist.jar.dir"/>
1010 <mkdir dir="${dist.jar.dir}"/>
1011 <jar compress="${jar.compress}" jarfile="${dist.war}">
1012 <fileset dir="${build.web.dir}" excludes="WEB-INF/classes/.netbeans_*,${dist.archive.excludes}"/>
1015 <target depends="init,compile,compile-jsps,-pre-dist" if="do.tmp.war.package.with.custom.manifest" name="-do-tmp-dist-with-manifest">
1016 <dirname file="${dist.war}" property="dist.jar.dir"/>
1017 <mkdir dir="${dist.jar.dir}"/>
1018 <jar compress="${jar.compress}" jarfile="${dist.war}" manifest="${build.meta.inf.dir}/MANIFEST.MF">
1019 <fileset dir="${build.web.dir}" excludes="WEB-INF/classes/.netbeans_*,${dist.archive.excludes}"/>
1022 <target depends="init,compile,compile-jsps,-pre-dist,-do-dist-with-manifest,-do-dist-without-manifest" name="do-dist"/>
1023 <target depends="init" if="dist.ear.dir" name="library-inclusion-in-manifest">
1024 <mkdir dir="${build.web.dir}/META-INF"/>
1025 <manifest file="${build.web.dir}/META-INF/MANIFEST.MF" mode="update"/>
1027 <target depends="init" name="library-inclusion-in-archive" unless="dist.ear.dir"/>
1028 <target depends="init" if="dist.ear.dir" name="-clean-webinf-lib">
1029 <delete dir="${build.web.dir}/WEB-INF/lib"/>
1031 <target depends="init,-clean-webinf-lib,compile,compile-jsps,-pre-dist,library-inclusion-in-manifest" if="do.tmp.war.package" name="do-ear-dist">
1032 <dirname file="${dist.ear.war}" property="dist.jar.dir"/>
1033 <mkdir dir="${dist.jar.dir}"/>
1034 <jar compress="${jar.compress}" jarfile="${dist.ear.war}" manifest="${build.web.dir}/META-INF/MANIFEST.MF">
1035 <fileset dir="${build.web.dir}" excludes="WEB-INF/classes/.netbeans_*,${dist.archive.excludes}"/>
1038 <target name="-post-dist">
1039 <!-- Empty placeholder for easier customization. -->
1040 <!-- You can override this target in the ../build.xml file. -->
1042 <target depends="init,compile,-pre-dist,do-dist,-post-dist" description="Build distribution (WAR)." name="dist"/>
1043 <target depends="init,-clean-webinf-lib,-init-cos,compile,-pre-dist,do-ear-dist,-post-dist" description="Build distribution (WAR) to be packaged into an EAR." name="dist-ear"/>
1047 <target depends="run-deploy,run-display-browser" description="Deploy to server and show in browser." name="run"/>
1048 <target name="-pre-run-deploy">
1049 <!-- Empty placeholder for easier customization. -->
1050 <!-- You can override this target in the ../build.xml file. -->
1052 <target name="-post-run-deploy">
1053 <!-- Empty placeholder for easier customization. -->
1054 <!-- You can override this target in the ../build.xml file. -->
1056 <target name="-pre-nbmodule-run-deploy">
1057 <!-- Empty placeholder for easier customization. -->
1058 <!-- This target can be overriden by NetBeans modules. Don't override it directly, use -pre-run-deploy task instead. -->
1060 <target name="-post-nbmodule-run-deploy">
1061 <!-- Empty placeholder for easier customization. -->
1062 <!-- This target can be overriden by NetBeans modules. Don't override it directly, use -post-run-deploy task instead. -->
1064 <target name="-run-deploy-am">
1065 <!-- Task to deploy to the Access Manager runtime. -->
1067 <target depends="init,-init-cos,compile,compile-jsps,-do-compile-single-jsp,-pre-dist,-do-tmp-dist-with-manifest,-do-tmp-dist-without-manifest,-pre-run-deploy,-pre-nbmodule-run-deploy,-run-deploy-nb,-init-deploy-ant,-deploy-ant,-run-deploy-am,-post-nbmodule-run-deploy,-post-run-deploy,-do-update-breakpoints" name="run-deploy"/>
1068 <target if="netbeans.home" name="-run-deploy-nb">
1069 <nbdeploy clientUrlPart="${client.urlPart}" debugmode="false" forceRedeploy="${forceRedeploy}"/>
1071 <target name="-init-deploy-ant" unless="netbeans.home">
1072 <property name="deploy.ant.archive" value="${dist.war}"/>
1073 <property name="deploy.ant.docbase.dir" value="${web.docbase.dir}"/>
1074 <property name="deploy.ant.resource.dir" value="${resource.dir}"/>
1075 <property name="deploy.ant.enabled" value="true"/>
1077 <target depends="dist,-run-undeploy-nb,-init-deploy-ant,-undeploy-ant" name="run-undeploy"/>
1078 <target if="netbeans.home" name="-run-undeploy-nb">
1079 <fail message="Undeploy is not supported from within the IDE"/>
1081 <target depends="init,-pre-dist,dist,-post-dist" name="verify">
1082 <nbverify file="${dist.war}"/>
1084 <target depends="run-deploy,-init-display-browser,-display-browser-nb-old,-display-browser-nb,-display-browser-cl" name="run-display-browser"/>
1085 <target if="do.display.browser" name="-init-display-browser">
1086 <condition property="do.display.browser.nb.old">
1088 <isset property="netbeans.home"/>
1090 <isset property="browser.context"/>
1094 <condition property="do.display.browser.nb">
1096 <isset property="netbeans.home"/>
1097 <isset property="browser.context"/>
1100 <condition property="do.display.browser.cl">
1101 <isset property="deploy.ant.enabled"/>
1104 <target if="do.display.browser.nb.old" name="-display-browser-nb-old">
1105 <nbbrowse url="${client.url}"/>
1107 <target if="do.display.browser.nb" name="-display-browser-nb">
1108 <nbbrowse context="${browser.context}" url="${client.url}" urlPath="${client.urlPart}"/>
1110 <target if="do.display.browser.cl" name="-get-browser" unless="browser">
1111 <condition property="browser" value="rundll32">
1112 <os family="windows"/>
1114 <condition else="" property="browser.args" value="url.dll,FileProtocolHandler">
1115 <os family="windows"/>
1117 <condition property="browser" value="/usr/bin/open">
1120 <property environment="env"/>
1121 <condition property="browser" value="${env.BROWSER}">
1122 <isset property="env.BROWSER"/>
1124 <condition property="browser" value="/usr/bin/firefox">
1125 <available file="/usr/bin/firefox"/>
1127 <condition property="browser" value="/usr/local/firefox/firefox">
1128 <available file="/usr/local/firefox/firefox"/>
1130 <condition property="browser" value="/usr/bin/mozilla">
1131 <available file="/usr/bin/mozilla"/>
1133 <condition property="browser" value="/usr/local/mozilla/mozilla">
1134 <available file="/usr/local/mozilla/mozilla"/>
1136 <condition property="browser" value="/usr/sfw/lib/firefox/firefox">
1137 <available file="/usr/sfw/lib/firefox/firefox"/>
1139 <condition property="browser" value="/opt/csw/bin/firefox">
1140 <available file="/opt/csw/bin/firefox"/>
1142 <condition property="browser" value="/usr/sfw/lib/mozilla/mozilla">
1143 <available file="/usr/sfw/lib/mozilla/mozilla"/>
1145 <condition property="browser" value="/opt/csw/bin/mozilla">
1146 <available file="/opt/csw/bin/mozilla"/>
1149 <target depends="-get-browser" if="do.display.browser.cl" name="-display-browser-cl">
1150 <fail unless="browser">
1151 Browser not found, cannot launch the deployed application. Try to set the BROWSER environment variable.
1153 <property name="browse.url" value="${deploy.ant.client.url}${client.urlPart}"/>
1154 <echo>Launching ${browse.url}</echo>
1155 <exec executable="${browser}" spawn="true">
1156 <arg line="${browser.args} ${browse.url}"/>
1159 <target depends="init,-init-cos,compile-single" name="run-main">
1160 <fail unless="run.class">Must select one file in the IDE or set run.class</fail>
1161 <webproject1:java classname="${run.class}"/>
1163 <target depends="init,compile-test-single,-pre-test-run-single" name="run-test-with-main">
1164 <fail unless="run.class">Must select one file in the IDE or set run.class</fail>
1165 <webproject1:java classname="${run.class}" classpath="${run.test.classpath}"/>
1167 <target depends="init" if="netbeans.home" name="-do-update-breakpoints">
1168 <webproject1:nbjpdaappreloaded/>
1173 <target depends="init,-init-cos,compile,compile-jsps,-do-compile-single-jsp,-pre-dist,-do-tmp-dist-with-manifest,-do-tmp-dist-without-manifest" description="Debug project in IDE." if="netbeans.home" name="debug">
1174 <nbstartserver debugmode="true"/>
1175 <antcall target="connect-debugger"/>
1176 <nbdeploy clientUrlPart="${client.urlPart}" debugmode="true" forceRedeploy="true"/>
1177 <antcall target="debug-display-browser-old"/>
1178 <antcall target="debug-display-browser"/>
1179 <antcall target="connect-client-debugger"/>
1181 <target if="do.debug.server" name="connect-debugger" unless="is.debugged">
1182 <condition property="listeningcp" value="sourcepath">
1183 <istrue value="${j2ee.compile.on.save}"/>
1185 <nbjpdaconnect address="${jpda.address}" host="${jpda.host}" listeningcp="${listeningcp}" name="${name}" transport="${jpda.transport}">
1187 <path path="${debug.classpath}:${j2ee.platform.classpath}"/>
1190 <path path="${web.docbase.dir}"/>
1194 <target if="do.display.browser.debug.old" name="debug-display-browser-old">
1195 <nbbrowse url="${client.url}"/>
1197 <target if="do.display.browser.debug" name="debug-display-browser">
1198 <nbbrowse context="${browser.context}" url="${client.url}" urlPath="${client.urlPart}"/>
1200 <target if="do.debug.client" name="connect-client-debugger">
1201 <webproject1:nbjsdebugstart webUrl="${client.url}"/>
1203 <target depends="init,compile-test-single" if="netbeans.home" name="-debug-start-debuggee-main-test">
1204 <fail unless="debug.class">Must select one file in the IDE or set debug.class</fail>
1205 <webproject1:debug classname="${debug.class}" classpath="${debug.test.classpath}"/>
1207 <target depends="init,compile-test-single,-debug-start-debugger-main-test,-debug-start-debuggee-main-test" if="netbeans.home" name="debug-test-with-main"/>
1208 <target depends="init,compile,compile-jsps,-do-compile-single-jsp,debug" if="netbeans.home" name="debug-single"/>
1209 <target depends="init" if="netbeans.home" name="-debug-start-debugger-main-test">
1210 <webproject1:nbjpdastart classpath="${debug.test.classpath}" name="${debug.class}"/>
1212 <target depends="init" if="netbeans.home" name="-debug-start-debugger">
1213 <webproject1:nbjpdastart name="${debug.class}"/>
1215 <target depends="init,compile-single" if="netbeans.home" name="-debug-start-debuggee-single">
1216 <fail unless="debug.class">Must select one file in the IDE or set debug.class</fail>
1217 <webproject1:debug classname="${debug.class}"/>
1219 <target depends="init,compile-single,-debug-start-debugger,-debug-start-debuggee-single" if="netbeans.home" name="debug-single-main"/>
1220 <target depends="init" name="-pre-debug-fix">
1221 <fail unless="fix.includes">Must set fix.includes</fail>
1222 <property name="javac.includes" value="${fix.includes}.java"/>
1224 <target depends="init,-pre-debug-fix,compile-single" if="netbeans.home" name="-do-debug-fix">
1225 <webproject1:nbjpdareload/>
1227 <target depends="init,-pre-debug-fix,-do-debug-fix" if="netbeans.home" name="debug-fix"/>
1234 pre NB7.2 profiling section; consider it deprecated
1236 <target description="Profile a J2EE project in the IDE." if="profiler.info.jvmargs.agent" name="-profile-pre72">
1237 <condition else="start-profiled-server" property="profiler.startserver.target" value="start-profiled-server-extraargs">
1238 <isset property="profiler.info.jvmargs.extra"/>
1240 <antcall target="${profiler.startserver.target}"/>
1241 <antcall target="run"/>
1242 <antcall target="-profile-start-loadgen"/>
1244 <target if="profiler.info.jvmargs.agent" name="start-profiled-server">
1245 <nbstartprofiledserver forceRestart="${profiler.j2ee.serverForceRestart}" javaPlatform="${profiler.info.javaPlatform}" startupTimeout="${profiler.j2ee.serverStartupTimeout}">
1246 <jvmarg value="${profiler.info.jvmargs.agent}"/>
1247 <jvmarg value="${profiler.j2ee.agentID}"/>
1248 </nbstartprofiledserver>
1250 <target if="profiler.info.jvmargs.agent" name="start-profiled-server-extraargs">
1251 <nbstartprofiledserver forceRestart="${profiler.j2ee.serverForceRestart}" javaPlatform="${profiler.info.javaPlatform}" startupTimeout="${profiler.j2ee.serverStartupTimeout}">
1252 <jvmarg value="${profiler.info.jvmargs.extra}"/>
1253 <jvmarg value="${profiler.info.jvmargs.agent}"/>
1254 <jvmarg value="${profiler.j2ee.agentID}"/>
1255 </nbstartprofiledserver>
1257 <target depends="profile-init,compile-test-single" if="profiler.info.jvmargs.agent" name="-profile-test-single-pre72">
1258 <fail unless="netbeans.home">This target only works when run from inside the NetBeans IDE.</fail>
1261 <path path="${run.test.classpath}"/>
1262 <path path="${j2ee.platform.classpath}"/>
1265 <junit dir="${profiler.info.dir}" errorproperty="tests.failed" failureproperty="tests.failed" fork="true" jvm="${profiler.info.jvm}" showoutput="true">
1266 <env key="${profiler.info.pathvar}" path="${profiler.info.agentpath}:${profiler.current.path}"/>
1267 <jvmarg value="${profiler.info.jvmargs.agent}"/>
1268 <jvmarg line="${profiler.info.jvmargs}"/>
1269 <test name="${profile.class}"/>
1271 <path path="${run.test.classpath}"/>
1272 <path path="${j2ee.platform.classpath}"/>
1275 <propertyref prefix="test-sys-prop."/>
1276 <mapper from="test-sys-prop.*" to="*" type="glob"/>
1278 <formatter type="brief" usefile="false"/>
1279 <formatter type="xml"/>
1282 <target if="netbeans.home" name="-profile-check">
1283 <condition property="profiler.configured">
1285 <contains casesensitive="true" string="${run.jvmargs.ide}" substring="-agentpath:"/>
1286 <contains casesensitive="true" string="${run.jvmargs.ide}" substring="-javaagent:"/>
1290 <target depends="init,-init-cos,compile,compile-jsps,-do-compile-single-jsp,-pre-dist,-do-tmp-dist-with-manifest,-do-tmp-dist-without-manifest" name="-do-profile">
1292 <nbstartserver profilemode="true"/>
1293 <nbdeploy clientUrlPart="${client.urlPart}" forceRedeploy="true" profilemode="true"/>
1294 <antcall target="debug-display-browser-old"/>
1295 <antcall target="debug-display-browser"/>
1296 <antcall target="-profile-start-loadgen"/>
1298 <target depends="-profile-check,-profile-pre72" description="Profile a J2EE project in the IDE." if="profiler.configured" name="profile" unless="profiler.info.jvmargs.agent">
1299 <antcall target="-do-profile"/>
1301 <target depends="-profile-test-single-pre72" name="profile-test-single"/>
1302 <target depends="-profile-check" if="profiler.configured" name="profile-test" unless="profiler.info.jvmargs.agent">
1304 <antcall target="test-single"/>
1306 <target if="profiler.loadgen.path" name="-profile-start-loadgen">
1307 <loadgenstart path="${profiler.loadgen.path}"/>
1312 <target depends="init" if="have.sources" name="javadoc-build">
1313 <mkdir dir="${dist.javadoc.dir}"/>
1314 <javadoc additionalparam="${javadoc.additionalparam}" author="${javadoc.author}" charset="UTF-8" destdir="${dist.javadoc.dir}" docencoding="UTF-8" encoding="${javadoc.encoding.used}" failonerror="true" noindex="${javadoc.noindex}" nonavbar="${javadoc.nonavbar}" notree="${javadoc.notree}" private="${javadoc.private}" source="${javac.source}" splitindex="${javadoc.splitindex}" use="${javadoc.use}" useexternalfile="true" version="${javadoc.version}" windowtitle="${javadoc.windowtitle}">
1316 <path path="${javac.classpath}:${j2ee.platform.classpath}"/>
1318 <fileset dir="${src.dir}" excludes="${excludes}" includes="${includes}">
1319 <filename name="**/*.java"/>
1321 <fileset dir="${build.generated.sources.dir}" erroronmissingdir="false">
1322 <include name="**/*.java"/>
1325 <copy todir="${dist.javadoc.dir}">
1326 <fileset dir="${src.dir}" excludes="${excludes}" includes="${includes}">
1327 <filename name="**/doc-files/**"/>
1329 <fileset dir="${build.generated.sources.dir}" erroronmissingdir="false">
1330 <include name="**/doc-files/**"/>
1334 <target depends="init,javadoc-build" if="netbeans.home" name="javadoc-browse" unless="no.javadoc.preview">
1335 <nbbrowse file="${dist.javadoc.dir}/index.html"/>
1337 <target depends="init,javadoc-build,javadoc-browse" description="Build Javadoc." name="javadoc"/>
1340 TEST COMPILATION SECTION
1342 <target depends="init,compile" if="have.tests" name="-pre-pre-compile-test">
1343 <mkdir dir="${build.test.classes.dir}"/>
1344 <property name="j2ee.platform.embeddableejb.classpath" value=""/>
1346 <target name="-pre-compile-test">
1347 <!-- Empty placeholder for easier customization. -->
1348 <!-- You can override this target in the ../build.xml file. -->
1350 <target depends="init,compile,-pre-pre-compile-test,-pre-compile-test" if="have.tests" name="-do-compile-test">
1351 <webproject2:javac classpath="${javac.test.classpath}:${j2ee.platform.classpath}:${j2ee.platform.embeddableejb.classpath}" debug="true" destdir="${build.test.classes.dir}" srcdir="${test.src.dir}"/>
1352 <copy todir="${build.test.classes.dir}">
1353 <fileset dir="${test.src.dir}" excludes="${build.classes.excludes},${excludes}" includes="${includes}"/>
1356 <target name="-post-compile-test">
1357 <!-- Empty placeholder for easier customization. -->
1358 <!-- You can override this target in the ../build.xml file. -->
1360 <target depends="init,compile,-pre-pre-compile-test,-pre-compile-test,-do-compile-test,-post-compile-test" name="compile-test"/>
1361 <target name="-pre-compile-test-single">
1362 <!-- Empty placeholder for easier customization. -->
1363 <!-- You can override this target in the ../build.xml file. -->
1365 <target depends="init,compile,-pre-pre-compile-test,-pre-compile-test-single" if="have.tests" name="-do-compile-test-single">
1366 <fail unless="javac.includes">Must select some files in the IDE or set javac.includes</fail>
1367 <webproject2:javac classpath="${javac.test.classpath}:${j2ee.platform.classpath}:${j2ee.platform.embeddableejb.classpath}" debug="true" destdir="${build.test.classes.dir}" excludes="" includes="${javac.includes}" srcdir="${test.src.dir}"/>
1368 <copy todir="${build.test.classes.dir}">
1369 <fileset dir="${test.src.dir}" excludes="${build.classes.excludes},${excludes}" includes="${includes}"/>
1372 <target name="-post-compile-test-single">
1373 <!-- Empty placeholder for easier customization. -->
1374 <!-- You can override this target in the ../build.xml file. -->
1376 <target depends="init,compile,-pre-pre-compile-test,-pre-compile-test-single,-do-compile-test-single,-post-compile-test-single" name="compile-test-single"/>
1379 TEST EXECUTION SECTION
1381 <target depends="init" if="have.tests" name="-pre-test-run">
1382 <mkdir dir="${build.test.results.dir}"/>
1384 <target depends="init,compile-test,-pre-test-run" if="have.tests" name="-do-test-run">
1385 <webproject2:test includes="${includes}" testincludes="**/*Test.java"/>
1387 <target depends="init,compile-test,-pre-test-run,-do-test-run" if="have.tests" name="-post-test-run">
1388 <fail if="tests.failed" unless="ignore.failing.tests">Some tests failed; see details above.</fail>
1390 <target depends="init" if="have.tests" name="test-report"/>
1391 <target depends="init" if="netbeans.home+have.tests" name="-test-browse"/>
1392 <target depends="init,compile-test,-pre-test-run,-do-test-run,test-report,-post-test-run,-test-browse" description="Run unit tests." name="test"/>
1393 <target depends="init" if="have.tests" name="-pre-test-run-single">
1394 <mkdir dir="${build.test.results.dir}"/>
1396 <target depends="init,compile-test-single,-pre-test-run-single" if="have.tests" name="-do-test-run-single">
1397 <fail unless="test.includes">Must select some files in the IDE or set test.includes</fail>
1398 <webproject2:test excludes="" includes="${test.includes}" testincludes="${test.includes}"/>
1400 <target depends="init,compile-test-single,-pre-test-run-single,-do-test-run-single" if="have.tests" name="-post-test-run-single">
1401 <fail if="tests.failed" unless="ignore.failing.tests">Some tests failed; see details above.</fail>
1403 <target depends="init,compile-test-single,-pre-test-run-single,-do-test-run-single,-post-test-run-single" description="Run single unit test." name="test-single"/>
1404 <target depends="init,compile-test-single,-pre-test-run-single" if="have.tests" name="-do-test-run-single-method">
1405 <fail unless="test.class">Must select some files in the IDE or set test.class</fail>
1406 <fail unless="test.method">Must select some method in the IDE or set test.method</fail>
1407 <webproject2:test excludes="" includes="${javac.includes}" testincludes="${test.class}" testmethods="${test.method}"/>
1409 <target depends="init,compile-test-single,-pre-test-run-single,-do-test-run-single-method" if="have.tests" name="-post-test-run-single-method">
1410 <fail if="tests.failed" unless="ignore.failing.tests">Some tests failed; see details above.</fail>
1412 <target depends="init,compile-test-single,-pre-test-run-single,-do-test-run-single-method,-post-test-run-single-method" description="Run single unit test." name="test-single-method"/>
1415 TEST DEBUGGING SECTION
1417 <target depends="init,compile-test-single,-pre-test-run-single" if="have.tests" name="-debug-start-debuggee-test">
1418 <fail unless="test.class">Must select one file in the IDE or set test.class</fail>
1419 <webproject2:test-debug excludes="" includes="${javac.includes}" testClass="${test.class}" testincludes="${javac.includes}"/>
1421 <target depends="init,compile-test-single,-pre-test-run-single" if="have.tests" name="-debug-start-debuggee-test-method">
1422 <fail unless="test.class">Must select one file in the IDE or set test.class</fail>
1423 <fail unless="test.method">Must select some method in the IDE or set test.method</fail>
1424 <webproject2:test-debug excludes="" includes="${javac.includes}" testClass="${test.class}" testMethod="${test.method}" testincludes="${test.class}" testmethods="${test.method}"/>
1426 <target depends="init,compile-test" if="netbeans.home+have.tests" name="-debug-start-debugger-test">
1427 <webproject1:nbjpdastart classpath="${debug.test.classpath}" name="${test.class}"/>
1429 <target depends="init,compile-test,-debug-start-debugger-test,-debug-start-debuggee-test" name="debug-test"/>
1430 <target depends="init,compile-test-single,-debug-start-debugger-test,-debug-start-debuggee-test-method" name="debug-test-method"/>
1431 <target depends="debug-test-method" name="debug-single-method"/>
1432 <target depends="init,-pre-debug-fix,compile-test-single" if="netbeans.home" name="-do-debug-fix-test">
1433 <webproject1:nbjpdareload dir="${build.test.classes.dir}"/>
1435 <target depends="init,-pre-debug-fix,-do-debug-fix-test" if="netbeans.home" name="debug-fix-test"/>
1440 <target depends="init" name="deps-clean" unless="no.deps">
1441 <ant antfile="${project.pizzaservice-core}/build.xml" inheritall="false" target="clean"/>
1442 <ant antfile="${project.pizzaservice-lib}/build.xml" inheritall="false" target="clean"/>
1444 <target depends="init" name="do-clean">
1445 <condition property="build.dir.to.clean" value="${build.web.dir}">
1446 <isset property="dist.ear.dir"/>
1448 <property name="build.dir.to.clean" value="${build.web.dir}"/>
1449 <delete includeEmptyDirs="true" quiet="true">
1450 <fileset dir="${build.dir.to.clean}/WEB-INF/lib"/>
1452 <delete dir="${build.dir}"/>
1453 <available file="${build.dir.to.clean}/WEB-INF/lib" property="status.clean-failed" type="dir"/>
1454 <delete dir="${dist.dir}"/>
1456 <target depends="do-clean" if="status.clean-failed" name="check-clean">
1457 <echo message="Warning: unable to delete some files in ${build.web.dir}/WEB-INF/lib - they are probably locked by the J2EE server. "/>
1458 <echo level="info" message="To delete all files undeploy the module from Server Registry in Runtime tab and then use Clean again."/>
1460 <target depends="init" if="netbeans.home" name="undeploy-clean">
1461 <nbundeploy failOnError="false" startServer="false"/>
1463 <target name="-post-clean">
1464 <!-- Empty placeholder for easier customization. -->
1465 <!-- You can override this target in the ../build.xml file. -->
1467 <target depends="init,undeploy-clean,deps-clean,do-clean,check-clean,-post-clean" description="Clean build products." name="clean"/>
1468 <target depends="clean" description="Clean build products." name="clean-ear"/>