1.1 --- /dev/null Thu Jan 01 00:00:00 1970 +0000
1.2 +++ b/samples/conditionaluseofapi/build.xml Sat Jun 14 09:50:50 2008 +0200
1.3 @@ -0,0 +1,27 @@
1.4 +<?xml version="1.0" encoding="UTF-8"?>
1.5 +<project name="conditionaluseofapi" default="default" basedir=".">
1.6 + <description>Builds, tests, and runs the project conditionaluseofapi.</description>
1.7 +
1.8 + <target name="test">
1.9 + <!-- simulates run on JDK 1.4 -->
1.10 + <antcall target="clean"/>
1.11 + <antcall target="run">
1.12 + <param name="excludes" value="**/*15.java"/>
1.13 + </antcall>
1.14 + </target>
1.15 +
1.16 + <target name="-pre-compile">
1.17 + <condition property="excludes" value="**/*15.java">
1.18 + <not>
1.19 + <available classname="java.lang.StringBuilder"/>
1.20 + </not>
1.21 + </condition>
1.22 + <property name="excludes" value=""/>
1.23 + </target>
1.24 +
1.25 +
1.26 + <import file="nbproject/build-impl.xml"/>
1.27 +
1.28 +
1.29 +
1.30 +</project>
2.1 --- /dev/null Thu Jan 01 00:00:00 1970 +0000
2.2 +++ b/samples/conditionaluseofapi/nbproject/build-impl.xml Sat Jun 14 09:50:50 2008 +0200
2.3 @@ -0,0 +1,627 @@
2.4 +<?xml version="1.0" encoding="UTF-8"?>
2.5 +<!--
2.6 +*** GENERATED FROM project.xml - DO NOT EDIT ***
2.7 +*** EDIT ../build.xml INSTEAD ***
2.8 +
2.9 +For the purpose of easier reading the script
2.10 +is divided into following sections:
2.11 +
2.12 + - initialization
2.13 + - compilation
2.14 + - jar
2.15 + - execution
2.16 + - debugging
2.17 + - javadoc
2.18 + - junit compilation
2.19 + - junit execution
2.20 + - junit debugging
2.21 + - applet
2.22 + - cleanup
2.23 +
2.24 + -->
2.25 +<project xmlns:j2seproject1="http://www.netbeans.org/ns/j2se-project/1" xmlns:j2seproject2="http://www.netbeans.org/ns/j2se-project/2" xmlns:j2seproject3="http://www.netbeans.org/ns/j2se-project/3" xmlns:jaxrpc="http://www.netbeans.org/ns/j2se-project/jax-rpc" basedir=".." default="default" name="conditionaluseofapi-impl">
2.26 + <target depends="test,jar,javadoc" description="Build and test whole project." name="default"/>
2.27 + <!--
2.28 + ======================
2.29 + INITIALIZATION SECTION
2.30 + ======================
2.31 + -->
2.32 + <target name="-pre-init">
2.33 + <!-- Empty placeholder for easier customization. -->
2.34 + <!-- You can override this target in the ../build.xml file. -->
2.35 + </target>
2.36 + <target depends="-pre-init" name="-init-private">
2.37 + <property file="nbproject/private/config.properties"/>
2.38 + <property file="nbproject/private/configs/${config}.properties"/>
2.39 + <property file="nbproject/private/private.properties"/>
2.40 + </target>
2.41 + <target depends="-pre-init,-init-private" name="-init-user">
2.42 + <property file="${user.properties.file}"/>
2.43 + <!-- The two properties below are usually overridden -->
2.44 + <!-- by the active platform. Just a fallback. -->
2.45 + <property name="default.javac.source" value="1.4"/>
2.46 + <property name="default.javac.target" value="1.4"/>
2.47 + </target>
2.48 + <target depends="-pre-init,-init-private,-init-user" name="-init-project">
2.49 + <property file="nbproject/configs/${config}.properties"/>
2.50 + <property file="nbproject/project.properties"/>
2.51 + </target>
2.52 + <target depends="-pre-init,-init-private,-init-user,-init-project,-init-macrodef-property" name="-do-init">
2.53 + <available file="${manifest.file}" property="manifest.available"/>
2.54 + <condition property="manifest.available+main.class">
2.55 + <and>
2.56 + <isset property="manifest.available"/>
2.57 + <isset property="main.class"/>
2.58 + <not>
2.59 + <equals arg1="${main.class}" arg2="" trim="true"/>
2.60 + </not>
2.61 + </and>
2.62 + </condition>
2.63 + <condition property="manifest.available+main.class+mkdist.available">
2.64 + <and>
2.65 + <istrue value="${manifest.available+main.class}"/>
2.66 + <isset property="libs.CopyLibs.classpath"/>
2.67 + </and>
2.68 + </condition>
2.69 + <condition property="have.tests">
2.70 + <or>
2.71 + <available file="${test.src.dir}"/>
2.72 + </or>
2.73 + </condition>
2.74 + <condition property="have.sources">
2.75 + <or>
2.76 + <available file="${src.dir}"/>
2.77 + </or>
2.78 + </condition>
2.79 + <condition property="netbeans.home+have.tests">
2.80 + <and>
2.81 + <isset property="netbeans.home"/>
2.82 + <isset property="have.tests"/>
2.83 + </and>
2.84 + </condition>
2.85 + <condition property="no.javadoc.preview">
2.86 + <and>
2.87 + <isset property="javadoc.preview"/>
2.88 + <isfalse value="${javadoc.preview}"/>
2.89 + </and>
2.90 + </condition>
2.91 + <property name="run.jvmargs" value=""/>
2.92 + <property name="javac.compilerargs" value=""/>
2.93 + <property name="work.dir" value="${basedir}"/>
2.94 + <condition property="no.deps">
2.95 + <and>
2.96 + <istrue value="${no.dependencies}"/>
2.97 + </and>
2.98 + </condition>
2.99 + <property name="javac.debug" value="true"/>
2.100 + <property name="javadoc.preview" value="true"/>
2.101 + <property name="application.args" value=""/>
2.102 + <property name="source.encoding" value="${file.encoding}"/>
2.103 + <condition property="javadoc.encoding.used" value="${javadoc.encoding}">
2.104 + <and>
2.105 + <isset property="javadoc.encoding"/>
2.106 + <not>
2.107 + <equals arg1="${javadoc.encoding}" arg2=""/>
2.108 + </not>
2.109 + </and>
2.110 + </condition>
2.111 + <property name="javadoc.encoding.used" value="${source.encoding}"/>
2.112 + <property name="includes" value="**"/>
2.113 + <property name="excludes" value=""/>
2.114 + <property name="do.depend" value="false"/>
2.115 + <condition property="do.depend.true">
2.116 + <istrue value="${do.depend}"/>
2.117 + </condition>
2.118 + <condition else="" property="javac.compilerargs.jaxws" value="-Djava.endorsed.dirs='${jaxws.endorsed.dir}'">
2.119 + <and>
2.120 + <isset property="jaxws.endorsed.dir"/>
2.121 + <available file="nbproject/jaxws-build.xml"/>
2.122 + </and>
2.123 + </condition>
2.124 + </target>
2.125 + <target name="-post-init">
2.126 + <!-- Empty placeholder for easier customization. -->
2.127 + <!-- You can override this target in the ../build.xml file. -->
2.128 + </target>
2.129 + <target depends="-pre-init,-init-private,-init-user,-init-project,-do-init" name="-init-check">
2.130 + <fail unless="src.dir">Must set src.dir</fail>
2.131 + <fail unless="test.src.dir">Must set test.src.dir</fail>
2.132 + <fail unless="build.dir">Must set build.dir</fail>
2.133 + <fail unless="dist.dir">Must set dist.dir</fail>
2.134 + <fail unless="build.classes.dir">Must set build.classes.dir</fail>
2.135 + <fail unless="dist.javadoc.dir">Must set dist.javadoc.dir</fail>
2.136 + <fail unless="build.test.classes.dir">Must set build.test.classes.dir</fail>
2.137 + <fail unless="build.test.results.dir">Must set build.test.results.dir</fail>
2.138 + <fail unless="build.classes.excludes">Must set build.classes.excludes</fail>
2.139 + <fail unless="dist.jar">Must set dist.jar</fail>
2.140 + </target>
2.141 + <target name="-init-macrodef-property">
2.142 + <macrodef name="property" uri="http://www.netbeans.org/ns/j2se-project/1">
2.143 + <attribute name="name"/>
2.144 + <attribute name="value"/>
2.145 + <sequential>
2.146 + <property name="@{name}" value="${@{value}}"/>
2.147 + </sequential>
2.148 + </macrodef>
2.149 + </target>
2.150 + <target name="-init-macrodef-javac">
2.151 + <macrodef name="javac" uri="http://www.netbeans.org/ns/j2se-project/3">
2.152 + <attribute default="${src.dir}" name="srcdir"/>
2.153 + <attribute default="${build.classes.dir}" name="destdir"/>
2.154 + <attribute default="${javac.classpath}" name="classpath"/>
2.155 + <attribute default="${includes}" name="includes"/>
2.156 + <attribute default="${excludes}" name="excludes"/>
2.157 + <attribute default="${javac.debug}" name="debug"/>
2.158 + <attribute default="" name="sourcepath"/>
2.159 + <element name="customize" optional="true"/>
2.160 + <sequential>
2.161 + <javac debug="@{debug}" deprecation="${javac.deprecation}" destdir="@{destdir}" encoding="${source.encoding}" excludes="@{excludes}" includeantruntime="false" includes="@{includes}" source="${javac.source}" sourcepath="@{sourcepath}" srcdir="@{srcdir}" target="${javac.target}">
2.162 + <classpath>
2.163 + <path path="@{classpath}"/>
2.164 + </classpath>
2.165 + <compilerarg line="${javac.compilerargs} ${javac.compilerargs.jaxws}"/>
2.166 + <customize/>
2.167 + </javac>
2.168 + </sequential>
2.169 + </macrodef>
2.170 + <macrodef name="depend" uri="http://www.netbeans.org/ns/j2se-project/3">
2.171 + <attribute default="${src.dir}" name="srcdir"/>
2.172 + <attribute default="${build.classes.dir}" name="destdir"/>
2.173 + <attribute default="${javac.classpath}" name="classpath"/>
2.174 + <sequential>
2.175 + <depend cache="${build.dir}/depcache" destdir="@{destdir}" excludes="${excludes}" includes="${includes}" srcdir="@{srcdir}">
2.176 + <classpath>
2.177 + <path path="@{classpath}"/>
2.178 + </classpath>
2.179 + </depend>
2.180 + </sequential>
2.181 + </macrodef>
2.182 + <macrodef name="force-recompile" uri="http://www.netbeans.org/ns/j2se-project/3">
2.183 + <attribute default="${build.classes.dir}" name="destdir"/>
2.184 + <sequential>
2.185 + <fail unless="javac.includes">Must set javac.includes</fail>
2.186 + <pathconvert pathsep="," property="javac.includes.binary">
2.187 + <path>
2.188 + <filelist dir="@{destdir}" files="${javac.includes}"/>
2.189 + </path>
2.190 + <globmapper from="*.java" to="*.class"/>
2.191 + </pathconvert>
2.192 + <delete>
2.193 + <files includes="${javac.includes.binary}"/>
2.194 + </delete>
2.195 + </sequential>
2.196 + </macrodef>
2.197 + </target>
2.198 + <target name="-init-macrodef-junit">
2.199 + <macrodef name="junit" uri="http://www.netbeans.org/ns/j2se-project/3">
2.200 + <attribute default="${includes}" name="includes"/>
2.201 + <attribute default="${excludes}" name="excludes"/>
2.202 + <attribute default="**" name="testincludes"/>
2.203 + <sequential>
2.204 + <junit dir="${work.dir}" errorproperty="tests.failed" failureproperty="tests.failed" fork="true" showoutput="true">
2.205 + <batchtest todir="${build.test.results.dir}">
2.206 + <fileset dir="${test.src.dir}" excludes="@{excludes},${excludes}" includes="@{includes}">
2.207 + <filename name="@{testincludes}"/>
2.208 + </fileset>
2.209 + </batchtest>
2.210 + <classpath>
2.211 + <path path="${run.test.classpath}"/>
2.212 + </classpath>
2.213 + <syspropertyset>
2.214 + <propertyref prefix="test-sys-prop."/>
2.215 + <mapper from="test-sys-prop.*" to="*" type="glob"/>
2.216 + </syspropertyset>
2.217 + <formatter type="brief" usefile="false"/>
2.218 + <formatter type="xml"/>
2.219 + <jvmarg line="${run.jvmargs}"/>
2.220 + </junit>
2.221 + </sequential>
2.222 + </macrodef>
2.223 + </target>
2.224 + <target name="-init-macrodef-nbjpda">
2.225 + <macrodef name="nbjpdastart" uri="http://www.netbeans.org/ns/j2se-project/1">
2.226 + <attribute default="${main.class}" name="name"/>
2.227 + <attribute default="${debug.classpath}" name="classpath"/>
2.228 + <attribute default="" name="stopclassname"/>
2.229 + <sequential>
2.230 + <nbjpdastart addressproperty="jpda.address" name="@{name}" stopclassname="@{stopclassname}" transport="dt_socket">
2.231 + <classpath>
2.232 + <path path="@{classpath}"/>
2.233 + </classpath>
2.234 + </nbjpdastart>
2.235 + </sequential>
2.236 + </macrodef>
2.237 + <macrodef name="nbjpdareload" uri="http://www.netbeans.org/ns/j2se-project/1">
2.238 + <attribute default="${build.classes.dir}" name="dir"/>
2.239 + <sequential>
2.240 + <nbjpdareload>
2.241 + <fileset dir="@{dir}" includes="${fix.includes}*.class"/>
2.242 + </nbjpdareload>
2.243 + </sequential>
2.244 + </macrodef>
2.245 + </target>
2.246 + <target name="-init-debug-args">
2.247 + <property name="version-output" value="java version "${ant.java.version}"/>
2.248 + <condition property="have-jdk-older-than-1.4">
2.249 + <or>
2.250 + <contains string="${version-output}" substring="java version "1.0"/>
2.251 + <contains string="${version-output}" substring="java version "1.1"/>
2.252 + <contains string="${version-output}" substring="java version "1.2"/>
2.253 + <contains string="${version-output}" substring="java version "1.3"/>
2.254 + </or>
2.255 + </condition>
2.256 + <condition else="-Xdebug" property="debug-args-line" value="-Xdebug -Xnoagent -Djava.compiler=none">
2.257 + <istrue value="${have-jdk-older-than-1.4}"/>
2.258 + </condition>
2.259 + </target>
2.260 + <target depends="-init-debug-args" name="-init-macrodef-debug">
2.261 + <macrodef name="debug" uri="http://www.netbeans.org/ns/j2se-project/3">
2.262 + <attribute default="${main.class}" name="classname"/>
2.263 + <attribute default="${debug.classpath}" name="classpath"/>
2.264 + <element name="customize" optional="true"/>
2.265 + <sequential>
2.266 + <java classname="@{classname}" dir="${work.dir}" fork="true">
2.267 + <jvmarg line="${debug-args-line}"/>
2.268 + <jvmarg value="-Xrunjdwp:transport=dt_socket,address=${jpda.address}"/>
2.269 + <jvmarg line="${run.jvmargs}"/>
2.270 + <classpath>
2.271 + <path path="@{classpath}"/>
2.272 + </classpath>
2.273 + <syspropertyset>
2.274 + <propertyref prefix="run-sys-prop."/>
2.275 + <mapper from="run-sys-prop.*" to="*" type="glob"/>
2.276 + </syspropertyset>
2.277 + <customize/>
2.278 + </java>
2.279 + </sequential>
2.280 + </macrodef>
2.281 + </target>
2.282 + <target name="-init-macrodef-java">
2.283 + <macrodef name="java" uri="http://www.netbeans.org/ns/j2se-project/1">
2.284 + <attribute default="${main.class}" name="classname"/>
2.285 + <element name="customize" optional="true"/>
2.286 + <sequential>
2.287 + <java classname="@{classname}" dir="${work.dir}" fork="true">
2.288 + <jvmarg line="${run.jvmargs}"/>
2.289 + <classpath>
2.290 + <path path="${run.classpath}"/>
2.291 + </classpath>
2.292 + <syspropertyset>
2.293 + <propertyref prefix="run-sys-prop."/>
2.294 + <mapper from="run-sys-prop.*" to="*" type="glob"/>
2.295 + </syspropertyset>
2.296 + <customize/>
2.297 + </java>
2.298 + </sequential>
2.299 + </macrodef>
2.300 + </target>
2.301 + <target name="-init-presetdef-jar">
2.302 + <presetdef name="jar" uri="http://www.netbeans.org/ns/j2se-project/1">
2.303 + <jar compress="${jar.compress}" jarfile="${dist.jar}">
2.304 + <j2seproject1:fileset dir="${build.classes.dir}"/>
2.305 + </jar>
2.306 + </presetdef>
2.307 + </target>
2.308 + <target depends="-pre-init,-init-private,-init-user,-init-project,-do-init,-post-init,-init-check,-init-macrodef-property,-init-macrodef-javac,-init-macrodef-junit,-init-macrodef-nbjpda,-init-macrodef-debug,-init-macrodef-java,-init-presetdef-jar" name="init"/>
2.309 + <!--
2.310 + ===================
2.311 + COMPILATION SECTION
2.312 + ===================
2.313 + -->
2.314 + <target depends="init" name="deps-jar" unless="no.deps"/>
2.315 + <target depends="init,deps-jar" name="-pre-pre-compile">
2.316 + <mkdir dir="${build.classes.dir}"/>
2.317 + </target>
2.318 + <target name="-pre-compile">
2.319 + <!-- Empty placeholder for easier customization. -->
2.320 + <!-- You can override this target in the ../build.xml file. -->
2.321 + </target>
2.322 + <target if="do.depend.true" name="-compile-depend">
2.323 + <j2seproject3:depend/>
2.324 + </target>
2.325 + <target depends="init,deps-jar,-pre-pre-compile,-pre-compile,-compile-depend" if="have.sources" name="-do-compile">
2.326 + <j2seproject3:javac/>
2.327 + <copy todir="${build.classes.dir}">
2.328 + <fileset dir="${src.dir}" excludes="${build.classes.excludes},${excludes}" includes="${includes}"/>
2.329 + </copy>
2.330 + </target>
2.331 + <target name="-post-compile">
2.332 + <!-- Empty placeholder for easier customization. -->
2.333 + <!-- You can override this target in the ../build.xml file. -->
2.334 + </target>
2.335 + <target depends="init,deps-jar,-pre-pre-compile,-pre-compile,-do-compile,-post-compile" description="Compile project." name="compile"/>
2.336 + <target name="-pre-compile-single">
2.337 + <!-- Empty placeholder for easier customization. -->
2.338 + <!-- You can override this target in the ../build.xml file. -->
2.339 + </target>
2.340 + <target depends="init,deps-jar,-pre-pre-compile" name="-do-compile-single">
2.341 + <fail unless="javac.includes">Must select some files in the IDE or set javac.includes</fail>
2.342 + <j2seproject3:force-recompile/>
2.343 + <j2seproject3:javac excludes="" includes="${javac.includes}" sourcepath="${src.dir}"/>
2.344 + </target>
2.345 + <target name="-post-compile-single">
2.346 + <!-- Empty placeholder for easier customization. -->
2.347 + <!-- You can override this target in the ../build.xml file. -->
2.348 + </target>
2.349 + <target depends="init,deps-jar,-pre-pre-compile,-pre-compile-single,-do-compile-single,-post-compile-single" name="compile-single"/>
2.350 + <!--
2.351 + ====================
2.352 + JAR BUILDING SECTION
2.353 + ====================
2.354 + -->
2.355 + <target depends="init" name="-pre-pre-jar">
2.356 + <dirname file="${dist.jar}" property="dist.jar.dir"/>
2.357 + <mkdir dir="${dist.jar.dir}"/>
2.358 + </target>
2.359 + <target name="-pre-jar">
2.360 + <!-- Empty placeholder for easier customization. -->
2.361 + <!-- You can override this target in the ../build.xml file. -->
2.362 + </target>
2.363 + <target depends="init,compile,-pre-pre-jar,-pre-jar" name="-do-jar-without-manifest" unless="manifest.available">
2.364 + <j2seproject1:jar/>
2.365 + </target>
2.366 + <target depends="init,compile,-pre-pre-jar,-pre-jar" if="manifest.available" name="-do-jar-with-manifest" unless="manifest.available+main.class">
2.367 + <j2seproject1:jar manifest="${manifest.file}"/>
2.368 + </target>
2.369 + <target depends="init,compile,-pre-pre-jar,-pre-jar" if="manifest.available+main.class" name="-do-jar-with-mainclass" unless="manifest.available+main.class+mkdist.available">
2.370 + <j2seproject1:jar manifest="${manifest.file}">
2.371 + <j2seproject1:manifest>
2.372 + <j2seproject1:attribute name="Main-Class" value="${main.class}"/>
2.373 + </j2seproject1:manifest>
2.374 + </j2seproject1:jar>
2.375 + <echo>To run this application from the command line without Ant, try:</echo>
2.376 + <property location="${build.classes.dir}" name="build.classes.dir.resolved"/>
2.377 + <property location="${dist.jar}" name="dist.jar.resolved"/>
2.378 + <pathconvert property="run.classpath.with.dist.jar">
2.379 + <path path="${run.classpath}"/>
2.380 + <map from="${build.classes.dir.resolved}" to="${dist.jar.resolved}"/>
2.381 + </pathconvert>
2.382 + <echo>java -cp "${run.classpath.with.dist.jar}" ${main.class}</echo>
2.383 + </target>
2.384 + <target depends="init,compile,-pre-pre-jar,-pre-jar" if="manifest.available+main.class+mkdist.available" name="-do-jar-with-libraries">
2.385 + <property location="${build.classes.dir}" name="build.classes.dir.resolved"/>
2.386 + <pathconvert property="run.classpath.without.build.classes.dir">
2.387 + <path path="${run.classpath}"/>
2.388 + <map from="${build.classes.dir.resolved}" to=""/>
2.389 + </pathconvert>
2.390 + <pathconvert pathsep=" " property="jar.classpath">
2.391 + <path path="${run.classpath.without.build.classes.dir}"/>
2.392 + <chainedmapper>
2.393 + <flattenmapper/>
2.394 + <globmapper from="*" to="lib/*"/>
2.395 + </chainedmapper>
2.396 + </pathconvert>
2.397 + <taskdef classname="org.netbeans.modules.java.j2seproject.copylibstask.CopyLibs" classpath="${libs.CopyLibs.classpath}" name="copylibs"/>
2.398 + <copylibs compress="${jar.compress}" jarfile="${dist.jar}" manifest="${manifest.file}" runtimeclasspath="${run.classpath.without.build.classes.dir}">
2.399 + <fileset dir="${build.classes.dir}"/>
2.400 + <manifest>
2.401 + <attribute name="Main-Class" value="${main.class}"/>
2.402 + <attribute name="Class-Path" value="${jar.classpath}"/>
2.403 + </manifest>
2.404 + </copylibs>
2.405 + <echo>To run this application from the command line without Ant, try:</echo>
2.406 + <property location="${dist.jar}" name="dist.jar.resolved"/>
2.407 + <echo>java -jar "${dist.jar.resolved}"</echo>
2.408 + </target>
2.409 + <target name="-post-jar">
2.410 + <!-- Empty placeholder for easier customization. -->
2.411 + <!-- You can override this target in the ../build.xml file. -->
2.412 + </target>
2.413 + <target depends="init,compile,-pre-jar,-do-jar-with-manifest,-do-jar-without-manifest,-do-jar-with-mainclass,-do-jar-with-libraries,-post-jar" description="Build JAR." name="jar"/>
2.414 + <!--
2.415 + =================
2.416 + EXECUTION SECTION
2.417 + =================
2.418 + -->
2.419 + <target depends="init,compile" description="Run a main class." name="run">
2.420 + <j2seproject1:java>
2.421 + <customize>
2.422 + <arg line="${application.args}"/>
2.423 + </customize>
2.424 + </j2seproject1:java>
2.425 + </target>
2.426 + <target name="-do-not-recompile">
2.427 + <property name="javac.includes.binary" value=""/>
2.428 + </target>
2.429 + <target depends="init,-do-not-recompile,compile-single" name="run-single">
2.430 + <fail unless="run.class">Must select one file in the IDE or set run.class</fail>
2.431 + <j2seproject1:java classname="${run.class}"/>
2.432 + </target>
2.433 + <!--
2.434 + =================
2.435 + DEBUGGING SECTION
2.436 + =================
2.437 + -->
2.438 + <target depends="init" if="netbeans.home" name="-debug-start-debugger">
2.439 + <j2seproject1:nbjpdastart name="${debug.class}"/>
2.440 + </target>
2.441 + <target depends="init,compile" name="-debug-start-debuggee">
2.442 + <j2seproject3:debug>
2.443 + <customize>
2.444 + <arg line="${application.args}"/>
2.445 + </customize>
2.446 + </j2seproject3:debug>
2.447 + </target>
2.448 + <target depends="init,compile,-debug-start-debugger,-debug-start-debuggee" description="Debug project in IDE." if="netbeans.home" name="debug"/>
2.449 + <target depends="init" if="netbeans.home" name="-debug-start-debugger-stepinto">
2.450 + <j2seproject1:nbjpdastart stopclassname="${main.class}"/>
2.451 + </target>
2.452 + <target depends="init,compile,-debug-start-debugger-stepinto,-debug-start-debuggee" if="netbeans.home" name="debug-stepinto"/>
2.453 + <target depends="init,compile-single" if="netbeans.home" name="-debug-start-debuggee-single">
2.454 + <fail unless="debug.class">Must select one file in the IDE or set debug.class</fail>
2.455 + <j2seproject3:debug classname="${debug.class}"/>
2.456 + </target>
2.457 + <target depends="init,-do-not-recompile,compile-single,-debug-start-debugger,-debug-start-debuggee-single" if="netbeans.home" name="debug-single"/>
2.458 + <target depends="init" name="-pre-debug-fix">
2.459 + <fail unless="fix.includes">Must set fix.includes</fail>
2.460 + <property name="javac.includes" value="${fix.includes}.java"/>
2.461 + </target>
2.462 + <target depends="init,-pre-debug-fix,compile-single" if="netbeans.home" name="-do-debug-fix">
2.463 + <j2seproject1:nbjpdareload/>
2.464 + </target>
2.465 + <target depends="init,-pre-debug-fix,-do-debug-fix" if="netbeans.home" name="debug-fix"/>
2.466 + <!--
2.467 + ===============
2.468 + JAVADOC SECTION
2.469 + ===============
2.470 + -->
2.471 + <target depends="init" name="-javadoc-build">
2.472 + <mkdir dir="${dist.javadoc.dir}"/>
2.473 + <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}">
2.474 + <classpath>
2.475 + <path path="${javac.classpath}"/>
2.476 + </classpath>
2.477 + <fileset dir="${src.dir}" excludes="${excludes}" includes="${includes}">
2.478 + <filename name="**/*.java"/>
2.479 + </fileset>
2.480 + </javadoc>
2.481 + </target>
2.482 + <target depends="init,-javadoc-build" if="netbeans.home" name="-javadoc-browse" unless="no.javadoc.preview">
2.483 + <nbbrowse file="${dist.javadoc.dir}/index.html"/>
2.484 + </target>
2.485 + <target depends="init,-javadoc-build,-javadoc-browse" description="Build Javadoc." name="javadoc"/>
2.486 + <!--
2.487 + =========================
2.488 + JUNIT COMPILATION SECTION
2.489 + =========================
2.490 + -->
2.491 + <target depends="init,compile" if="have.tests" name="-pre-pre-compile-test">
2.492 + <mkdir dir="${build.test.classes.dir}"/>
2.493 + </target>
2.494 + <target name="-pre-compile-test">
2.495 + <!-- Empty placeholder for easier customization. -->
2.496 + <!-- You can override this target in the ../build.xml file. -->
2.497 + </target>
2.498 + <target if="do.depend.true" name="-compile-test-depend">
2.499 + <j2seproject3:depend classpath="${javac.test.classpath}" destdir="${build.test.classes.dir}" srcdir="${test.src.dir}"/>
2.500 + </target>
2.501 + <target depends="init,compile,-pre-pre-compile-test,-pre-compile-test,-compile-test-depend" if="have.tests" name="-do-compile-test">
2.502 + <j2seproject3:javac classpath="${javac.test.classpath}" debug="true" destdir="${build.test.classes.dir}" srcdir="${test.src.dir}"/>
2.503 + <copy todir="${build.test.classes.dir}">
2.504 + <fileset dir="${test.src.dir}" excludes="${build.classes.excludes},${excludes}" includes="${includes}"/>
2.505 + </copy>
2.506 + </target>
2.507 + <target name="-post-compile-test">
2.508 + <!-- Empty placeholder for easier customization. -->
2.509 + <!-- You can override this target in the ../build.xml file. -->
2.510 + </target>
2.511 + <target depends="init,compile,-pre-pre-compile-test,-pre-compile-test,-do-compile-test,-post-compile-test" name="compile-test"/>
2.512 + <target name="-pre-compile-test-single">
2.513 + <!-- Empty placeholder for easier customization. -->
2.514 + <!-- You can override this target in the ../build.xml file. -->
2.515 + </target>
2.516 + <target depends="init,compile,-pre-pre-compile-test,-pre-compile-test-single" if="have.tests" name="-do-compile-test-single">
2.517 + <fail unless="javac.includes">Must select some files in the IDE or set javac.includes</fail>
2.518 + <j2seproject3:force-recompile destdir="${build.test.classes.dir}"/>
2.519 + <j2seproject3:javac classpath="${javac.test.classpath}" debug="true" destdir="${build.test.classes.dir}" excludes="" includes="${javac.includes}" sourcepath="${test.src.dir}" srcdir="${test.src.dir}"/>
2.520 + <copy todir="${build.test.classes.dir}">
2.521 + <fileset dir="${test.src.dir}" excludes="${build.classes.excludes},${excludes}" includes="${includes}"/>
2.522 + </copy>
2.523 + </target>
2.524 + <target name="-post-compile-test-single">
2.525 + <!-- Empty placeholder for easier customization. -->
2.526 + <!-- You can override this target in the ../build.xml file. -->
2.527 + </target>
2.528 + <target depends="init,compile,-pre-pre-compile-test,-pre-compile-test-single,-do-compile-test-single,-post-compile-test-single" name="compile-test-single"/>
2.529 + <!--
2.530 + =======================
2.531 + JUNIT EXECUTION SECTION
2.532 + =======================
2.533 + -->
2.534 + <target depends="init" if="have.tests" name="-pre-test-run">
2.535 + <mkdir dir="${build.test.results.dir}"/>
2.536 + </target>
2.537 + <target depends="init,compile-test,-pre-test-run" if="have.tests" name="-do-test-run">
2.538 + <j2seproject3:junit testincludes="**/*Test.java"/>
2.539 + </target>
2.540 + <target depends="init,compile-test,-pre-test-run,-do-test-run" if="have.tests" name="-post-test-run">
2.541 + <fail if="tests.failed">Some tests failed; see details above.</fail>
2.542 + </target>
2.543 + <target depends="init" if="have.tests" name="test-report"/>
2.544 + <target depends="init" if="netbeans.home+have.tests" name="-test-browse"/>
2.545 + <target depends="init,compile-test,-pre-test-run,-do-test-run,test-report,-post-test-run,-test-browse" description="Run unit tests." name="test"/>
2.546 + <target depends="init" if="have.tests" name="-pre-test-run-single">
2.547 + <mkdir dir="${build.test.results.dir}"/>
2.548 + </target>
2.549 + <target depends="init,compile-test-single,-pre-test-run-single" if="have.tests" name="-do-test-run-single">
2.550 + <fail unless="test.includes">Must select some files in the IDE or set test.includes</fail>
2.551 + <j2seproject3:junit excludes="" includes="${test.includes}"/>
2.552 + </target>
2.553 + <target depends="init,compile-test-single,-pre-test-run-single,-do-test-run-single" if="have.tests" name="-post-test-run-single">
2.554 + <fail if="tests.failed">Some tests failed; see details above.</fail>
2.555 + </target>
2.556 + <target depends="init,-do-not-recompile,compile-test-single,-pre-test-run-single,-do-test-run-single,-post-test-run-single" description="Run single unit test." name="test-single"/>
2.557 + <!--
2.558 + =======================
2.559 + JUNIT DEBUGGING SECTION
2.560 + =======================
2.561 + -->
2.562 + <target depends="init,compile-test" if="have.tests" name="-debug-start-debuggee-test">
2.563 + <fail unless="test.class">Must select one file in the IDE or set test.class</fail>
2.564 + <property location="${build.test.results.dir}/TEST-${test.class}.xml" name="test.report.file"/>
2.565 + <delete file="${test.report.file}"/>
2.566 + <mkdir dir="${build.test.results.dir}"/>
2.567 + <j2seproject3:debug classname="org.apache.tools.ant.taskdefs.optional.junit.JUnitTestRunner" classpath="${ant.home}/lib/ant.jar:${ant.home}/lib/ant-junit.jar:${debug.test.classpath}">
2.568 + <customize>
2.569 + <syspropertyset>
2.570 + <propertyref prefix="test-sys-prop."/>
2.571 + <mapper from="test-sys-prop.*" to="*" type="glob"/>
2.572 + </syspropertyset>
2.573 + <arg value="${test.class}"/>
2.574 + <arg value="showoutput=true"/>
2.575 + <arg value="formatter=org.apache.tools.ant.taskdefs.optional.junit.BriefJUnitResultFormatter"/>
2.576 + <arg value="formatter=org.apache.tools.ant.taskdefs.optional.junit.XMLJUnitResultFormatter,${test.report.file}"/>
2.577 + </customize>
2.578 + </j2seproject3:debug>
2.579 + </target>
2.580 + <target depends="init,compile-test" if="netbeans.home+have.tests" name="-debug-start-debugger-test">
2.581 + <j2seproject1:nbjpdastart classpath="${debug.test.classpath}" name="${test.class}"/>
2.582 + </target>
2.583 + <target depends="init,-do-not-recompile,compile-test-single,-debug-start-debugger-test,-debug-start-debuggee-test" name="debug-test"/>
2.584 + <target depends="init,-pre-debug-fix,compile-test-single" if="netbeans.home" name="-do-debug-fix-test">
2.585 + <j2seproject1:nbjpdareload dir="${build.test.classes.dir}"/>
2.586 + </target>
2.587 + <target depends="init,-pre-debug-fix,-do-debug-fix-test" if="netbeans.home" name="debug-fix-test"/>
2.588 + <!--
2.589 + =========================
2.590 + APPLET EXECUTION SECTION
2.591 + =========================
2.592 + -->
2.593 + <target depends="init,compile-single" name="run-applet">
2.594 + <fail unless="applet.url">Must select one file in the IDE or set applet.url</fail>
2.595 + <j2seproject1:java classname="sun.applet.AppletViewer">
2.596 + <customize>
2.597 + <arg value="${applet.url}"/>
2.598 + </customize>
2.599 + </j2seproject1:java>
2.600 + </target>
2.601 + <!--
2.602 + =========================
2.603 + APPLET DEBUGGING SECTION
2.604 + =========================
2.605 + -->
2.606 + <target depends="init,compile-single" if="netbeans.home" name="-debug-start-debuggee-applet">
2.607 + <fail unless="applet.url">Must select one file in the IDE or set applet.url</fail>
2.608 + <j2seproject3:debug classname="sun.applet.AppletViewer">
2.609 + <customize>
2.610 + <arg value="${applet.url}"/>
2.611 + </customize>
2.612 + </j2seproject3:debug>
2.613 + </target>
2.614 + <target depends="init,compile-single,-debug-start-debugger,-debug-start-debuggee-applet" if="netbeans.home" name="debug-applet"/>
2.615 + <!--
2.616 + ===============
2.617 + CLEANUP SECTION
2.618 + ===============
2.619 + -->
2.620 + <target depends="init" name="deps-clean" unless="no.deps"/>
2.621 + <target depends="init" name="-do-clean">
2.622 + <delete dir="${build.dir}"/>
2.623 + <delete dir="${dist.dir}"/>
2.624 + </target>
2.625 + <target name="-post-clean">
2.626 + <!-- Empty placeholder for easier customization. -->
2.627 + <!-- You can override this target in the ../build.xml file. -->
2.628 + </target>
2.629 + <target depends="init,deps-clean,-do-clean,-post-clean" description="Clean build products." name="clean"/>
2.630 +</project>
3.1 --- /dev/null Thu Jan 01 00:00:00 1970 +0000
3.2 +++ b/samples/conditionaluseofapi/nbproject/genfiles.properties Sat Jun 14 09:50:50 2008 +0200
3.3 @@ -0,0 +1,8 @@
3.4 +build.xml.data.CRC32=32385e3b
3.5 +build.xml.script.CRC32=91329421
3.6 +build.xml.stylesheet.CRC32=be360661
3.7 +# This file is used by a NetBeans-based IDE to track changes in generated files such as build-impl.xml.
3.8 +# Do not edit this file. You may delete it but then the IDE will never regenerate such files for you.
3.9 +nbproject/build-impl.xml.data.CRC32=32385e3b
3.10 +nbproject/build-impl.xml.script.CRC32=7a10d71d
3.11 +nbproject/build-impl.xml.stylesheet.CRC32=f1d9da08
4.1 --- /dev/null Thu Jan 01 00:00:00 1970 +0000
4.2 +++ b/samples/conditionaluseofapi/nbproject/project.properties Sat Jun 14 09:50:50 2008 +0200
4.3 @@ -0,0 +1,59 @@
4.4 +application.title=conditionaluseofapi
4.5 +application.vendor=jarda
4.6 +build.classes.dir=${build.dir}/classes
4.7 +build.classes.excludes=**/*.java,**/*.form
4.8 +# This directory is removed when the project is cleaned:
4.9 +build.dir=build
4.10 +build.generated.dir=${build.dir}/generated
4.11 +# Only compile against the classpath explicitly listed here:
4.12 +build.sysclasspath=ignore
4.13 +build.test.classes.dir=${build.dir}/test/classes
4.14 +build.test.results.dir=${build.dir}/test/results
4.15 +debug.classpath=\
4.16 + ${run.classpath}
4.17 +debug.test.classpath=\
4.18 + ${run.test.classpath}
4.19 +# This directory is removed when the project is cleaned:
4.20 +dist.dir=dist
4.21 +dist.jar=${dist.dir}/conditionaluseofapi.jar
4.22 +dist.javadoc.dir=${dist.dir}/javadoc
4.23 +includes=**
4.24 +jar.compress=false
4.25 +javac.classpath=
4.26 +# Space-separated list of extra javac options
4.27 +javac.compilerargs=
4.28 +javac.deprecation=false
4.29 +javac.source=1.4
4.30 +javac.target=1.4
4.31 +javac.test.classpath=\
4.32 + ${javac.classpath}:\
4.33 + ${build.classes.dir}:\
4.34 + ${libs.junit.classpath}:\
4.35 + ${libs.junit_4.classpath}
4.36 +javadoc.additionalparam=
4.37 +javadoc.author=false
4.38 +javadoc.encoding=${source.encoding}
4.39 +javadoc.noindex=false
4.40 +javadoc.nonavbar=false
4.41 +javadoc.notree=false
4.42 +javadoc.private=false
4.43 +javadoc.splitindex=true
4.44 +javadoc.use=true
4.45 +javadoc.version=false
4.46 +javadoc.windowtitle=
4.47 +main.class=conditionaluseofapi.Main
4.48 +meta.inf.dir=${src.dir}/META-INF
4.49 +platform.active=default_platform
4.50 +run.classpath=\
4.51 + ${javac.classpath}:\
4.52 + ${build.classes.dir}
4.53 +# Space-separated list of JVM arguments used when running the project
4.54 +# (you may also define separate properties like run-sys-prop.name=value instead of -Dname=value
4.55 +# or test-sys-prop.name=value to set system properties for unit tests):
4.56 +run.jvmargs=
4.57 +run.test.classpath=\
4.58 + ${javac.test.classpath}:\
4.59 + ${build.test.classes.dir}
4.60 +source.encoding=UTF-8
4.61 +src.dir=src
4.62 +test.src.dir=test
5.1 --- /dev/null Thu Jan 01 00:00:00 1970 +0000
5.2 +++ b/samples/conditionaluseofapi/nbproject/project.xml Sat Jun 14 09:50:50 2008 +0200
5.3 @@ -0,0 +1,16 @@
5.4 +<?xml version="1.0" encoding="UTF-8"?>
5.5 +<project xmlns="http://www.netbeans.org/ns/project/1">
5.6 + <type>org.netbeans.modules.java.j2seproject</type>
5.7 + <configuration>
5.8 + <data xmlns="http://www.netbeans.org/ns/j2se-project/3">
5.9 + <name>conditionaluseofapi</name>
5.10 + <minimum-ant-version>1.6.5</minimum-ant-version>
5.11 + <source-roots>
5.12 + <root id="src.dir"/>
5.13 + </source-roots>
5.14 + <test-roots>
5.15 + <root id="test.src.dir"/>
5.16 + </test-roots>
5.17 + </data>
5.18 + </configuration>
5.19 +</project>
6.1 --- /dev/null Thu Jan 01 00:00:00 1970 +0000
6.2 +++ b/samples/conditionaluseofapi/src/conditionaluseofapi/AddString.java Sat Jun 14 09:50:50 2008 +0200
6.3 @@ -0,0 +1,14 @@
6.4 +
6.5 +package conditionaluseofapi;
6.6 +
6.7 +/** Facade interface to shield us from the actual implementation for
6.8 + * Java 1.4 and Java 5.
6.9 + *
6.10 + * @author Jaroslav Tulach <jtulach@netbeans.org>
6.11 + */
6.12 +// BEGIN: theory.binary.overloads.facade
6.13 +interface AddString {
6.14 + public void addString(String msg);
6.15 + public String getMessage();
6.16 +}
6.17 +// END: theory.binary.overloads.facade
7.1 --- /dev/null Thu Jan 01 00:00:00 1970 +0000
7.2 +++ b/samples/conditionaluseofapi/src/conditionaluseofapi/Main.java Sat Jun 14 09:50:50 2008 +0200
7.3 @@ -0,0 +1,41 @@
7.4 +/*
7.5 + * Sun Public License Notice
7.6 + *
7.7 + * The contents of this file are subject to the Sun Public License
7.8 + * Version 1.0 (the "License"). You may not use this file except in
7.9 + * compliance with the License. A copy of the License is available at
7.10 + * http://www.sun.com/
7.11 + *
7.12 + * The Original Code is NetBeans. The Initial Developer of the Original
7.13 + * Code is Jaroslav Tulach. Portions Copyright 2007 Jaroslav Tulach.
7.14 + * All Rights Reserved.
7.15 + */
7.16 +package conditionaluseofapi;
7.17 +
7.18 +/**
7.19 + *
7.20 + * @author Jaroslav Tulach <jtulach@netbeans.org>
7.21 + */
7.22 +public class Main {
7.23 +
7.24 + public static void main(String[] args) throws Exception {
7.25 + // BEGIN: theory.binary.overloads.init
7.26 + AddString add;
7.27 +
7.28 + try {
7.29 + Class onlyOn15 = Class.forName("java.lang.StringBuilder");
7.30 + add = (AddString)Class.forName("conditionaluseofapi.StringBuilderAdd15").newInstance();
7.31 + } catch (ClassNotFoundException ex) {
7.32 + add = new StringBufferAdd();
7.33 + }
7.34 + // END: theory.binary.overloads.init
7.35 +
7.36 + add.addString("Hello");
7.37 + add.addString(" ");
7.38 + add.addString("World!");
7.39 +
7.40 + System.out.println(add.getMessage());
7.41 + System.out.println("printed with: " + add);
7.42 + }
7.43 +
7.44 +}
8.1 --- /dev/null Thu Jan 01 00:00:00 1970 +0000
8.2 +++ b/samples/conditionaluseofapi/src/conditionaluseofapi/StringBufferAdd.java Sat Jun 14 09:50:50 2008 +0200
8.3 @@ -0,0 +1,22 @@
8.4 +package conditionaluseofapi;
8.5 +
8.6 +/** Implementation for string concatention using Java 1.4 APIs.
8.7 + *
8.8 + * @author Jaroslav Tulach <jtulach@netbeans.org>
8.9 + */
8.10 +final class StringBufferAdd implements AddString {
8.11 +
8.12 + private StringBuffer sb = new StringBuffer();
8.13 +
8.14 + public void addString(String msg) {
8.15 + sb.append(msg);
8.16 + }
8.17 +
8.18 + public String getMessage() {
8.19 + return sb.toString();
8.20 + }
8.21 +
8.22 + public String toString() {
8.23 + return "Old Java 1.4 implementation";
8.24 + }
8.25 +}
9.1 --- /dev/null Thu Jan 01 00:00:00 1970 +0000
9.2 +++ b/samples/conditionaluseofapi/src/conditionaluseofapi/StringBuilderAdd15.java Sat Jun 14 09:50:50 2008 +0200
9.3 @@ -0,0 +1,26 @@
9.4 +package conditionaluseofapi;
9.5 +
9.6 +/** Implementation for string concatention using Java 5 only.
9.7 + *
9.8 + * StringBuilder is supposed to be faster than StringBuffer as it
9.9 + * is not synchronized and as such it is does not waste time with
9.10 + * synchronization when its methods are called.
9.11 + *
9.12 + * @author Jaroslav Tulach <jtulach@netbeans.org>
9.13 + */
9.14 +final class StringBuilderAdd15 implements AddString {
9.15 +
9.16 + private StringBuilder sb = new StringBuilder();
9.17 +
9.18 + public void addString(String msg) {
9.19 + sb.append(msg);
9.20 + }
9.21 +
9.22 + public String getMessage() {
9.23 + return sb.toString();
9.24 + }
9.25 +
9.26 + public String toString() {
9.27 + return "New Shiny and Fast Java 5 Implementation";
9.28 + }
9.29 +}
10.1 --- a/samples/friendpackage/nbproject/build-impl.xml Sat Jun 14 09:50:29 2008 +0200
10.2 +++ b/samples/friendpackage/nbproject/build-impl.xml Sat Jun 14 09:50:50 2008 +0200
10.3 @@ -108,6 +108,16 @@
10.4 <property name="javadoc.encoding.used" value="${source.encoding}"/>
10.5 <property name="includes" value="**"/>
10.6 <property name="excludes" value=""/>
10.7 + <property name="do.depend" value="false"/>
10.8 + <condition property="do.depend.true">
10.9 + <istrue value="${do.depend}"/>
10.10 + </condition>
10.11 + <condition else="" property="javac.compilerargs.jaxws" value="-Djava.endorsed.dirs='${jaxws.endorsed.dir}'">
10.12 + <and>
10.13 + <isset property="jaxws.endorsed.dir"/>
10.14 + <available file="nbproject/jaxws-build.xml"/>
10.15 + </and>
10.16 + </condition>
10.17 </target>
10.18 <target name="-post-init">
10.19 <!-- Empty placeholder for easier customization. -->
10.20 @@ -142,7 +152,6 @@
10.21 <attribute default="${includes}" name="includes"/>
10.22 <attribute default="${excludes}" name="excludes"/>
10.23 <attribute default="${javac.debug}" name="debug"/>
10.24 - <attribute default="" name="javac.compilerargs.jaxws"/>
10.25 <attribute default="" name="sourcepath"/>
10.26 <element name="customize" optional="true"/>
10.27 <sequential>
10.28 @@ -150,7 +159,7 @@
10.29 <classpath>
10.30 <path path="@{classpath}"/>
10.31 </classpath>
10.32 - <compilerarg line="${javac.compilerargs} @{javac.compilerargs.jaxws}"/>
10.33 + <compilerarg line="${javac.compilerargs} ${javac.compilerargs.jaxws}"/>
10.34 <customize/>
10.35 </javac>
10.36 </sequential>
10.37 @@ -187,11 +196,12 @@
10.38 <macrodef name="junit" uri="http://www.netbeans.org/ns/j2se-project/3">
10.39 <attribute default="${includes}" name="includes"/>
10.40 <attribute default="${excludes}" name="excludes"/>
10.41 + <attribute default="**" name="testincludes"/>
10.42 <sequential>
10.43 <junit dir="${work.dir}" errorproperty="tests.failed" failureproperty="tests.failed" fork="true" showoutput="true">
10.44 <batchtest todir="${build.test.results.dir}">
10.45 <fileset dir="${test.src.dir}" excludes="@{excludes},${excludes}" includes="@{includes}">
10.46 - <filename name="**/*Test.java"/>
10.47 + <filename name="@{testincludes}"/>
10.48 </fileset>
10.49 </batchtest>
10.50 <classpath>
10.51 @@ -306,8 +316,10 @@
10.52 <!-- Empty placeholder for easier customization. -->
10.53 <!-- You can override this target in the ../build.xml file. -->
10.54 </target>
10.55 - <target depends="init,deps-jar,-pre-pre-compile,-pre-compile" if="have.sources" name="-do-compile">
10.56 + <target if="do.depend.true" name="-compile-depend">
10.57 <j2seproject3:depend/>
10.58 + </target>
10.59 + <target depends="init,deps-jar,-pre-pre-compile,-pre-compile,-compile-depend" if="have.sources" name="-do-compile">
10.60 <j2seproject3:javac/>
10.61 <copy todir="${build.classes.dir}">
10.62 <fileset dir="${src.dir}" excludes="${build.classes.excludes},${excludes}" includes="${includes}"/>
10.63 @@ -455,7 +467,7 @@
10.64 -->
10.65 <target depends="init" name="-javadoc-build">
10.66 <mkdir dir="${dist.javadoc.dir}"/>
10.67 - <javadoc additionalparam="${javadoc.additionalparam}" author="${javadoc.author}" destdir="${dist.javadoc.dir}" 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}">
10.68 + <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}">
10.69 <classpath>
10.70 <path path="${javac.classpath}"/>
10.71 </classpath>
10.72 @@ -480,8 +492,10 @@
10.73 <!-- Empty placeholder for easier customization. -->
10.74 <!-- You can override this target in the ../build.xml file. -->
10.75 </target>
10.76 - <target depends="init,compile,-pre-pre-compile-test,-pre-compile-test" if="have.tests" name="-do-compile-test">
10.77 + <target if="do.depend.true" name="-compile-test-depend">
10.78 <j2seproject3:depend classpath="${javac.test.classpath}" destdir="${build.test.classes.dir}" srcdir="${test.src.dir}"/>
10.79 + </target>
10.80 + <target depends="init,compile,-pre-pre-compile-test,-pre-compile-test,-compile-test-depend" if="have.tests" name="-do-compile-test">
10.81 <j2seproject3:javac classpath="${javac.test.classpath}" debug="true" destdir="${build.test.classes.dir}" srcdir="${test.src.dir}"/>
10.82 <copy todir="${build.test.classes.dir}">
10.83 <fileset dir="${test.src.dir}" excludes="${build.classes.excludes},${excludes}" includes="${includes}"/>
10.84 @@ -518,7 +532,7 @@
10.85 <mkdir dir="${build.test.results.dir}"/>
10.86 </target>
10.87 <target depends="init,compile-test,-pre-test-run" if="have.tests" name="-do-test-run">
10.88 - <j2seproject3:junit/>
10.89 + <j2seproject3:junit testincludes="**/*Test.java"/>
10.90 </target>
10.91 <target depends="init,compile-test,-pre-test-run,-do-test-run" if="have.tests" name="-post-test-run">
10.92 <fail if="tests.failed">Some tests failed; see details above.</fail>
11.1 --- a/samples/friendpackage/nbproject/genfiles.properties Sat Jun 14 09:50:29 2008 +0200
11.2 +++ b/samples/friendpackage/nbproject/genfiles.properties Sat Jun 14 09:50:50 2008 +0200
11.3 @@ -4,5 +4,5 @@
11.4 # This file is used by a NetBeans-based IDE to track changes in generated files such as build-impl.xml.
11.5 # Do not edit this file. You may delete it but then the IDE will never regenerate such files for you.
11.6 nbproject/build-impl.xml.data.CRC32=b1c774b2
11.7 -nbproject/build-impl.xml.script.CRC32=93374311
11.8 -nbproject/build-impl.xml.stylesheet.CRC32=3c2f24dc
11.9 +nbproject/build-impl.xml.script.CRC32=2fcc3cdb
11.10 +nbproject/build-impl.xml.stylesheet.CRC32=f1d9da08
12.1 --- a/samples/friendpackage/src/apipkg/AccessorImpl.java Sat Jun 14 09:50:29 2008 +0200
12.2 +++ b/samples/friendpackage/src/apipkg/AccessorImpl.java Sat Jun 14 09:50:50 2008 +0200
12.3 @@ -7,8 +7,8 @@
12.4 * http://www.sun.com/
12.5 *
12.6 * The Original Code is NetBeans. The Initial Developer of the Original
12.7 - * Code is Sun Microsystems, Inc. Portions Copyright 1999-2006 Sun
12.8 - * Microsystems, Inc. All Rights Reserved.
12.9 + * Code is Jaroslav Tulach. Portions Copyright 2007 Jaroslav Tulach.
12.10 + * All Rights Reserved.
12.11 */
12.12
12.13 package apipkg;
13.1 --- a/samples/friendpackage/src/apipkg/Item.java Sat Jun 14 09:50:29 2008 +0200
13.2 +++ b/samples/friendpackage/src/apipkg/Item.java Sat Jun 14 09:50:50 2008 +0200
13.3 @@ -7,8 +7,8 @@
13.4 * http://www.sun.com/
13.5 *
13.6 * The Original Code is NetBeans. The Initial Developer of the Original
13.7 - * Code is Sun Microsystems, Inc. Portions Copyright 1999-2006 Sun
13.8 - * Microsystems, Inc. All Rights Reserved.
13.9 + * Code is Jaroslav Tulach. Portions Copyright 2007 Jaroslav Tulach.
13.10 + * All Rights Reserved.
13.11 */
13.12
13.13 package apipkg;
14.1 --- a/samples/friendpackage/src/implpkg/Accessor.java Sat Jun 14 09:50:29 2008 +0200
14.2 +++ b/samples/friendpackage/src/implpkg/Accessor.java Sat Jun 14 09:50:50 2008 +0200
14.3 @@ -7,8 +7,8 @@
14.4 * http://www.sun.com/
14.5 *
14.6 * The Original Code is NetBeans. The Initial Developer of the Original
14.7 - * Code is Sun Microsystems, Inc. Portions Copyright 1999-2006 Sun
14.8 - * Microsystems, Inc. All Rights Reserved.
14.9 + * Code is Jaroslav Tulach. Portions Copyright 2007 Jaroslav Tulach.
14.10 + * All Rights Reserved.
14.11 */
14.12
14.13 package implpkg;
15.1 --- a/samples/friendpackage/test/implpkg/AccessorTest.java Sat Jun 14 09:50:29 2008 +0200
15.2 +++ b/samples/friendpackage/test/implpkg/AccessorTest.java Sat Jun 14 09:50:50 2008 +0200
15.3 @@ -7,8 +7,8 @@
15.4 * http://www.sun.com/
15.5 *
15.6 * The Original Code is NetBeans. The Initial Developer of the Original
15.7 - * Code is Sun Microsystems, Inc. Portions Copyright 1999-2006 Sun
15.8 - * Microsystems, Inc. All Rights Reserved.
15.9 + * Code is Jaroslav Tulach. Portions Copyright 2007 Jaroslav Tulach.
15.10 + * All Rights Reserved.
15.11 */
15.12
15.13 package implpkg;