merging work from the branch playing_with_server to trunk BLD200610021800
authorjtulach@netbeans.org
Mon, 02 Oct 2006 17:00:09 +0000
changeset 1806cd04f6bb2e13
parent 1805 2f8ca3a42f6d
child 1807 4ba2d459d83c
merging work from the branch playing_with_server to trunk
logger/uihandlerserver/build.xml
logger/uihandlerserver/nbproject/ant-deploy.xml
logger/uihandlerserver/nbproject/build-impl.xml
logger/uihandlerserver/nbproject/genfiles.properties
logger/uihandlerserver/nbproject/project.properties
logger/uihandlerserver/nbproject/project.xml
logger/uihandlerserver/src/conf/MANIFEST.MF
logger/uihandlerserver/src/java/org/netbeans/server/uihandler/UploadLogs.java
logger/uihandlerserver/web/META-INF/context.xml
logger/uihandlerserver/web/WEB-INF/sun-web.xml
logger/uihandlerserver/web/WEB-INF/web.xml
logger/uihandlerserver/web/error.jsp
logger/uihandlerserver/web/index.jsp
logger/uihandlerserver/web/upload.jsp
logger/uihandlerserver/web/uploaddone.jsp
     1.1 --- /dev/null	Thu Jan 01 00:00:00 1970 +0000
     1.2 +++ b/logger/uihandlerserver/build.xml	Mon Oct 02 17:00:09 2006 +0000
     1.3 @@ -0,0 +1,66 @@
     1.4 +<?xml version="1.0" encoding="UTF-8"?>
     1.5 +<!-- You may freely edit this file. See commented blocks below for -->
     1.6 +<!-- some examples of how to customize the build. -->
     1.7 +<!-- (If you delete it and reopen the project it will be recreated.) -->
     1.8 +<project name="uihandlerserver" default="default" basedir=".">
     1.9 +    <description>Builds, tests, and runs the project uihandlerserver.</description>
    1.10 +    <import file="nbproject/build-impl.xml"/>
    1.11 +    <!--
    1.12 +
    1.13 +    There exist several targets which are by default empty and which can be 
    1.14 +    used for execution of your tasks. These targets are usually executed 
    1.15 +    before and after some main targets. They are: 
    1.16 +
    1.17 +      -pre-init:                 called before initialization of project properties 
    1.18 +      -post-init:                called after initialization of project properties 
    1.19 +      -pre-compile:              called before javac compilation 
    1.20 +      -post-compile:             called after javac compilation 
    1.21 +      -pre-compile-single:       called before javac compilation of single file
    1.22 +      -post-compile-single:      called after javac compilation of single file
    1.23 +      -pre-compile-test:         called before javac compilation of JUnit tests
    1.24 +      -post-compile-test:        called after javac compilation of JUnit tests
    1.25 +      -pre-compile-test-single:  called before javac compilation of single JUnit test
    1.26 +      -post-compile-test-single: called after javac compilation of single JUunit test
    1.27 +      -pre-dist:                 called before jar building 
    1.28 +      -post-dist:                called after jar building 
    1.29 +      -post-clean:               called after cleaning build products 
    1.30 +      -pre-run-deploy:           called before deploying
    1.31 +      -post-run-deploy:          called after deploying
    1.32 +
    1.33 +    Example of pluging an obfuscator after the compilation could look like 
    1.34 +
    1.35 +        <target name="post-compile">
    1.36 +            <obfuscate>
    1.37 +                <fileset dir="${build.classes.dir}"/>
    1.38 +            </obfuscate>
    1.39 +        </target>
    1.40 +
    1.41 +    For list of available properties check the imported 
    1.42 +    nbproject/build-impl.xml file. 
    1.43 +
    1.44 +
    1.45 +    Other way how to customize the build is by overriding existing main targets.
    1.46 +    The target of interest are: 
    1.47 +
    1.48 +      init-macrodef-javac:    defines macro for javac compilation
    1.49 +      init-macrodef-junit:   defines macro for junit execution
    1.50 +      init-macrodef-debug:    defines macro for class debugging
    1.51 +      do-dist:                jar archive building
    1.52 +      run:                    execution of project 
    1.53 +      javadoc-build:          javadoc generation 
    1.54 +
    1.55 +    Example of overriding the target for project execution could look like 
    1.56 +
    1.57 +        <target name="run" depends="<PROJNAME>-impl.jar">
    1.58 +            <exec dir="bin" executable="launcher.exe">
    1.59 +                <arg file="${dist.jar}"/>
    1.60 +            </exec>
    1.61 +        </target>
    1.62 +
    1.63 +    Notice that overridden target depends on jar target and not only on 
    1.64 +    compile target as regular run target does. Again, for list of available 
    1.65 +    properties which you can use check the target you are overriding in 
    1.66 +    nbproject/build-impl.xml file. 
    1.67 +
    1.68 +    -->
    1.69 +</project>
     2.1 --- /dev/null	Thu Jan 01 00:00:00 1970 +0000
     2.2 +++ b/logger/uihandlerserver/nbproject/ant-deploy.xml	Mon Oct 02 17:00:09 2006 +0000
     2.3 @@ -0,0 +1,28 @@
     2.4 +<?xml version="1.0" encoding="UTF-8"?>
     2.5 +<project default="-deploy-ant" basedir=".">
     2.6 +    <target name="-init" if="deploy.ant.enabled">
     2.7 +        <property file="${deploy.ant.properties.file}"/>
     2.8 +        <tempfile property="temp.module.folder" prefix="tomcat" destdir="${java.io.tmpdir}"/>
     2.9 +        <unwar src="${deploy.ant.archive}" dest="${temp.module.folder}">
    2.10 +            <patternset includes="META-INF/context.xml"/>
    2.11 +        </unwar>
    2.12 +        <xmlproperty file="${temp.module.folder}/META-INF/context.xml"/>
    2.13 +        <delete dir="${temp.module.folder}"/>
    2.14 +    </target>
    2.15 +    <target name="-deploy-ant" if="deploy.ant.enabled" depends="-init">
    2.16 +        <echo message="Deploying ${deploy.ant.archive} to ${Context(path)}"/>
    2.17 +        <taskdef name="deploy" classname="org.apache.catalina.ant.DeployTask"
    2.18 +                 classpath="${tomcat.home}/server/lib/catalina-ant.jar"/>
    2.19 +        <deploy url="${tomcat.url}/manager" username="${tomcat.username}"
    2.20 +                password="${tomcat.password}" path="${Context(path)}"
    2.21 +                war="${deploy.ant.archive}"/>
    2.22 +        <property name="deploy.ant.client.url" value="${tomcat.url}${Context(path)}"/>
    2.23 +    </target>
    2.24 +    <target name="-undeploy-ant" if="deploy.ant.enabled" depends="-init">
    2.25 +        <echo message="Undeploying ${Context(path)}"/>
    2.26 +        <taskdef name="undeploy"  classname="org.apache.catalina.ant.UndeployTask"
    2.27 +                classpath="${tomcat.home}/server/lib/catalina-ant.jar"/>
    2.28 +        <undeploy url="${tomcat.url}/manager" username="${tomcat.username}" 
    2.29 +                  password="${tomcat.password}" path="${Context(path)}"/>
    2.30 +    </target>
    2.31 +</project>
     3.1 --- /dev/null	Thu Jan 01 00:00:00 1970 +0000
     3.2 +++ b/logger/uihandlerserver/nbproject/build-impl.xml	Mon Oct 02 17:00:09 2006 +0000
     3.3 @@ -0,0 +1,694 @@
     3.4 +<?xml version="1.0" encoding="UTF-8"?>
     3.5 +<!--
     3.6 +        *** GENERATED FROM project.xml - DO NOT EDIT  ***
     3.7 +        ***         EDIT ../build.xml INSTEAD         ***
     3.8 +
     3.9 +        For the purpose of easier reading the script
    3.10 +        is divided into following sections:
    3.11 +        - initialization
    3.12 +        - compilation
    3.13 +        - dist
    3.14 +        - execution
    3.15 +        - debugging
    3.16 +        - javadoc
    3.17 +        - junit compilation
    3.18 +        - junit execution
    3.19 +        - junit debugging
    3.20 +        - cleanup
    3.21 +
    3.22 +        -->
    3.23 +<project name="uihandlerserver-impl" default="build" basedir=".." xmlns:webproject3="http://www.netbeans.org/ns/web-project/3" xmlns:webproject2="http://www.netbeans.org/ns/web-project/2" xmlns:jaxws="http://www.netbeans.org/ns/jax-ws/1" xmlns:webproject1="http://www.netbeans.org/ns/web-project/1">
    3.24 +    <import file="ant-deploy.xml"/>
    3.25 +    <target name="default" depends="dist,javadoc" description="Build whole project."/>
    3.26 +    <!--
    3.27 +                INITIALIZATION SECTION
    3.28 +            -->
    3.29 +    <target name="-pre-init">
    3.30 +        <!-- Empty placeholder for easier customization. -->
    3.31 +        <!-- You can override this target in the ../build.xml file. -->
    3.32 +    </target>
    3.33 +    <target name="-init-private" depends="-pre-init">
    3.34 +        <property file="nbproject/private/private.properties"/>
    3.35 +    </target>
    3.36 +    <target name="-init-user" depends="-pre-init,-init-private">
    3.37 +        <property file="${user.properties.file}"/>
    3.38 +        <!-- The two properties below are usually overridden -->
    3.39 +        <!-- by the active platform. Just a fallback. -->
    3.40 +        <property name="default.javac.source" value="1.4"/>
    3.41 +        <property name="default.javac.target" value="1.4"/>
    3.42 +    </target>
    3.43 +    <target name="-init-project" depends="-pre-init,-init-private,-init-user">
    3.44 +        <property file="nbproject/project.properties"/>
    3.45 +    </target>
    3.46 +    <target name="-do-ear-init" depends="-pre-init,-init-private,-init-user,-init-project,-init-macrodef-property" if="dist.ear.dir">
    3.47 +        <property value="${build.ear.web.dir}/META-INF" name="build.meta.inf.dir"/>
    3.48 +        <property name="build.classes.dir.real" value="${build.ear.classes.dir}"/>
    3.49 +        <property name="build.web.dir.real" value="${build.ear.web.dir}"/>
    3.50 +    </target>
    3.51 +    <target name="-do-init" depends="-pre-init,-init-private,-init-user,-init-project,-init-macrodef-property, -do-ear-init">
    3.52 +        <condition property="have.tests">
    3.53 +            <or>
    3.54 +                <available file="${test.src.dir}"/>
    3.55 +            </or>
    3.56 +        </condition>
    3.57 +        <condition property="have.sources">
    3.58 +            <or>
    3.59 +                <available file="${src.dir}"/>
    3.60 +            </or>
    3.61 +        </condition>
    3.62 +        <condition property="netbeans.home+have.tests">
    3.63 +            <and>
    3.64 +                <isset property="netbeans.home"/>
    3.65 +                <isset property="have.tests"/>
    3.66 +            </and>
    3.67 +        </condition>
    3.68 +        <condition property="no.javadoc.preview">
    3.69 +            <isfalse value="${javadoc.preview}"/>
    3.70 +        </condition>
    3.71 +        <property name="javac.compilerargs" value=""/>
    3.72 +        <condition property="no.deps">
    3.73 +            <and>
    3.74 +                <istrue value="${no.dependencies}"/>
    3.75 +            </and>
    3.76 +        </condition>
    3.77 +        <condition property="no.dist.ear.dir">
    3.78 +            <not>
    3.79 +                <isset property="dist.ear.dir"/>
    3.80 +            </not>
    3.81 +        </condition>
    3.82 +        <property name="build.web.excludes" value="${build.classes.excludes}"/>
    3.83 +        <condition property="do.compile.jsps">
    3.84 +            <istrue value="${compile.jsps}"/>
    3.85 +        </condition>
    3.86 +        <condition property="do.display.browser">
    3.87 +            <istrue value="${display.browser}"/>
    3.88 +        </condition>
    3.89 +        <available file="${conf.dir}/MANIFEST.MF" property="has.custom.manifest"/>
    3.90 +        <available file="${conf.dir}/persistence.xml" property="has.persistence.xml"/>
    3.91 +        <condition property="do.war.package.with.custom.manifest">
    3.92 +            <and>
    3.93 +                <istrue value="${war.package}"/>
    3.94 +                <isset property="has.custom.manifest"/>
    3.95 +            </and>
    3.96 +        </condition>
    3.97 +        <condition property="do.war.package.without.custom.manifest">
    3.98 +            <and>
    3.99 +                <istrue value="${war.package}"/>
   3.100 +                <not>
   3.101 +                    <isset property="has.custom.manifest"/>
   3.102 +                </not>
   3.103 +            </and>
   3.104 +        </condition>
   3.105 +        <property value="${build.web.dir}/META-INF" name="build.meta.inf.dir"/>
   3.106 +        <property name="build.classes.dir.real" value="${build.classes.dir}"/>
   3.107 +        <property name="build.web.dir.real" value="${build.web.dir}"/>
   3.108 +    </target>
   3.109 +    <target name="-post-init">
   3.110 +        <!-- Empty placeholder for easier customization. -->
   3.111 +        <!-- You can override this target in the ../build.xml file. -->
   3.112 +    </target>
   3.113 +    <target name="-init-check" depends="-pre-init,-init-private,-init-user,-init-project,-do-init">
   3.114 +        <fail unless="src.dir">Must set src.dir</fail>
   3.115 +        <fail unless="test.src.dir">Must set test.src.dir</fail>
   3.116 +        <fail unless="build.dir">Must set build.dir</fail>
   3.117 +        <fail unless="build.web.dir">Must set build.web.dir</fail>
   3.118 +        <fail unless="build.generated.dir">Must set build.generated.dir</fail>
   3.119 +        <fail unless="dist.dir">Must set dist.dir</fail>
   3.120 +        <fail unless="build.classes.dir">Must set build.classes.dir</fail>
   3.121 +        <fail unless="dist.javadoc.dir">Must set dist.javadoc.dir</fail>
   3.122 +        <fail unless="build.test.classes.dir">Must set build.test.classes.dir</fail>
   3.123 +        <fail unless="build.test.results.dir">Must set build.test.results.dir</fail>
   3.124 +        <fail unless="build.classes.excludes">Must set build.classes.excludes</fail>
   3.125 +        <fail unless="dist.war">Must set dist.war</fail>
   3.126 +    </target>
   3.127 +    <target name="-init-macrodef-property">
   3.128 +        <macrodef name="property" uri="http://www.netbeans.org/ns/web-project/1">
   3.129 +            <attribute name="name"/>
   3.130 +            <attribute name="value"/>
   3.131 +            <sequential>
   3.132 +                <property name="@{name}" value="${@{value}}"/>
   3.133 +            </sequential>
   3.134 +        </macrodef>
   3.135 +    </target>
   3.136 +    <target name="-init-macrodef-javac">
   3.137 +        <macrodef name="javac" uri="http://www.netbeans.org/ns/web-project/2">
   3.138 +            <attribute name="srcdir" default="${src.dir}"/>
   3.139 +            <attribute name="destdir" default="${build.classes.dir.real}"/>
   3.140 +            <attribute name="classpath" default="${javac.classpath}:${j2ee.platform.classpath}"/>
   3.141 +            <attribute name="debug" default="${javac.debug}"/>
   3.142 +            <element name="customize" optional="true"/>
   3.143 +            <sequential>
   3.144 +                <javac srcdir="@{srcdir}" destdir="@{destdir}" debug="@{debug}" deprecation="${javac.deprecation}" source="${javac.source}" target="${javac.target}" includeantruntime="false">
   3.145 +                    <classpath>
   3.146 +                        <path path="@{classpath}"/>
   3.147 +                    </classpath>
   3.148 +                    <compilerarg line="${javac.compilerargs}"/>
   3.149 +                    <customize/>
   3.150 +                </javac>
   3.151 +            </sequential>
   3.152 +        </macrodef>
   3.153 +    </target>
   3.154 +    <target name="-init-macrodef-junit">
   3.155 +        <macrodef name="junit" uri="http://www.netbeans.org/ns/web-project/2">
   3.156 +            <attribute name="includes" default="**/*Test.java"/>
   3.157 +            <sequential>
   3.158 +                <junit showoutput="true" fork="true" dir="${basedir}" failureproperty="tests.failed" errorproperty="tests.failed">
   3.159 +                    <batchtest todir="${build.test.results.dir}">
   3.160 +                        <fileset dir="${test.src.dir}" includes="@{includes}"/>
   3.161 +                    </batchtest>
   3.162 +                    <classpath>
   3.163 +                        <path path="${run.test.classpath}"/>
   3.164 +                    </classpath>
   3.165 +                    <syspropertyset>
   3.166 +                        <propertyref prefix="test-sys-prop."/>
   3.167 +                        <mapper type="glob" from="test-sys-prop.*" to="*"/>
   3.168 +                    </syspropertyset>
   3.169 +                    <formatter type="brief" usefile="false"/>
   3.170 +                    <formatter type="xml"/>
   3.171 +                </junit>
   3.172 +            </sequential>
   3.173 +        </macrodef>
   3.174 +    </target>
   3.175 +    <target name="-init-macrodef-java">
   3.176 +        <macrodef name="java" uri="http://www.netbeans.org/ns/web-project/1">
   3.177 +            <attribute name="classname" default="${main.class}"/>
   3.178 +            <element name="customize" optional="true"/>
   3.179 +            <sequential>
   3.180 +                <java fork="true" classname="@{classname}">
   3.181 +                    <jvmarg line="${runmain.jvmargs}"/>
   3.182 +                    <classpath>
   3.183 +                        <path path="${build.classes.dir.real}:${javac.classpath}:${j2ee.platform.classpath}"/>
   3.184 +                    </classpath>
   3.185 +                    <syspropertyset>
   3.186 +                        <propertyref prefix="run-sys-prop."/>
   3.187 +                        <mapper type="glob" from="run-sys-prop.*" to="*"/>
   3.188 +                    </syspropertyset>
   3.189 +                    <customize/>
   3.190 +                </java>
   3.191 +            </sequential>
   3.192 +        </macrodef>
   3.193 +    </target>
   3.194 +    <target name="-init-macrodef-nbjpda">
   3.195 +        <macrodef name="nbjpdastart" uri="http://www.netbeans.org/ns/web-project/1">
   3.196 +            <attribute name="name" default="${main.class}"/>
   3.197 +            <attribute name="classpath" default="${debug.classpath}"/>
   3.198 +            <sequential>
   3.199 +                <nbjpdastart transport="dt_socket" addressproperty="jpda.address" name="@{name}">
   3.200 +                    <classpath>
   3.201 +                        <path path="@{classpath}"/>
   3.202 +                    </classpath>
   3.203 +                </nbjpdastart>
   3.204 +            </sequential>
   3.205 +        </macrodef>
   3.206 +        <macrodef name="nbjpdareload" uri="http://www.netbeans.org/ns/web-project/1">
   3.207 +            <attribute name="dir" default="${build.classes.dir.real}"/>
   3.208 +            <sequential>
   3.209 +                <nbjpdareload>
   3.210 +                    <fileset includes="${fix.includes}*.class" dir="@{dir}"/>
   3.211 +                </nbjpdareload>
   3.212 +            </sequential>
   3.213 +        </macrodef>
   3.214 +    </target>
   3.215 +    <target name="-init-macrodef-debug">
   3.216 +        <macrodef name="debug" uri="http://www.netbeans.org/ns/web-project/1">
   3.217 +            <attribute name="classname" default="${main.class}"/>
   3.218 +            <attribute name="classpath" default="${debug.classpath}"/>
   3.219 +            <sequential>
   3.220 +                <java fork="true" classname="@{classname}">
   3.221 +                    <jvmarg value="-Xdebug"/>
   3.222 +                    <jvmarg value="-Xnoagent"/>
   3.223 +                    <jvmarg value="-Djava.compiler=none"/>
   3.224 +                    <jvmarg value="-Xrunjdwp:transport=dt_socket,address=${jpda.address}"/>
   3.225 +                    <jvmarg line="${runmain.jvmargs}"/>
   3.226 +                    <classpath>
   3.227 +                        <path path="@{classpath}"/>
   3.228 +                    </classpath>
   3.229 +                    <syspropertyset>
   3.230 +                        <propertyref prefix="run-sys-prop."/>
   3.231 +                        <mapper type="glob" from="run-sys-prop.*" to="*"/>
   3.232 +                    </syspropertyset>
   3.233 +                </java>
   3.234 +            </sequential>
   3.235 +        </macrodef>
   3.236 +    </target>
   3.237 +    <target name="-init-macrodef-copy-ear-war">
   3.238 +        <macrodef name="copy-ear-war">
   3.239 +            <attribute name="file"/>
   3.240 +            <attribute name="propname"/>
   3.241 +            <sequential>
   3.242 +                <basename property="base_@{propname}" file="@{file}"/>
   3.243 +                <zipfileset id="tld.files_@{propname}" src="@{file}" includes="META-INF/*.tld META-INF/tlds/*.tld"/>
   3.244 +                <pathconvert property="tld.files.path_@{propname}" refid="tld.files_@{propname}"/>
   3.245 +                <condition value="yes" property="hastlds_@{propname}">
   3.246 +                    <contains string="${tld.files.path_@{propname}}" substring=".tld" casesensitive="false"/>
   3.247 +                </condition>
   3.248 +                <condition value="${build.web.dir.real}/WEB-INF/lib" property="copy.to.dir_@{propname}">
   3.249 +                    <isset property="hastlds_@{propname}"/>
   3.250 +                </condition>
   3.251 +                <condition value="${dist.ear.dir}" property="copy.to.dir_@{propname}">
   3.252 +                    <not>
   3.253 +                        <isset property="hastlds_@{propname}"/>
   3.254 +                    </not>
   3.255 +                </condition>
   3.256 +                <copy file="@{file}" todir="${copy.to.dir_@{propname}}"/>
   3.257 +                <condition value="${base_@{propname}}" property="@{propname}">
   3.258 +                    <not>
   3.259 +                        <isset property="hastlds_@{propname}"/>
   3.260 +                    </not>
   3.261 +                </condition>
   3.262 +                <condition value="" property="@{propname}">
   3.263 +                    <isset property="hastlds_@{propname}"/>
   3.264 +                </condition>
   3.265 +            </sequential>
   3.266 +        </macrodef>
   3.267 +    </target>
   3.268 +    <target name="init" 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-java,-init-macrodef-nbjpda,-init-macrodef-debug,-init-macrodef-copy-ear-war"/>
   3.269 +    <!--
   3.270 +                COMPILATION SECTION
   3.271 +            -->
   3.272 +    <target name="deps-module-jar" depends="init" if="no.dist.ear.dir" unless="no.deps">
   3.273 +        <ant target="netbeans" inheritall="false" antfile="${project.org_netbeans_lib_uihandler}/build.xml"/>
   3.274 +    </target>
   3.275 +    <target name="deps-ear-jar" depends="init" if="dist.ear.dir" unless="no.deps">
   3.276 +        <ant target="dist-ear" inheritall="false" antfile="${project.org_netbeans_lib_uihandler}/build.xml">
   3.277 +            <property name="dist.ear.dir" location="${build.dir}"/>
   3.278 +        </ant>
   3.279 +    </target>
   3.280 +    <target name="deps-jar" depends="init, deps-module-jar, deps-ear-jar" unless="no.deps"/>
   3.281 +    <target name="-pre-pre-compile" depends="init,deps-jar">
   3.282 +        <mkdir dir="${build.classes.dir.real}"/>
   3.283 +    </target>
   3.284 +    <target name="-pre-compile">
   3.285 +        <!-- Empty placeholder for easier customization. -->
   3.286 +        <!-- You can override this target in the ../build.xml file. -->
   3.287 +    </target>
   3.288 +    <target name="-copy-webdir">
   3.289 +        <copy todir="${build.web.dir.real}">
   3.290 +            <fileset excludes="${build.web.excludes}" dir="${web.docbase.dir}"/>
   3.291 +        </copy>
   3.292 +    </target>
   3.293 +    <target name="-do-compile" 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">
   3.294 +        <webproject2:javac destdir="${build.classes.dir.real}"/>
   3.295 +        <copy todir="${build.classes.dir.real}">
   3.296 +            <fileset dir="${src.dir}" excludes="${build.classes.excludes}"/>
   3.297 +        </copy>
   3.298 +    </target>
   3.299 +    <target name="-copy-manifest" if="has.custom.manifest">
   3.300 +        <mkdir dir="${build.meta.inf.dir}"/>
   3.301 +        <copy todir="${build.meta.inf.dir}">
   3.302 +            <fileset dir="${conf.dir}" includes="MANIFEST.MF"/>
   3.303 +        </copy>
   3.304 +    </target>
   3.305 +    <target name="-copy-persistence-xml" if="has.persistence.xml">
   3.306 +        <mkdir dir="${build.web.dir.real}/WEB-INF/classes/META-INF"/>
   3.307 +        <copy todir="${build.web.dir.real}/WEB-INF/classes/META-INF">
   3.308 +            <fileset dir="${conf.dir}" includes="persistence.xml"/>
   3.309 +        </copy>
   3.310 +    </target>
   3.311 +    <target name="-post-compile">
   3.312 +        <!-- Empty placeholder for easier customization. -->
   3.313 +        <!-- You can override this target in the ../build.xml file. -->
   3.314 +    </target>
   3.315 +    <target name="compile" depends="init,deps-jar,-pre-pre-compile,-pre-compile,-do-compile,-post-compile" description="Compile project."/>
   3.316 +    <target name="-pre-compile-single">
   3.317 +        <!-- Empty placeholder for easier customization. -->
   3.318 +        <!-- You can override this target in the ../build.xml file. -->
   3.319 +    </target>
   3.320 +    <target name="-do-compile-single" depends="init,deps-jar,-pre-pre-compile">
   3.321 +        <fail unless="javac.includes">Must select some files in the IDE or set javac.includes</fail>
   3.322 +        <webproject2:javac>
   3.323 +            <customize>
   3.324 +                <patternset includes="${javac.includes}"/>
   3.325 +            </customize>
   3.326 +        </webproject2:javac>
   3.327 +        <copy todir="${build.classes.dir.real}">
   3.328 +            <fileset dir="${src.dir}" excludes="${build.classes.excludes}"/>
   3.329 +        </copy>
   3.330 +    </target>
   3.331 +    <target name="-post-compile-single">
   3.332 +        <!-- Empty placeholder for easier customization. -->
   3.333 +        <!-- You can override this target in the ../build.xml file. -->
   3.334 +    </target>
   3.335 +    <target name="compile-single" depends="init,deps-jar,-pre-pre-compile,-pre-compile-single,-do-compile-single,-post-compile-single"/>
   3.336 +    <target name="compile-jsps" depends="compile" if="do.compile.jsps" description="Test compile JSP pages to expose compilation errors.">
   3.337 +        <mkdir dir="${build.generated.dir}/src"/>
   3.338 +        <java classname="org.netbeans.modules.web.project.ant.JspC" fork="true" failonerror="true">
   3.339 +            <arg value="-uriroot"/>
   3.340 +            <arg file="${basedir}/${build.web.dir.real}"/>
   3.341 +            <arg value="-d"/>
   3.342 +            <arg file="${basedir}/${build.generated.dir}/src"/>
   3.343 +            <arg value="-die1"/>
   3.344 +            <classpath path="${java.home}/../lib/tools.jar:${copyfiles.classpath}:${jspcompilation.classpath}"/>
   3.345 +        </java>
   3.346 +        <mkdir dir="${build.generated.dir}/classes"/>
   3.347 +        <webproject2:javac srcdir="${build.generated.dir}/src" destdir="${build.generated.dir}/classes" classpath="${j2ee.platform.classpath}:${build.classes.dir.real}:${jspcompilation.classpath}"/>
   3.348 +    </target>
   3.349 +    <target name="-do-compile-single-jsp" depends="compile" if="jsp.includes">
   3.350 +        <fail unless="javac.jsp.includes">Must select some files in the IDE or set javac.jsp.includes</fail>
   3.351 +        <mkdir dir="${build.generated.dir}/src"/>
   3.352 +        <java classname="org.netbeans.modules.web.project.ant.JspCSingle" fork="true" failonerror="true">
   3.353 +            <arg value="-uriroot"/>
   3.354 +            <arg file="${basedir}/${build.web.dir.real}"/>
   3.355 +            <arg value="-d"/>
   3.356 +            <arg file="${basedir}/${build.generated.dir}/src"/>
   3.357 +            <arg value="-die1"/>
   3.358 +            <arg value="-jspc.files"/>
   3.359 +            <arg path="${jsp.includes}"/>
   3.360 +            <classpath path="${java.home}/../lib/tools.jar:${copyfiles.classpath}:${jspcompilation.classpath}"/>
   3.361 +        </java>
   3.362 +        <mkdir dir="${build.generated.dir}/classes"/>
   3.363 +        <webproject2:javac srcdir="${build.generated.dir}/src" destdir="${build.generated.dir}/classes" classpath="${j2ee.platform.classpath}:${build.classes.dir.real}:${jspcompilation.classpath}">
   3.364 +            <customize>
   3.365 +                <patternset includes="${javac.jsp.includes}"/>
   3.366 +            </customize>
   3.367 +        </webproject2:javac>
   3.368 +    </target>
   3.369 +    <target name="compile-single-jsp">
   3.370 +        <fail unless="jsp.includes">Must select a file in the IDE or set jsp.includes</fail>
   3.371 +        <antcall target="-do-compile-single-jsp"/>
   3.372 +    </target>
   3.373 +    <!--
   3.374 +                DIST BUILDING SECTION
   3.375 +            -->
   3.376 +    <target name="-pre-dist">
   3.377 +        <!-- Empty placeholder for easier customization. -->
   3.378 +        <!-- You can override this target in the ../build.xml file. -->
   3.379 +    </target>
   3.380 +    <target name="-do-dist-without-manifest" if="do.war.package.without.custom.manifest" depends="init,compile,compile-jsps,-pre-dist">
   3.381 +        <dirname property="dist.jar.dir" file="${dist.war}"/>
   3.382 +        <mkdir dir="${dist.jar.dir}"/>
   3.383 +        <jar jarfile="${dist.war}" compress="${jar.compress}">
   3.384 +            <fileset dir="${build.web.dir.real}"/>
   3.385 +        </jar>
   3.386 +    </target>
   3.387 +    <target name="-do-dist-with-manifest" if="do.war.package.with.custom.manifest" depends="init,compile,compile-jsps,-pre-dist">
   3.388 +        <dirname property="dist.jar.dir" file="${dist.war}"/>
   3.389 +        <mkdir dir="${dist.jar.dir}"/>
   3.390 +        <jar manifest="${build.meta.inf.dir}/MANIFEST.MF" jarfile="${dist.war}" compress="${jar.compress}">
   3.391 +            <fileset dir="${build.web.dir.real}"/>
   3.392 +        </jar>
   3.393 +    </target>
   3.394 +    <target name="do-dist" depends="init,compile,compile-jsps,-pre-dist,-do-dist-with-manifest,-do-dist-without-manifest"/>
   3.395 +    <target name="library-inclusion-in-manifest" depends="init" if="dist.ear.dir">
   3.396 +        <basename property="included.lib.reference.org_netbeans_lib_uihandler.module" file="${reference.org_netbeans_lib_uihandler.module}"/>
   3.397 +        <copy-ear-war file="${reference.org_netbeans_lib_uihandler.module}" propname="included.lib.reference.org_netbeans_lib_uihandler.module.X"/>
   3.398 +        <mkdir dir="${build.web.dir.real}/META-INF"/>
   3.399 +        <manifest file="${build.web.dir.real}/META-INF/MANIFEST.MF" mode="update">
   3.400 +            <attribute name="Class-Path" value="${included.lib.reference.org_netbeans_lib_uihandler.module} "/>
   3.401 +        </manifest>
   3.402 +        <delete dir="${dist.ear.dir}/temp"/>
   3.403 +    </target>
   3.404 +    <target name="library-inclusion-in-archive" depends="init" unless="dist.ear.dir">
   3.405 +        <copy file="${reference.org_netbeans_lib_uihandler.module}" todir="${build.web.dir.real}/WEB-INF/lib"/>
   3.406 +    </target>
   3.407 +    <target name="do-ear-dist" depends="init,compile,compile-jsps,-pre-dist,library-inclusion-in-manifest">
   3.408 +        <dirname property="dist.jar.dir" file="${dist.ear.war}"/>
   3.409 +        <mkdir dir="${dist.jar.dir}"/>
   3.410 +        <jar jarfile="${dist.ear.war}" compress="${jar.compress}" manifest="${build.web.dir.real}/META-INF/MANIFEST.MF">
   3.411 +            <fileset dir="${build.web.dir.real}"/>
   3.412 +        </jar>
   3.413 +    </target>
   3.414 +    <target name="-post-dist">
   3.415 +        <!-- Empty placeholder for easier customization. -->
   3.416 +        <!-- You can override this target in the ../build.xml file. -->
   3.417 +    </target>
   3.418 +    <target name="dist" depends="init,compile,-pre-dist,do-dist,-post-dist" description="Build distribution (WAR)."/>
   3.419 +    <target name="dist-ear" depends="init,compile,-pre-dist,do-ear-dist,-post-dist" description="Build distribution (WAR) to be packaged into an EAR."/>
   3.420 +    <!--
   3.421 +                EXECUTION SECTION
   3.422 +            -->
   3.423 +    <target name="run" depends="run-deploy,run-display-browser" description="Deploy to server and show in browser."/>
   3.424 +    <target name="-pre-run-deploy">
   3.425 +        <!-- Empty placeholder for easier customization. -->
   3.426 +        <!-- You can override this target in the ../build.xml file. -->
   3.427 +    </target>
   3.428 +    <target name="-post-run-deploy">
   3.429 +        <!-- Empty placeholder for easier customization. -->
   3.430 +        <!-- You can override this target in the ../build.xml file. -->
   3.431 +    </target>
   3.432 +    <target name="-pre-nbmodule-run-deploy">
   3.433 +        <!-- Empty placeholder for easier customization. -->
   3.434 +        <!-- This target can be overriden by NetBeans modules. Don't override it directly, use -pre-run-deploy task instead. -->
   3.435 +    </target>
   3.436 +    <target name="-post-nbmodule-run-deploy">
   3.437 +        <!-- Empty placeholder for easier customization. -->
   3.438 +        <!-- This target can be overriden by NetBeans modules. Don't override it directly, use -post-run-deploy task instead. -->
   3.439 +    </target>
   3.440 +    <target name="-run-deploy-am">
   3.441 +        <!-- Task to deploy to the Access Manager runtime. -->
   3.442 +    </target>
   3.443 +    <target name="run-deploy" depends="init,compile,compile-jsps,-do-compile-single-jsp,dist,-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"/>
   3.444 +    <target name="-run-deploy-nb" if="netbeans.home">
   3.445 +        <nbdeploy debugmode="false" clientUrlPart="${client.urlPart}" forceRedeploy="${forceRedeploy}"/>
   3.446 +    </target>
   3.447 +    <target name="-init-deploy-ant" unless="netbeans.home">
   3.448 +        <property name="deploy.ant.archive" value="${dist.war}"/>
   3.449 +        <property name="deploy.ant.docbase.dir" value="${web.docbase.dir}"/>
   3.450 +        <property name="deploy.ant.resource.dir" value="${resource.dir}"/>
   3.451 +        <property name="deploy.ant.enabled" value="true"/>
   3.452 +    </target>
   3.453 +    <target name="run-undeploy" depends="dist,-run-undeploy-nb,-init-deploy-ant,-undeploy-ant"/>
   3.454 +    <target name="-run-undeploy-nb" if="netbeans.home">
   3.455 +        <fail message="Undeploy is not supported from within the IDE"/>
   3.456 +    </target>
   3.457 +    <target name="verify" depends="init,dist">
   3.458 +        <nbverify file="${dist.war}"/>
   3.459 +    </target>
   3.460 +    <target name="run-display-browser" depends="run-deploy,-init-display-browser,-display-browser-nb,-display-browser-cl"/>
   3.461 +    <target name="-init-display-browser" if="do.display.browser">
   3.462 +        <condition property="do.display.browser.nb">
   3.463 +            <isset property="netbeans.home"/>
   3.464 +        </condition>
   3.465 +        <condition property="do.display.browser.cl">
   3.466 +            <isset property="deploy.ant.enabled"/>
   3.467 +        </condition>
   3.468 +    </target>
   3.469 +    <target name="-display-browser-nb" if="do.display.browser.nb">
   3.470 +        <nbbrowse url="${client.url}"/>
   3.471 +    </target>
   3.472 +    <target name="-get-browser" if="do.display.browser.cl" unless="browser">
   3.473 +        <condition property="browser" value="rundll32">
   3.474 +            <os family="windows"/>
   3.475 +        </condition>
   3.476 +        <condition property="browser.args" value="url.dll,FileProtocolHandler" else="">
   3.477 +            <os family="windows"/>
   3.478 +        </condition>
   3.479 +        <condition property="browser" value="/usr/bin/open">
   3.480 +            <os family="mac"/>
   3.481 +        </condition>
   3.482 +        <property environment="env"/>
   3.483 +        <condition property="browser" value="${env.BROWSER}">
   3.484 +            <isset property="env.BROWSER"/>
   3.485 +        </condition>
   3.486 +        <condition property="browser" value="/usr/bin/firefox">
   3.487 +            <available file="/usr/bin/firefox"/>
   3.488 +        </condition>
   3.489 +        <condition property="browser" value="/usr/local/firefox/firefox">
   3.490 +            <available file="/usr/local/firefox/firefox"/>
   3.491 +        </condition>
   3.492 +        <condition property="browser" value="/usr/bin/mozilla">
   3.493 +            <available file="/usr/bin/mozilla"/>
   3.494 +        </condition>
   3.495 +        <condition property="browser" value="/usr/local/mozilla/mozilla">
   3.496 +            <available file="/usr/local/mozilla/mozilla"/>
   3.497 +        </condition>
   3.498 +        <condition property="browser" value="/usr/sfw/lib/firefox/firefox">
   3.499 +            <available file="/usr/sfw/lib/firefox/firefox"/>
   3.500 +        </condition>
   3.501 +        <condition property="browser" value="/opt/csw/bin/firefox">
   3.502 +            <available file="/opt/csw/bin/firefox"/>
   3.503 +        </condition>
   3.504 +        <condition property="browser" value="/usr/sfw/lib/mozilla/mozilla">
   3.505 +            <available file="/usr/sfw/lib/mozilla/mozilla"/>
   3.506 +        </condition>
   3.507 +        <condition property="browser" value="/opt/csw/bin/mozilla">
   3.508 +            <available file="/opt/csw/bin/mozilla"/>
   3.509 +        </condition>
   3.510 +    </target>
   3.511 +    <target name="-display-browser-cl" depends="-get-browser" if="do.display.browser.cl">
   3.512 +        <fail unless="browser">
   3.513 +                    Browser not found, cannot launch the deployed application. Try to set the BROWSER environment variable.
   3.514 +                </fail>
   3.515 +        <property name="browse.url" value="${deploy.ant.client.url}${client.urlPart}"/>
   3.516 +        <echo>Launching ${browse.url}</echo>
   3.517 +        <exec executable="${browser}" spawn="true">
   3.518 +            <arg line="${browser.args} ${browse.url}"/>
   3.519 +        </exec>
   3.520 +    </target>
   3.521 +    <target name="run-main" depends="init,compile-single">
   3.522 +        <fail unless="run.class">Must select one file in the IDE or set run.class</fail>
   3.523 +        <webproject1:java classname="${run.class}"/>
   3.524 +    </target>
   3.525 +    <!--
   3.526 +                DEBUGGING SECTION
   3.527 +            -->
   3.528 +    <target name="debug" description="Debug project in IDE." depends="init,compile,compile-jsps,-do-compile-single-jsp,dist" if="netbeans.home">
   3.529 +        <nbdeploy debugmode="true" clientUrlPart="${client.urlPart}"/>
   3.530 +        <antcall target="connect-debugger"/>
   3.531 +        <antcall target="debug-display-browser"/>
   3.532 +    </target>
   3.533 +    <target name="connect-debugger" unless="is.debugged">
   3.534 +        <nbjpdaconnect name="${name}" host="${jpda.host}" address="${jpda.address}" transport="${jpda.transport}">
   3.535 +            <classpath>
   3.536 +                <path path="${debug.classpath}:${ws.debug.classpaths}"/>
   3.537 +            </classpath>
   3.538 +            <sourcepath>
   3.539 +                <path path="${web.docbase.dir}:${ws.web.docbase.dirs}"/>
   3.540 +            </sourcepath>
   3.541 +        </nbjpdaconnect>
   3.542 +    </target>
   3.543 +    <target name="debug-display-browser" if="do.display.browser">
   3.544 +        <nbbrowse url="${client.url}"/>
   3.545 +    </target>
   3.546 +    <target name="debug-single" if="netbeans.home" depends="init,compile,compile-jsps,-do-compile-single-jsp,debug"/>
   3.547 +    <target name="-debug-start-debugger" if="netbeans.home" depends="init">
   3.548 +        <webproject1:nbjpdastart name="${debug.class}"/>
   3.549 +    </target>
   3.550 +    <target name="-debug-start-debuggee-single" if="netbeans.home" depends="init,compile-single">
   3.551 +        <fail unless="debug.class">Must select one file in the IDE or set debug.class</fail>
   3.552 +        <webproject1:debug classname="${debug.class}"/>
   3.553 +    </target>
   3.554 +    <target name="debug-single-main" if="netbeans.home" depends="init,compile-single,-debug-start-debugger,-debug-start-debuggee-single"/>
   3.555 +    <target name="-pre-debug-fix" depends="init">
   3.556 +        <fail unless="fix.includes">Must set fix.includes</fail>
   3.557 +        <property name="javac.includes" value="${fix.includes}.java"/>
   3.558 +    </target>
   3.559 +    <target name="-do-debug-fix" if="netbeans.home" depends="init,-pre-debug-fix,compile-single">
   3.560 +        <webproject1:nbjpdareload/>
   3.561 +    </target>
   3.562 +    <target name="debug-fix" if="netbeans.home" depends="init,-pre-debug-fix,-do-debug-fix"/>
   3.563 +    <!--
   3.564 +                JAVADOC SECTION
   3.565 +            -->
   3.566 +    <target name="javadoc-build" depends="init">
   3.567 +        <mkdir dir="${dist.javadoc.dir}"/>
   3.568 +        <javadoc destdir="${dist.javadoc.dir}" source="${javac.source}" notree="${javadoc.notree}" use="${javadoc.use}" nonavbar="${javadoc.nonavbar}" noindex="${javadoc.noindex}" splitindex="${javadoc.splitindex}" author="${javadoc.author}" version="${javadoc.version}" windowtitle="${javadoc.windowtitle}" private="${javadoc.private}" additionalparam="${javadoc.additionalparam}" failonerror="true" useexternalfile="true">
   3.569 +            <classpath>
   3.570 +                <path path="${javac.classpath}:${j2ee.platform.classpath}"/>
   3.571 +            </classpath>
   3.572 +            <sourcepath>
   3.573 +                <pathelement location="${src.dir}"/>
   3.574 +            </sourcepath>
   3.575 +            <packageset dir="${src.dir}" includes="*/**"/>
   3.576 +            <fileset dir="${src.dir}" includes="*.java"/>
   3.577 +        </javadoc>
   3.578 +    </target>
   3.579 +    <target name="javadoc-browse" if="netbeans.home" unless="no.javadoc.preview" depends="init,javadoc-build">
   3.580 +        <nbbrowse file="${dist.javadoc.dir}/index.html"/>
   3.581 +    </target>
   3.582 +    <target name="javadoc" depends="init,javadoc-build,javadoc-browse" description="Build Javadoc."/>
   3.583 +    <!--
   3.584 +
   3.585 +                JUNIT COMPILATION SECTION
   3.586 +            -->
   3.587 +    <target name="-pre-pre-compile-test" if="have.tests" depends="init,compile">
   3.588 +        <mkdir dir="${build.test.classes.dir}"/>
   3.589 +    </target>
   3.590 +    <target name="-pre-compile-test">
   3.591 +        <!-- Empty placeholder for easier customization. -->
   3.592 +        <!-- You can override this target in the ../build.xml file. -->
   3.593 +    </target>
   3.594 +    <target name="-do-compile-test" if="have.tests" depends="init,compile,-pre-pre-compile-test,-pre-compile-test">
   3.595 +        <webproject2:javac srcdir="${test.src.dir}" destdir="${build.test.classes.dir}" debug="true" classpath="${javac.test.classpath}:${j2ee.platform.classpath}"/>
   3.596 +        <copy todir="${build.test.classes.dir}">
   3.597 +            <fileset dir="${test.src.dir}" excludes="**/*.java"/>
   3.598 +        </copy>
   3.599 +    </target>
   3.600 +    <target name="-post-compile-test">
   3.601 +        <!-- Empty placeholder for easier customization. -->
   3.602 +        <!-- You can override this target in the ../build.xml file. -->
   3.603 +    </target>
   3.604 +    <target name="compile-test" depends="init,compile,-pre-pre-compile-test,-pre-compile-test,-do-compile-test,-post-compile-test"/>
   3.605 +    <target name="-pre-compile-test-single">
   3.606 +        <!-- Empty placeholder for easier customization. -->
   3.607 +        <!-- You can override this target in the ../build.xml file. -->
   3.608 +    </target>
   3.609 +    <target name="-do-compile-test-single" if="have.tests" depends="init,compile,-pre-pre-compile-test,-pre-compile-test-single">
   3.610 +        <fail unless="javac.includes">Must select some files in the IDE or set javac.includes</fail>
   3.611 +        <webproject2:javac srcdir="${test.src.dir}" destdir="${build.test.classes.dir}" debug="true" classpath="${javac.test.classpath}:${j2ee.platform.classpath}">
   3.612 +            <customize>
   3.613 +                <patternset includes="${javac.includes}"/>
   3.614 +            </customize>
   3.615 +        </webproject2:javac>
   3.616 +        <copy todir="${build.test.classes.dir}">
   3.617 +            <fileset dir="${test.src.dir}" excludes="**/*.java"/>
   3.618 +        </copy>
   3.619 +    </target>
   3.620 +    <target name="-post-compile-test-single">
   3.621 +        <!-- Empty placeholder for easier customization. -->
   3.622 +        <!-- You can override this target in the ../build.xml file. -->
   3.623 +    </target>
   3.624 +    <target name="compile-test-single" depends="init,compile,-pre-pre-compile-test,-pre-compile-test-single,-do-compile-test-single,-post-compile-test-single"/>
   3.625 +    <!--
   3.626 +
   3.627 +                JUNIT EXECUTION SECTION
   3.628 +            -->
   3.629 +    <target name="-pre-test-run" if="have.tests" depends="init">
   3.630 +        <mkdir dir="${build.test.results.dir}"/>
   3.631 +    </target>
   3.632 +    <target name="-do-test-run" if="have.tests" depends="init,compile-test,-pre-test-run">
   3.633 +        <webproject2:junit/>
   3.634 +    </target>
   3.635 +    <target name="-post-test-run" if="have.tests" depends="init,compile-test,-pre-test-run,-do-test-run">
   3.636 +        <fail if="tests.failed">Some tests failed; see details above.</fail>
   3.637 +    </target>
   3.638 +    <target name="test-report" if="have.tests" depends="init"/>
   3.639 +    <target name="-test-browse" if="netbeans.home+have.tests" depends="init"/>
   3.640 +    <target name="test" depends="init,compile-test,-pre-test-run,-do-test-run,test-report,-post-test-run,-test-browse" description="Run unit tests."/>
   3.641 +    <target name="-pre-test-run-single" if="have.tests" depends="init">
   3.642 +        <mkdir dir="${build.test.results.dir}"/>
   3.643 +    </target>
   3.644 +    <target name="-do-test-run-single" if="have.tests" depends="init,compile-test-single,-pre-test-run-single">
   3.645 +        <fail unless="test.includes">Must select some files in the IDE or set test.includes</fail>
   3.646 +        <webproject2:junit includes="${test.includes}"/>
   3.647 +    </target>
   3.648 +    <target name="-post-test-run-single" if="have.tests" depends="init,compile-test-single,-pre-test-run-single,-do-test-run-single">
   3.649 +        <fail if="tests.failed">Some tests failed; see details above.</fail>
   3.650 +    </target>
   3.651 +    <target name="test-single" depends="init,compile-test-single,-pre-test-run-single,-do-test-run-single,-post-test-run-single" description="Run single unit test."/>
   3.652 +    <!--
   3.653 +
   3.654 +                JUNIT DEBUGGING SECTION
   3.655 +            -->
   3.656 +    <target name="-debug-start-debuggee-test" if="have.tests" depends="init,compile-test">
   3.657 +        <fail unless="test.class">Must select one file in the IDE or set test.class</fail>
   3.658 +        <webproject1:debug classname="junit.textui.TestRunner" classpath="${debug.test.classpath}" args="${test.class}"/>
   3.659 +    </target>
   3.660 +    <target name="-debug-start-debugger-test" if="netbeans.home+have.tests" depends="init,compile-test">
   3.661 +        <webproject1:nbjpdastart name="${test.class}" classpath="${debug.test.classpath}"/>
   3.662 +    </target>
   3.663 +    <target name="debug-test" depends="init,compile-test,-debug-start-debugger-test,-debug-start-debuggee-test"/>
   3.664 +    <target name="-do-debug-fix-test" if="netbeans.home" depends="init,-pre-debug-fix,compile-test-single">
   3.665 +        <webproject1:nbjpdareload dir="${build.test.classes.dir}"/>
   3.666 +    </target>
   3.667 +    <target name="debug-fix-test" if="netbeans.home" depends="init,-pre-debug-fix,-do-debug-fix-test"/>
   3.668 +    <!--
   3.669 +
   3.670 +                CLEANUP SECTION
   3.671 +            -->
   3.672 +    <target name="deps-clean" depends="init" if="no.dist.ear.dir" unless="no.deps">
   3.673 +        <ant target="clean" inheritall="false" antfile="${project.org_netbeans_lib_uihandler}/build.xml"/>
   3.674 +    </target>
   3.675 +    <target name="do-clean" depends="init">
   3.676 +        <condition value="${build.web.dir.real}" property="build.dir.to.clean">
   3.677 +            <isset property="dist.ear.dir"/>
   3.678 +        </condition>
   3.679 +        <property value="${build.web.dir.real}" name="build.dir.to.clean"/>
   3.680 +        <delete includeEmptyDirs="true" quiet="true">
   3.681 +            <fileset dir="${build.dir.to.clean}/WEB-INF/lib"/>
   3.682 +        </delete>
   3.683 +        <delete dir="${build.dir}"/>
   3.684 +        <available file="${build.dir.to.clean}/WEB-INF/lib" type="dir" property="status.clean-failed"/>
   3.685 +        <delete dir="${dist.dir}"/>
   3.686 +    </target>
   3.687 +    <target name="check-clean" depends="do-clean" if="status.clean-failed">
   3.688 +        <echo message="Warning: unable to delete some files in ${build.web.dir.real}/WEB-INF/lib - they are probably locked by the J2EE server. "/>
   3.689 +        <echo level="info" message="To delete all files undeploy the module from Server Registry in Runtime tab and then use Clean again."/>
   3.690 +    </target>
   3.691 +    <target name="-post-clean">
   3.692 +        <!-- Empty placeholder for easier customization. -->
   3.693 +        <!-- You can override this target in the ../build.xml file. -->
   3.694 +    </target>
   3.695 +    <target name="clean" depends="init,deps-clean,do-clean,check-clean,-post-clean" description="Clean build products."/>
   3.696 +    <target name="clean-ear" depends="clean" description="Clean build products."/>
   3.697 +</project>
     4.1 --- /dev/null	Thu Jan 01 00:00:00 1970 +0000
     4.2 +++ b/logger/uihandlerserver/nbproject/genfiles.properties	Mon Oct 02 17:00:09 2006 +0000
     4.3 @@ -0,0 +1,8 @@
     4.4 +build.xml.data.CRC32=c60e9b7d
     4.5 +build.xml.script.CRC32=4af66eda
     4.6 +build.xml.stylesheet.CRC32=95be3570
     4.7 +# This file is used by a NetBeans-based IDE to track changes in generated files such as build-impl.xml.
     4.8 +# Do not edit this file. You may delete it but then the IDE will never regenerate such files for you.
     4.9 +nbproject/build-impl.xml.data.CRC32=c60e9b7d
    4.10 +nbproject/build-impl.xml.script.CRC32=8af3f5d3
    4.11 +nbproject/build-impl.xml.stylesheet.CRC32=e0c03a66
     5.1 --- /dev/null	Thu Jan 01 00:00:00 1970 +0000
     5.2 +++ b/logger/uihandlerserver/nbproject/project.properties	Mon Oct 02 17:00:09 2006 +0000
     5.3 @@ -0,0 +1,68 @@
     5.4 +build.classes.dir=${build.web.dir}/WEB-INF/classes
     5.5 +build.classes.excludes=**/*.java,**/*.form
     5.6 +build.dir=build
     5.7 +build.ear.classes.dir=${build.ear.web.dir}/WEB-INF/classes
     5.8 +build.ear.web.dir=${build.dir}/ear-module
     5.9 +build.generated.dir=${build.dir}/generated
    5.10 +build.test.classes.dir=${build.dir}/test/classes
    5.11 +build.test.results.dir=${build.dir}/test/results
    5.12 +build.web.dir=${build.dir}/web
    5.13 +build.web.excludes=${build.classes.excludes}
    5.14 +client.urlPart=
    5.15 +compile.jsps=false
    5.16 +conf.dir=${source.root}/conf
    5.17 +debug.classpath=${javac.classpath}:${build.classes.dir}:${build.ear.classes.dir}
    5.18 +debug.test.classpath=\
    5.19 +    ${run.test.classpath}
    5.20 +display.browser=true
    5.21 +dist.dir=dist
    5.22 +dist.ear.war=${dist.dir}/${war.ear.name}
    5.23 +dist.javadoc.dir=${dist.dir}/javadoc
    5.24 +dist.war=${dist.dir}/${war.name}
    5.25 +j2ee.platform=1.4
    5.26 +j2ee.server.type=Tomcat55
    5.27 +jar.compress=false
    5.28 +javac.classpath=\
    5.29 +    ${reference.org_netbeans_lib_uihandler.module}
    5.30 +# Space-separated list of extra javac options
    5.31 +javac.compilerargs=
    5.32 +javac.debug=true
    5.33 +javac.deprecation=false
    5.34 +javac.source=1.4
    5.35 +javac.target=1.4
    5.36 +javac.test.classpath=\
    5.37 +    ${javac.classpath}:\
    5.38 +    ${build.classes.dir}:\
    5.39 +    ${libs.junit.classpath}
    5.40 +javadoc.additionalparam=
    5.41 +javadoc.author=false
    5.42 +javadoc.encoding=
    5.43 +javadoc.noindex=false
    5.44 +javadoc.nonavbar=false
    5.45 +javadoc.notree=false
    5.46 +javadoc.preview=true
    5.47 +javadoc.private=false
    5.48 +javadoc.splitindex=true
    5.49 +javadoc.use=true
    5.50 +javadoc.version=false
    5.51 +javadoc.windowtitle=
    5.52 +jspcompilation.classpath=${jspc.classpath}:${javac.classpath}
    5.53 +lib.dir=${web.docbase.dir}/WEB-INF/lib
    5.54 +platform.active=default_platform
    5.55 +project.org_netbeans_lib_uihandler=../uihandlerlib
    5.56 +reference.org_netbeans_lib_uihandler.module=${project.org_netbeans_lib_uihandler}/../../nbbuild/netbeans/extra/modules/org-netbeans-lib-uihandler.jar
    5.57 +resource.dir=setup
    5.58 +run.test.classpath=\
    5.59 +    ${javac.test.classpath}:\
    5.60 +    ${build.test.classes.dir}
    5.61 +# Space-separated list of JVM arguments used when running class with main method
    5.62 +# (you may also define separate properties like run-sys-prop.name=value instead of -Dname=value):
    5.63 +runmain.jvmargs=
    5.64 +source.root=src
    5.65 +src.dir=${source.root}/java
    5.66 +test.src.dir=test
    5.67 +war.content.additional=
    5.68 +war.ear.name=uihandlerserver.war
    5.69 +war.name=uihandlerserver.war
    5.70 +war.package=true
    5.71 +web.docbase.dir=web
     6.1 --- /dev/null	Thu Jan 01 00:00:00 1970 +0000
     6.2 +++ b/logger/uihandlerserver/nbproject/project.xml	Mon Oct 02 17:00:09 2006 +0000
     6.3 @@ -0,0 +1,33 @@
     6.4 +<?xml version="1.0" encoding="UTF-8"?>
     6.5 +<project xmlns="http://www.netbeans.org/ns/project/1">
     6.6 +    <type>org.netbeans.modules.web.project</type>
     6.7 +    <configuration>
     6.8 +        <data xmlns="http://www.netbeans.org/ns/web-project/3">
     6.9 +            <name>uihandlerserver</name>
    6.10 +            <minimum-ant-version>1.6</minimum-ant-version>
    6.11 +            <web-module-libraries>
    6.12 +                <library files="1">
    6.13 +                    <file>${reference.org_netbeans_lib_uihandler.module}</file>
    6.14 +                    <path-in-war>WEB-INF/lib</path-in-war>
    6.15 +                </library>
    6.16 +            </web-module-libraries>
    6.17 +            <web-module-additional-libraries/>
    6.18 +            <source-roots>
    6.19 +                <root id="src.dir"/>
    6.20 +            </source-roots>
    6.21 +            <test-roots>
    6.22 +                <root id="test.src.dir"/>
    6.23 +            </test-roots>
    6.24 +        </data>
    6.25 +        <references xmlns="http://www.netbeans.org/ns/ant-project-references/1">
    6.26 +            <reference>
    6.27 +                <foreign-project>org_netbeans_lib_uihandler</foreign-project>
    6.28 +                <artifact-type>jar</artifact-type>
    6.29 +                <script>build.xml</script>
    6.30 +                <target>netbeans</target>
    6.31 +                <clean-target>clean</clean-target>
    6.32 +                <id>module</id>
    6.33 +            </reference>
    6.34 +        </references>
    6.35 +    </configuration>
    6.36 +</project>
     7.1 --- /dev/null	Thu Jan 01 00:00:00 1970 +0000
     7.2 +++ b/logger/uihandlerserver/src/conf/MANIFEST.MF	Mon Oct 02 17:00:09 2006 +0000
     7.3 @@ -0,0 +1,2 @@
     7.4 +Manifest-Version: 1.0
     7.5 +
     8.1 --- /dev/null	Thu Jan 01 00:00:00 1970 +0000
     8.2 +++ b/logger/uihandlerserver/src/java/org/netbeans/server/uihandler/UploadLogs.java	Mon Oct 02 17:00:09 2006 +0000
     8.3 @@ -0,0 +1,236 @@
     8.4 +/*
     8.5 + * The contents of this file are subject to the terms of the Common Development
     8.6 + * and Distribution License (the License). You may not use this file except in
     8.7 + * compliance with the License.
     8.8 + *
     8.9 + * You can obtain a copy of the License at http://www.netbeans.org/cddl.html
    8.10 + * or http://www.netbeans.org/cddl.txt.
    8.11 + *
    8.12 + * When distributing Covered Code, include this CDDL Header Notice in each file
    8.13 + * and include the License file at http://www.netbeans.org/cddl.txt.
    8.14 + * If applicable, add the following below the CDDL Header, with the fields
    8.15 + * enclosed by brackets [] replaced by your own identifying information:
    8.16 + * "Portions Copyrighted [year] [name of copyright owner]"
    8.17 + *
    8.18 + * The Original Software is NetBeans. The Initial Developer of the Original
    8.19 + * Software is Sun Microsystems, Inc. Portions Copyright 1997-2006 Sun
    8.20 + * Microsystems, Inc. All Rights Reserved.
    8.21 + */
    8.22 +
    8.23 +package org.netbeans.server.uihandler;
    8.24 +
    8.25 +import java.io.*;
    8.26 +import java.net.*;
    8.27 +import java.util.Enumeration;
    8.28 +import java.util.logging.Logger;
    8.29 +
    8.30 +import javax.servlet.*;
    8.31 +import javax.servlet.http.*;
    8.32 +import org.netbeans.lib.uihandler.MultiPartHandler;
    8.33 +
    8.34 +/**
    8.35 + *
    8.36 + * @author Jaroslav Tulach
    8.37 + * @version
    8.38 + */
    8.39 +public class UploadLogs extends HttpServlet {
    8.40 +    private static Logger LOG = Logger.getLogger(UploadLogs.class.getName());
    8.41 +    
    8.42 +    /** Processes requests for both HTTP <code>GET</code> and <code>POST</code> methods.
    8.43 +     * @param request servlet request
    8.44 +     * @param response servlet response
    8.45 +     */
    8.46 +    protected void processRequest(HttpServletRequest request, HttpServletResponse response)
    8.47 +    throws ServletException, IOException {
    8.48 +        String uploadDir = request.getParameter("dir"); // NOI18N
    8.49 +//        if (uploadDir == null || uploadDir.length() == 0) {
    8.50 +//            uploadDir = request.getAttribute("dir"); // NOI18N
    8.51 +//        }
    8.52 +        if (uploadDir == null || uploadDir.length() == 0) {
    8.53 +            uploadDir = getInitParameter("dir"); // NOI18N
    8.54 +        }
    8.55 +        if (uploadDir == null) {
    8.56 +            String msg = "UploadServlet.doPost: dir is null."; 
    8.57 +            LOG.warning(msg);
    8.58 +            request.setAttribute("error", msg);
    8.59 +            response.sendRedirect(request.getContextPath() + "/error.jsp");
    8.60 +            return;
    8.61 +        }
    8.62 +        File dir = new File(uploadDir);
    8.63 +        if (!dir.isDirectory() && !dir.mkdirs()) {
    8.64 +            String msg = "UploadServlet.doPost: " + dir + " is not directory: " + dir.isDirectory(); 
    8.65 +            LOG.warning(msg);
    8.66 +            request.setAttribute("error", msg);
    8.67 +            response.sendRedirect(request.getContextPath() + "/error.jsp");
    8.68 +            return;
    8.69 +        }
    8.70 +        
    8.71 +        
    8.72 +        int maxUploadSize = 1024 * 1024;
    8.73 +        {
    8.74 +            String max = getInitParameter("maxSize"); // NOI18N
    8.75 +            if (max != null) {
    8.76 +                maxUploadSize = Integer.valueOf(max).intValue();
    8.77 +            }
    8.78 +        }
    8.79 +        
    8.80 +        
    8.81 +        String contentType = request.getContentType();
    8.82 +        if (contentType.toLowerCase().startsWith("multipart/form-data")) {
    8.83 +            
    8.84 +            RequestFacadeImpl facade = new RequestFacadeImpl(request);
    8.85 +            MultiPartHandler multiReq = new MultiPartHandler(facade, uploadDir, maxUploadSize);
    8.86 +            multiReq.parseMultipartUpload();
    8.87 +
    8.88 +            Enumeration fileEnum = multiReq.getFileNames();     
    8.89 +            String name = (String)fileEnum.nextElement();
    8.90 +            File appFile = multiReq.getFile(name);
    8.91 +            long len = 0;
    8.92 +            if (appFile != null) {
    8.93 +                 len = appFile.length();
    8.94 +            }
    8.95 +            /*
    8.96 +            if (len > 0) {
    8.97 +                dispatchRequest = getDispatchRequest(uploadType, appType, NEXT);
    8.98 +                String filePath = appFile.getAbsolutePath();
    8.99 +                String fileName = getFileName(filePath);
   8.100 +                if (dispatchRequest != null) {
   8.101 +                    if (uploadType.equals(FileUtil.DEPLOY)) {
   8.102 +
   8.103 +                        String listPage = multiReq.getParameter("upload.listPage");
   8.104 +                        req.setAttribute("filePath", filePath);
   8.105 +                        req.setAttribute("fileName", getFileName(filePath));
   8.106 +                        req.setAttribute("uploadedFileName", appFile.getName());
   8.107 +                        req.setAttribute("ctxtRoot", "/"+fileName);
   8.108 +                        if (cancelPage!=null && !cancelPage.equals("")){
   8.109 +                            req.setAttribute("cancelPage", cancelPage);
   8.110 +                        }
   8.111 +                        if (listPage != null && !listPage.equals("")){
   8.112 +                            req.setAttribute("listPage", listPage);
   8.113 +                        }
   8.114 +                        if ("mbean".equals(appType)){
   8.115 +                            if(!testMbeanExist(req, filePath)){
   8.116 +                                dispatchRequest = getDispatchRequest(FileUtil.DEPLOY, appType, CURRENT);
   8.117 +                            }
   8.118 +                        }
   8.119 +                    } else if (uploadType.equals(FileUtil.REDEPLOY)) {
   8.120 +                        if (!redeploy(req, true, filePath)) {
   8.121 +                            dispatchRequest = getDispatchRequest(FileUtil.REDEPLOY, appType, CURRENT);
   8.122 +                        }
   8.123 +                    } else if (uploadType.equals(FileUtil.TRANSFORMATION_RULE)) {
   8.124 +                        if (!addTransformationRule(req, filePath)) {
   8.125 +                            dispatchRequest = getDispatchRequest(FileUtil.TRANSFORMATION_RULE, appType, CURRENT);
   8.126 +                        }
   8.127 +                    }
   8.128 +                }
   8.129 +            } else {
   8.130 +                req.setAttribute("AppType", appType);
   8.131 +                req.setAttribute("ALERT_TYPE","error");
   8.132 +                req.setAttribute("ALERT_SUMMARY", "upload.ErrorUploadingFile");
   8.133 +                req.setAttribute("MBEAN_MESSAGE", "upload.FileToUploadDoesNotExist");
   8.134 +                req.setAttribute("HAS_MBEAN_MESSAGE", "true");
   8.135 +                req.setAttribute("HAS_ERROR_MESSAGE", "true");
   8.136 +                if (cancelPage!=null && !cancelPage.equals("")){
   8.137 +                    req.setAttribute("cancelPage", cancelPage);
   8.138 +                }
   8.139 +                dispatchRequest = getDispatchRequest(uploadType, appType, CURRENT);
   8.140 +            }
   8.141 +             */
   8.142 +        }
   8.143 +        
   8.144 +        /*
   8.145 +        for (int i = 0; i < 10; i++) {
   8.146 +            int r = is.read();
   8.147 +            if (r == -1) {
   8.148 +                out.println();
   8.149 +                break;
   8.150 +            }
   8.151 +            out.print((char)r);
   8.152 +        }
   8.153 +        out.println("<hr>\n");
   8.154 +        /*
   8.155 +        for (Enumeration en = request.getParameterNames(); en.hasMoreElements(); ) {
   8.156 +            String n = (String)en.nextElement();
   8.157 +            out.println("<p>param: " + n);
   8.158 +            String[] values = request.getParameterValues(n);
   8.159 +            for (int i = 0; i < values.length; i++) {
   8.160 +                out.println("<b>" + i + " = " + request.getParameterValues(values[i]) + "</b>");
   8.161 +            }
   8.162 +        }
   8.163 +        out.println("<hr>\n");
   8.164 +        for (Enumeration en = request.getAttributeNames(); en.hasMoreElements(); ) {
   8.165 +            out.println("<p>attr: " + en.nextElement());
   8.166 +        }
   8.167 +        out.println("<hr>\n");
   8.168 +        */
   8.169 +        
   8.170 +        request.setAttribute("redirect",  Boolean.TRUE);
   8.171 +        request.setAttribute("files",  new Integer(dir.list().length));
   8.172 +        request.getRequestDispatcher("/uploaddone.jsp").forward(request, response);
   8.173 +    }
   8.174 +    
   8.175 +    private static final class RequestFacadeImpl implements MultiPartHandler.RequestFacade {
   8.176 +        private final HttpServletRequest request;
   8.177 +        private InputFacadeImpl in;
   8.178 +        
   8.179 +        public RequestFacadeImpl(HttpServletRequest req) {
   8.180 +            this.request = req;
   8.181 +        }
   8.182 +        
   8.183 +        public int getContentLength() {
   8.184 +            return request.getContentLength();
   8.185 +        }
   8.186 +
   8.187 +        public String getContentType() {
   8.188 +            return request.getContentType();
   8.189 +        }
   8.190 +        public MultiPartHandler.InputFacade getInput() throws IOException {
   8.191 +            if (in == null) {
   8.192 +                in = new InputFacadeImpl(request.getInputStream());
   8.193 +            }
   8.194 +            return in;
   8.195 +        }
   8.196 +        
   8.197 +        private static final class InputFacadeImpl implements MultiPartHandler.InputFacade {
   8.198 +            private final ServletInputStream in;
   8.199 +            
   8.200 +            public InputFacadeImpl(ServletInputStream in) {
   8.201 +                this.in = in;
   8.202 +            }
   8.203 +
   8.204 +            public int readLine(byte[] arr, int off, int len) throws IOException {
   8.205 +                return in.readLine(arr, off, len);
   8.206 +            }
   8.207 +
   8.208 +            public InputStream getInputStream() {
   8.209 +                return in;
   8.210 +            }
   8.211 +        }
   8.212 +    }
   8.213 +    
   8.214 +    // <editor-fold defaultstate="collapsed" desc="HttpServlet methods. Click on the + sign on the left to edit the code.">
   8.215 +    /** Handles the HTTP <code>GET</code> method.
   8.216 +     * @param request servlet request
   8.217 +     * @param response servlet response
   8.218 +     */
   8.219 +    protected void doGet(HttpServletRequest request, HttpServletResponse response)
   8.220 +    throws ServletException, IOException {
   8.221 +        processRequest(request, response);
   8.222 +    }
   8.223 +    
   8.224 +    /** Handles the HTTP <code>POST</code> method.
   8.225 +     * @param request servlet request
   8.226 +     * @param response servlet response
   8.227 +     */
   8.228 +    protected void doPost(HttpServletRequest request, HttpServletResponse response)
   8.229 +    throws ServletException, IOException {
   8.230 +        processRequest(request, response);
   8.231 +    }
   8.232 +    
   8.233 +    /** Returns a short description of the servlet.
   8.234 +     */
   8.235 +    public String getServletInfo() {
   8.236 +        return "Uploads Logs Generated By UI Logger - http://logger.netbeans.org/welcome/";
   8.237 +    }
   8.238 +    // </editor-fold>
   8.239 +}
     9.1 --- /dev/null	Thu Jan 01 00:00:00 1970 +0000
     9.2 +++ b/logger/uihandlerserver/web/META-INF/context.xml	Mon Oct 02 17:00:09 2006 +0000
     9.3 @@ -0,0 +1,2 @@
     9.4 +<?xml version="1.0" encoding="UTF-8"?>
     9.5 +<Context path="/uihandlerserver"/>
    10.1 --- /dev/null	Thu Jan 01 00:00:00 1970 +0000
    10.2 +++ b/logger/uihandlerserver/web/WEB-INF/sun-web.xml	Mon Oct 02 17:00:09 2006 +0000
    10.3 @@ -0,0 +1,14 @@
    10.4 +<?xml version="1.0" encoding="UTF-8"?>
    10.5 +<!DOCTYPE sun-web-app PUBLIC "-//Sun Microsystems, Inc.//DTD Application Server 9.0 Servlet 2.5//EN" "http://www.sun.com/software/appserver/dtds/sun-web-app_2_5-0.dtd">
    10.6 +<sun-web-app error-url="">
    10.7 +  <context-root>/uihandlerserver</context-root>
    10.8 +  <class-loader delegate="true"/>
    10.9 +  <jsp-config>
   10.10 +    <property name="classdebuginfo" value="true">
   10.11 +      <description>Enable debug info compilation in the generated servlet class</description>
   10.12 +    </property>
   10.13 +    <property name="mappedfile" value="true">
   10.14 +      <description>Maintain a one-to-one correspondence between static content and the generated servlet class' java code</description>
   10.15 +    </property>
   10.16 +  </jsp-config>
   10.17 +</sun-web-app>
    11.1 --- /dev/null	Thu Jan 01 00:00:00 1970 +0000
    11.2 +++ b/logger/uihandlerserver/web/WEB-INF/web.xml	Mon Oct 02 17:00:09 2006 +0000
    11.3 @@ -0,0 +1,46 @@
    11.4 +<?xml version="1.0" encoding="UTF-8"?>
    11.5 +<web-app version="2.4" xmlns="http://java.sun.com/xml/ns/j2ee" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://java.sun.com/xml/ns/j2ee http://java.sun.com/xml/ns/j2ee/web-app_2_4.xsd">
    11.6 +    <context-param>
    11.7 +        <description>Location of directory where to upload files</description>
    11.8 +        <param-name>dir</param-name>
    11.9 +        <param-value>/tmp</param-value>
   11.10 +    </context-param>
   11.11 +    <servlet>
   11.12 +        <servlet-name>UploadLogs</servlet-name>
   11.13 +        <servlet-class>org.netbeans.server.uihandler.UploadLogs</servlet-class>
   11.14 +        <init-param>
   11.15 +            <description>Directory where to upload the UI log files</description>
   11.16 +            <param-name>dir</param-name>
   11.17 +            <param-value>/tmp</param-value>
   11.18 +        </init-param>
   11.19 +        <init-param>
   11.20 +            <description>Maximal size of one UI log file</description>
   11.21 +            <param-name>maxSize</param-name>
   11.22 +            <param-value>1000000</param-value>
   11.23 +        </init-param>
   11.24 +        </servlet>
   11.25 +    <servlet-mapping>
   11.26 +        <servlet-name>UploadLogs</servlet-name>
   11.27 +        <url-pattern>/servlet/upload</url-pattern>
   11.28 +    </servlet-mapping>
   11.29 +    <session-config>
   11.30 +        <session-timeout>
   11.31 +            30
   11.32 +        </session-timeout>
   11.33 +    </session-config>
   11.34 +    <welcome-file-list>
   11.35 +	<welcome-file>
   11.36 +            index.jsp
   11.37 +        </welcome-file>
   11.38 +    </welcome-file-list>
   11.39 +    <env-entry>
   11.40 +        <description>Location of directory to upload to</description>
   11.41 +        <env-entry-name>dir</env-entry-name>
   11.42 +        <env-entry-type>java.lang.String</env-entry-type>
   11.43 +    </env-entry>
   11.44 +    <env-entry>
   11.45 +        <description>Maximal Size of a File to Accept for Upload</description>
   11.46 +        <env-entry-name>maxSize</env-entry-name>
   11.47 +        <env-entry-type>java.lang.Long</env-entry-type>
   11.48 +    </env-entry>
   11.49 +    </web-app>
    12.1 --- /dev/null	Thu Jan 01 00:00:00 1970 +0000
    12.2 +++ b/logger/uihandlerserver/web/error.jsp	Mon Oct 02 17:00:09 2006 +0000
    12.3 @@ -0,0 +1,36 @@
    12.4 +<%@page contentType="text/html"%>
    12.5 +<%@page pageEncoding="UTF-8"%>
    12.6 +<%--
    12.7 +The taglib directive below imports the JSTL library. If you uncomment it,
    12.8 +you must also add the JSTL library to the project. The Add Library... action
    12.9 +on Libraries node in Projects view can be used to add the JSTL 1.1 library.
   12.10 +--%>
   12.11 +<%--
   12.12 +<%@taglib uri="http://java.sun.com/jsp/jstl/core" prefix="c"%> 
   12.13 +--%>
   12.14 +
   12.15 +<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"
   12.16 +   "http://www.w3.org/TR/html4/loose.dtd">
   12.17 +
   12.18 +<html>
   12.19 +    <head>
   12.20 +        <meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
   12.21 +        <title>JSP Page</title>
   12.22 +    </head>
   12.23 +    <body>
   12.24 +
   12.25 +    <h1>Error Page</h1>
   12.26 +
   12.27 +    <%--
   12.28 +    This example uses JSTL, uncomment the taglib directive above.
   12.29 +    To test, display the page like this: index.jsp?sayHello=true&name=Murphy
   12.30 +    --%>
   12.31 +    <%--
   12.32 +    <c:if test="${param.sayHello}">
   12.33 +        <!-- Let's welcome the user ${param.name} -->
   12.34 +        Hello ${param.name}!
   12.35 +    </c:if>
   12.36 +    --%>
   12.37 +    
   12.38 +    </body>
   12.39 +</html>
    13.1 --- /dev/null	Thu Jan 01 00:00:00 1970 +0000
    13.2 +++ b/logger/uihandlerserver/web/index.jsp	Mon Oct 02 17:00:09 2006 +0000
    13.3 @@ -0,0 +1,41 @@
    13.4 +<%@page contentType="text/html"%>
    13.5 +<%@page pageEncoding="UTF-8"%>
    13.6 +<%--
    13.7 +The taglib directive below imports the JSTL library. If you uncomment it,
    13.8 +you must also add the JSTL library to the project. The Add Library... action
    13.9 +on Libraries node in Projects view can be used to add the JSTL 1.1 library.
   13.10 +--%>
   13.11 +<%--
   13.12 +<%@taglib uri="http://java.sun.com/jsp/jstl/core" prefix="c"%> 
   13.13 +--%>
   13.14 +
   13.15 +<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"
   13.16 +   "http://www.w3.org/TR/html4/loose.dtd">
   13.17 +
   13.18 +<html>
   13.19 +    <head>
   13.20 +        <meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
   13.21 +        <title>JSP Page</title>
   13.22 +    </head>
   13.23 +    <body>
   13.24 +
   13.25 +    <h1>JSP Page</h1>
   13.26 +    
   13.27 +    <form action="upload.jsp" enctype="multipart/form-data" method="post">
   13.28 +        Identity: <input name="id" type="text"/></br>
   13.29 +        Log file: <input name="file" type="file"/></br>
   13.30 +        <input type="submit" value="Get Statistics"/>
   13.31 +    </form>
   13.32 +    <%--
   13.33 +    This example uses JSTL, uncomment the taglib directive above.
   13.34 +    To test, display the page like this: index.jsp?sayHello=true&name=Murphy
   13.35 +    --%>
   13.36 +    <%--
   13.37 +    <c:if test="${param.sayHello}">
   13.38 +        <!-- Let's welcome the user ${param.name} -->
   13.39 +        Hello ${param.name}!
   13.40 +    </c:if>
   13.41 +    --%>
   13.42 +    
   13.43 +    </body>
   13.44 +</html>
    14.1 --- /dev/null	Thu Jan 01 00:00:00 1970 +0000
    14.2 +++ b/logger/uihandlerserver/web/upload.jsp	Mon Oct 02 17:00:09 2006 +0000
    14.3 @@ -0,0 +1,6 @@
    14.4 +<%@page contentType="text/html"%>
    14.5 +<%@page pageEncoding="UTF-8"%>
    14.6 +
    14.7 +<jsp:forward page="servlet/upload">
    14.8 +    <jsp:param name="dir" value="/home/jst/ui/"/>
    14.9 +</jsp:forward>
   14.10 \ No newline at end of file
    15.1 --- /dev/null	Thu Jan 01 00:00:00 1970 +0000
    15.2 +++ b/logger/uihandlerserver/web/uploaddone.jsp	Mon Oct 02 17:00:09 2006 +0000
    15.3 @@ -0,0 +1,28 @@
    15.4 +<%@page contentType="text/html"%>
    15.5 +<%@page pageEncoding="UTF-8"%>
    15.6 +
    15.7 +<head>
    15.8 +    <% 
    15.9 +        Object f = request.getAttribute("files");
   15.10 +        if (f == null) {
   15.11 +            f = request.getParameter("files");
   15.12 +        }
   15.13 +        if (Boolean.TRUE.equals(request.getAttribute("redirect"))) { 
   15.14 +    %>
   15.15 +        <meta 
   15.16 +            http-equiv="Refresh" 
   15.17 +            content="3; URL=<%
   15.18 +                out.print(HttpUtils.getRequestURL(request));
   15.19 +            %>?files=<% 
   15.20 +                out.print(f); 
   15.21 +            %>">
   15.22 +    <% } %>
   15.23 +</head>
   15.24 +
   15.25 +<body>
   15.26 +    
   15.27 +    Thanks for your upload. There is currently:
   15.28 +    <% out.print(f); %> 
   15.29 +    files.
   15.30 +    
   15.31 +</body>
   15.32 \ No newline at end of file