git-svn-id: https://svn.coded.pt/svn/SIPRP@716 bb69d46d-e84e-40c8-a05a-06db0d633741
lxbfYeaa
L Luís = 18 years ago
parent 66b0ee4120
commit ee34a34151

@ -21,15 +21,15 @@
-post-compile-test: called after javac compilation of JUnit tests -post-compile-test: called after javac compilation of JUnit tests
-pre-compile-test-single: called before javac compilation of single JUnit test -pre-compile-test-single: called before javac compilation of single JUnit test
-post-compile-test-single: called after javac compilation of single JUunit test -post-compile-test-single: called after javac compilation of single JUunit test
-pre-dist: called before archive building -pre-dist: called before jar building
-post-dist: called after archive building -post-dist: called after jar building
-post-clean: called after cleaning build products -post-clean: called after cleaning build products
-pre-run-deploy: called before deploying -pre-run-deploy: called before deploying
-post-run-deploy: called after deploying -post-run-deploy: called after deploying
Example of pluging an obfuscator after the compilation could look like Example of pluging an obfuscator after the compilation could look like
<target name="-post-compile"> <target name="post-compile">
<obfuscate> <obfuscate>
<fileset dir="${build.classes.dir}"/> <fileset dir="${build.classes.dir}"/>
</obfuscate> </obfuscate>
@ -45,7 +45,7 @@
init-macrodef-javac: defines macro for javac compilation init-macrodef-javac: defines macro for javac compilation
init-macrodef-junit: defines macro for junit execution init-macrodef-junit: defines macro for junit execution
init-macrodef-debug: defines macro for class debugging init-macrodef-debug: defines macro for class debugging
do-dist: archive building do-dist: jar archive building
run: execution of project run: execution of project
javadoc-build: javadoc generation javadoc-build: javadoc generation

@ -12,7 +12,7 @@
<target name="-deploy-ant" if="deploy.ant.enabled" depends="-init"> <target name="-deploy-ant" if="deploy.ant.enabled" depends="-init">
<echo message="Deploying ${deploy.ant.archive} to ${Context(path)}"/> <echo message="Deploying ${deploy.ant.archive} to ${Context(path)}"/>
<taskdef name="deploy" classname="org.apache.catalina.ant.DeployTask" <taskdef name="deploy" classname="org.apache.catalina.ant.DeployTask"
classpath="${tomcat.home}/lib/catalina-ant.jar"/> classpath="${tomcat.home}/server/lib/catalina-ant.jar"/>
<deploy url="${tomcat.url}/manager" username="${tomcat.username}" <deploy url="${tomcat.url}/manager" username="${tomcat.username}"
password="${tomcat.password}" path="${Context(path)}" password="${tomcat.password}" path="${Context(path)}"
war="${deploy.ant.archive}"/> war="${deploy.ant.archive}"/>
@ -21,7 +21,7 @@
<target name="-undeploy-ant" if="deploy.ant.enabled" depends="-init"> <target name="-undeploy-ant" if="deploy.ant.enabled" depends="-init">
<echo message="Undeploying ${Context(path)}"/> <echo message="Undeploying ${Context(path)}"/>
<taskdef name="undeploy" classname="org.apache.catalina.ant.UndeployTask" <taskdef name="undeploy" classname="org.apache.catalina.ant.UndeployTask"
classpath="${tomcat.home}/lib/catalina-ant.jar"/> classpath="${tomcat.home}/server/lib/catalina-ant.jar"/>
<undeploy url="${tomcat.url}/manager" username="${tomcat.username}" <undeploy url="${tomcat.url}/manager" username="${tomcat.username}"
password="${tomcat.password}" path="${Context(path)}"/> password="${tomcat.password}" path="${Context(path)}"/>
</target> </target>

@ -17,9 +17,9 @@
- cleanup - cleanup
--> -->
<project xmlns:webproject1="http://www.netbeans.org/ns/web-project/1" xmlns:webproject2="http://www.netbeans.org/ns/web-project/2" xmlns:webproject3="http://www.netbeans.org/ns/web-project/3" basedir=".." default="default" name="AnaliseAcidentesTrabalho-impl"> <project name="AnaliseAcidentesTrabalho-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">
<import file="ant-deploy.xml"/> <import file="ant-deploy.xml"/>
<target depends="dist,javadoc" description="Build whole project." name="default"/> <target name="default" depends="dist,javadoc" description="Build whole project."/>
<!-- <!--
INITIALIZATION SECTION INITIALIZATION SECTION
--> -->
@ -27,21 +27,25 @@
<!-- Empty placeholder for easier customization. --> <!-- Empty placeholder for easier customization. -->
<!-- You can override this target in the ../build.xml file. --> <!-- You can override this target in the ../build.xml file. -->
</target> </target>
<target depends="-pre-init" name="-init-private"> <target name="-init-private" depends="-pre-init">
<property file="nbproject/private/private.properties"/> <property file="nbproject/private/private.properties"/>
</target> </target>
<target depends="-pre-init,-init-private" name="-init-user"> <target name="-init-user" depends="-pre-init,-init-private">
<property file="${user.properties.file}"/> <property file="${user.properties.file}"/>
<!-- The two properties below are usually overridden --> <!-- The two properties below are usually overridden -->
<!-- by the active platform. Just a fallback. --> <!-- by the active platform. Just a fallback. -->
<property name="default.javac.source" value="1.4"/> <property name="default.javac.source" value="1.4"/>
<property name="default.javac.target" value="1.4"/> <property name="default.javac.target" value="1.4"/>
</target> </target>
<target depends="-pre-init,-init-private,-init-user" name="-init-project"> <target name="-init-project" depends="-pre-init,-init-private,-init-user">
<property file="nbproject/project.properties"/> <property file="nbproject/project.properties"/>
</target> </target>
<target depends="-pre-init,-init-private,-init-user,-init-project,-init-macrodef-property" if="dist.ear.dir" name="-do-ear-init"/> <target name="-do-ear-init" depends="-pre-init,-init-private,-init-user,-init-project,-init-macrodef-property" if="dist.ear.dir">
<target depends="-pre-init,-init-private,-init-user,-init-project,-init-macrodef-property,-do-ear-init" name="-do-init"> <property value="${build.ear.web.dir}/META-INF" name="build.meta.inf.dir"/>
<property name="build.classes.dir.real" value="${build.ear.classes.dir}"/>
<property name="build.web.dir.real" value="${build.ear.web.dir}"/>
</target>
<target name="-do-init" depends="-pre-init,-init-private,-init-user,-init-project,-init-macrodef-property, -do-ear-init">
<condition property="have.tests"> <condition property="have.tests">
<or> <or>
<available file="${test.src.dir}"/> <available file="${test.src.dir}"/>
@ -82,29 +86,23 @@
<available file="${conf.dir}/MANIFEST.MF" property="has.custom.manifest"/> <available file="${conf.dir}/MANIFEST.MF" property="has.custom.manifest"/>
<available file="${conf.dir}/persistence.xml" property="has.persistence.xml"/> <available file="${conf.dir}/persistence.xml" property="has.persistence.xml"/>
<condition property="do.war.package.with.custom.manifest"> <condition property="do.war.package.with.custom.manifest">
<isset property="has.custom.manifest"/>
</condition>
<condition property="do.war.package.without.custom.manifest">
<not>
<isset property="has.custom.manifest"/>
</not>
</condition>
<condition property="do.tmp.war.package.with.custom.manifest">
<and> <and>
<istrue value="${war.package}"/>
<isset property="has.custom.manifest"/> <isset property="has.custom.manifest"/>
<isfalse value="${directory.deployment.supported}"/>
</and> </and>
</condition> </condition>
<condition property="do.tmp.war.package.without.custom.manifest"> <condition property="do.war.package.without.custom.manifest">
<and> <and>
<istrue value="${war.package}"/>
<not> <not>
<isset property="has.custom.manifest"/> <isset property="has.custom.manifest"/>
</not> </not>
<isfalse value="${directory.deployment.supported}"/>
</and> </and>
</condition> </condition>
<property name="build.meta.inf.dir" value="${build.web.dir}/META-INF"/> <property value="${build.web.dir}/META-INF" name="build.meta.inf.dir"/>
<condition else="" property="application.args.param" value="${application.args}"> <property name="build.classes.dir.real" value="${build.classes.dir}"/>
<property name="build.web.dir.real" value="${build.web.dir}"/>
<condition property="application.args.param" value="${application.args}" else="">
<and> <and>
<isset property="application.args"/> <isset property="application.args"/>
<not> <not>
@ -112,28 +110,12 @@
</not> </not>
</and> </and>
</condition> </condition>
<property name="source.encoding" value="${file.encoding}"/>
<condition property="javadoc.encoding.used" value="${javadoc.encoding}">
<and>
<isset property="javadoc.encoding"/>
<not>
<equals arg1="${javadoc.encoding}" arg2=""/>
</not>
</and>
</condition>
<property name="javadoc.encoding.used" value="${source.encoding}"/>
<condition else="" property="javac.compilerargs.jaxws" value="-Djava.endorsed.dirs='${jaxws.endorsed.dir}'">
<and>
<isset property="jaxws.endorsed.dir"/>
<available file="nbproject/jaxws-build.xml"/>
</and>
</condition>
</target> </target>
<target name="-post-init"> <target name="-post-init">
<!-- Empty placeholder for easier customization. --> <!-- Empty placeholder for easier customization. -->
<!-- You can override this target in the ../build.xml file. --> <!-- You can override this target in the ../build.xml file. -->
</target> </target>
<target depends="-pre-init,-init-private,-init-user,-init-project,-do-init" name="-init-check"> <target name="-init-check" depends="-pre-init,-init-private,-init-user,-init-project,-do-init">
<fail unless="src.dir">Must set src.dir</fail> <fail unless="src.dir">Must set src.dir</fail>
<fail unless="test.src.dir">Must set test.src.dir</fail> <fail unless="test.src.dir">Must set test.src.dir</fail>
<fail unless="build.dir">Must set build.dir</fail> <fail unless="build.dir">Must set build.dir</fail>
@ -158,17 +140,17 @@
</target> </target>
<target name="-init-macrodef-javac"> <target name="-init-macrodef-javac">
<macrodef name="javac" uri="http://www.netbeans.org/ns/web-project/2"> <macrodef name="javac" uri="http://www.netbeans.org/ns/web-project/2">
<attribute default="${src.dir}" name="srcdir"/> <attribute name="srcdir" default="${src.dir}"/>
<attribute default="${build.classes.dir}" name="destdir"/> <attribute name="destdir" default="${build.classes.dir.real}"/>
<attribute default="${javac.classpath}:${j2ee.platform.classpath}" name="classpath"/> <attribute name="classpath" default="${javac.classpath}:${j2ee.platform.classpath}"/>
<attribute default="${javac.debug}" name="debug"/> <attribute name="debug" default="${javac.debug}"/>
<element name="customize" optional="true"/> <element name="customize" optional="true"/>
<sequential> <sequential>
<javac debug="@{debug}" deprecation="${javac.deprecation}" destdir="@{destdir}" encoding="${source.encoding}" includeantruntime="false" source="${javac.source}" srcdir="@{srcdir}" target="${javac.target}"> <javac srcdir="@{srcdir}" destdir="@{destdir}" debug="@{debug}" deprecation="${javac.deprecation}" source="${javac.source}" target="${javac.target}" includeantruntime="false">
<classpath> <classpath>
<path path="@{classpath}"/> <path path="@{classpath}"/>
</classpath> </classpath>
<compilerarg line="${javac.compilerargs} ${javac.compilerargs.jaxws}"/> <compilerarg line="${javac.compilerargs}"/>
<customize/> <customize/>
</javac> </javac>
</sequential> </sequential>
@ -176,18 +158,18 @@
</target> </target>
<target name="-init-macrodef-junit"> <target name="-init-macrodef-junit">
<macrodef name="junit" uri="http://www.netbeans.org/ns/web-project/2"> <macrodef name="junit" uri="http://www.netbeans.org/ns/web-project/2">
<attribute default="**/*Test.java" name="includes"/> <attribute name="includes" default="**/*Test.java"/>
<sequential> <sequential>
<junit dir="${basedir}" errorproperty="tests.failed" failureproperty="tests.failed" fork="true" showoutput="true"> <junit showoutput="true" fork="true" dir="${basedir}" failureproperty="tests.failed" errorproperty="tests.failed">
<batchtest todir="${build.test.results.dir}"> <batchtest todir="${build.test.results.dir}">
<fileset dir="${test.src.dir}" includes="@{includes}"/> <fileset dir="${test.src.dir}" includes="@{includes}"/>
</batchtest> </batchtest>
<classpath> <classpath>
<path path="${run.test.classpath}:${j2ee.platform.classpath}"/> <path path="${run.test.classpath}"/>
</classpath> </classpath>
<syspropertyset> <syspropertyset>
<propertyref prefix="test-sys-prop."/> <propertyref prefix="test-sys-prop."/>
<mapper from="test-sys-prop.*" to="*" type="glob"/> <mapper type="glob" from="test-sys-prop.*" to="*"/>
</syspropertyset> </syspropertyset>
<formatter type="brief" usefile="false"/> <formatter type="brief" usefile="false"/>
<formatter type="xml"/> <formatter type="xml"/>
@ -197,17 +179,17 @@
</target> </target>
<target name="-init-macrodef-java"> <target name="-init-macrodef-java">
<macrodef name="java" uri="http://www.netbeans.org/ns/web-project/1"> <macrodef name="java" uri="http://www.netbeans.org/ns/web-project/1">
<attribute default="${main.class}" name="classname"/> <attribute name="classname" default="${main.class}"/>
<element name="customize" optional="true"/> <element name="customize" optional="true"/>
<sequential> <sequential>
<java classname="@{classname}" fork="true"> <java fork="true" classname="@{classname}">
<jvmarg line="${runmain.jvmargs}"/> <jvmarg line="${runmain.jvmargs}"/>
<classpath> <classpath>
<path path="${debug.classpath}:${j2ee.platform.classpath}"/> <path path="${build.classes.dir.real}:${javac.classpath}:${j2ee.platform.classpath}"/>
</classpath> </classpath>
<syspropertyset> <syspropertyset>
<propertyref prefix="run-sys-prop."/> <propertyref prefix="run-sys-prop."/>
<mapper from="run-sys-prop.*" to="*" type="glob"/> <mapper type="glob" from="run-sys-prop.*" to="*"/>
</syspropertyset> </syspropertyset>
<customize/> <customize/>
</java> </java>
@ -216,10 +198,10 @@
</target> </target>
<target name="-init-macrodef-nbjpda"> <target name="-init-macrodef-nbjpda">
<macrodef name="nbjpdastart" uri="http://www.netbeans.org/ns/web-project/1"> <macrodef name="nbjpdastart" uri="http://www.netbeans.org/ns/web-project/1">
<attribute default="${main.class}" name="name"/> <attribute name="name" default="${main.class}"/>
<attribute default="${debug.classpath}:${j2ee.platform.classpath}" name="classpath"/> <attribute name="classpath" default="${debug.classpath}"/>
<sequential> <sequential>
<nbjpdastart addressproperty="jpda.address" name="@{name}" transport="dt_socket"> <nbjpdastart transport="dt_socket" addressproperty="jpda.address" name="@{name}">
<classpath> <classpath>
<path path="@{classpath}"/> <path path="@{classpath}"/>
</classpath> </classpath>
@ -227,42 +209,24 @@
</sequential> </sequential>
</macrodef> </macrodef>
<macrodef name="nbjpdareload" uri="http://www.netbeans.org/ns/web-project/1"> <macrodef name="nbjpdareload" uri="http://www.netbeans.org/ns/web-project/1">
<attribute default="${build.classes.dir}" name="dir"/> <attribute name="dir" default="${build.classes.dir.real}"/>
<sequential> <sequential>
<nbjpdareload> <nbjpdareload>
<fileset dir="@{dir}" includes="${fix.includes}*.class"/> <fileset includes="${fix.includes}*.class" dir="@{dir}"/>
</nbjpdareload> </nbjpdareload>
</sequential> </sequential>
</macrodef> </macrodef>
<macrodef name="nbjpdaappreloaded" uri="http://www.netbeans.org/ns/web-project/1">
<sequential>
<nbjpdaappreloaded/>
</sequential>
</macrodef>
</target> </target>
<target name="-init-debug-args"> <target name="-init-macrodef-debug">
<property name="version-output" value="java version &quot;${ant.java.version}"/>
<condition property="have-jdk-older-than-1.4">
<or>
<contains string="${version-output}" substring="java version &quot;1.0"/>
<contains string="${version-output}" substring="java version &quot;1.1"/>
<contains string="${version-output}" substring="java version &quot;1.2"/>
<contains string="${version-output}" substring="java version &quot;1.3"/>
</or>
</condition>
<condition else="-Xdebug" property="debug-args-line" value="-Xdebug -Xnoagent -Djava.compiler=none">
<istrue value="${have-jdk-older-than-1.4}"/>
</condition>
</target>
<target depends="-init-debug-args" name="-init-macrodef-debug">
<macrodef name="debug" uri="http://www.netbeans.org/ns/web-project/1"> <macrodef name="debug" uri="http://www.netbeans.org/ns/web-project/1">
<attribute default="${main.class}" name="classname"/> <attribute name="classname" default="${main.class}"/>
<attribute default="${debug.classpath}:${j2ee.platform.classpath}" name="classpath"/> <attribute name="classpath" default="${debug.classpath}"/>
<attribute default="${application.args.param}" name="args"/> <attribute name="args" default="${application.args.param}"/>
<element name="customize" optional="true"/>
<sequential> <sequential>
<java classname="@{classname}" fork="true"> <java fork="true" classname="@{classname}">
<jvmarg line="${debug-args-line}"/> <jvmarg value="-Xdebug"/>
<jvmarg value="-Xnoagent"/>
<jvmarg value="-Djava.compiler=none"/>
<jvmarg value="-Xrunjdwp:transport=dt_socket,address=${jpda.address}"/> <jvmarg value="-Xrunjdwp:transport=dt_socket,address=${jpda.address}"/>
<jvmarg line="${runmain.jvmargs}"/> <jvmarg line="${runmain.jvmargs}"/>
<classpath> <classpath>
@ -270,10 +234,9 @@
</classpath> </classpath>
<syspropertyset> <syspropertyset>
<propertyref prefix="run-sys-prop."/> <propertyref prefix="run-sys-prop."/>
<mapper from="run-sys-prop.*" to="*" type="glob"/> <mapper type="glob" from="run-sys-prop.*" to="*"/>
</syspropertyset> </syspropertyset>
<arg line="@{args}"/> <arg line="@{args}"/>
<customize/>
</java> </java>
</sequential> </sequential>
</macrodef> </macrodef>
@ -283,70 +246,66 @@
<attribute name="file"/> <attribute name="file"/>
<attribute name="propname"/> <attribute name="propname"/>
<sequential> <sequential>
<basename file="@{file}" property="base_@{propname}"/> <basename property="base_@{propname}" file="@{file}"/>
<zipfileset id="tld.files_@{propname}" includes="META-INF/*.tld META-INF/tlds/*.tld" src="@{file}"/> <zipfileset id="tld.files_@{propname}" src="@{file}" includes="META-INF/*.tld META-INF/tlds/*.tld"/>
<pathconvert property="tld.files.path_@{propname}" refid="tld.files_@{propname}"/> <pathconvert property="tld.files.path_@{propname}" refid="tld.files_@{propname}"/>
<condition property="hastlds_@{propname}" value="yes"> <condition value="yes" property="hastlds_@{propname}">
<contains casesensitive="false" string="${tld.files.path_@{propname}}" substring=".tld"/> <contains string="${tld.files.path_@{propname}}" substring=".tld" casesensitive="false"/>
</condition> </condition>
<condition property="copy.to.dir_@{propname}" value="${build.web.dir}/WEB-INF/lib"> <condition value="${build.web.dir.real}/WEB-INF/lib" property="copy.to.dir_@{propname}">
<isset property="hastlds_@{propname}"/> <isset property="hastlds_@{propname}"/>
</condition> </condition>
<condition property="copy.to.dir_@{propname}" value="${dist.ear.dir}"> <condition value="${dist.ear.dir}" property="copy.to.dir_@{propname}">
<not> <not>
<isset property="hastlds_@{propname}"/> <isset property="hastlds_@{propname}"/>
</not> </not>
</condition> </condition>
<copy file="@{file}" todir="${copy.to.dir_@{propname}}"/> <copy file="@{file}" todir="${copy.to.dir_@{propname}}"/>
<condition property="@{propname}" value="${base_@{propname}}"> <condition value="${base_@{propname}}" property="@{propname}">
<not> <not>
<isset property="hastlds_@{propname}"/> <isset property="hastlds_@{propname}"/>
</not> </not>
</condition> </condition>
<condition property="@{propname}" value=""> <condition value="" property="@{propname}">
<isset property="hastlds_@{propname}"/> <isset property="hastlds_@{propname}"/>
</condition> </condition>
</sequential> </sequential>
</macrodef> </macrodef>
</target> </target>
<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-java,-init-macrodef-nbjpda,-init-macrodef-debug,-init-macrodef-copy-ear-war" name="init"/> <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"/>
<!-- <!--
COMPILATION SECTION COMPILATION SECTION
--> -->
<target depends="init" if="no.dist.ear.dir" name="deps-module-jar" unless="no.deps"/> <target name="deps-module-jar" depends="init" if="no.dist.ear.dir" unless="no.deps"/>
<target depends="init" if="dist.ear.dir" name="deps-ear-jar" unless="no.deps"/> <target name="deps-ear-jar" depends="init" if="dist.ear.dir" unless="no.deps"/>
<target depends="init, deps-module-jar, deps-ear-jar" name="deps-jar" unless="no.deps"/> <target name="deps-jar" depends="init, deps-module-jar, deps-ear-jar" unless="no.deps"/>
<target depends="init,deps-jar" name="-pre-pre-compile"> <target name="-pre-pre-compile" depends="init,deps-jar">
<mkdir dir="${build.classes.dir}"/> <mkdir dir="${build.classes.dir.real}"/>
</target> </target>
<target name="-pre-compile"> <target name="-pre-compile">
<!-- Empty placeholder for easier customization. --> <!-- Empty placeholder for easier customization. -->
<!-- You can override this target in the ../build.xml file. --> <!-- You can override this target in the ../build.xml file. -->
</target> </target>
<target name="-copy-webdir"> <target name="-copy-webdir">
<copy todir="${build.web.dir}"> <copy todir="${build.web.dir.real}">
<fileset dir="${web.docbase.dir}" excludes="${build.web.excludes}"/> <fileset excludes="${build.web.excludes}" dir="${web.docbase.dir}"/>
</copy>
<copy todir="${build.web.dir}/WEB-INF">
<fileset dir="${webinf.dir}" excludes="${build.web.excludes}"/>
</copy> </copy>
</target> </target>
<target name="-do-ws-compile"/> <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">
<target depends="init, deps-jar, -pre-pre-compile, -pre-compile, -copy-manifest, -copy-persistence-xml, -copy-webdir, library-inclusion-in-archive,library-inclusion-in-manifest,-do-ws-compile" if="have.sources" name="-do-compile"> <webproject2:javac destdir="${build.classes.dir.real}"/>
<webproject2:javac destdir="${build.classes.dir}"/> <copy todir="${build.classes.dir.real}">
<copy todir="${build.classes.dir}">
<fileset dir="${src.dir}" excludes="${build.classes.excludes}"/> <fileset dir="${src.dir}" excludes="${build.classes.excludes}"/>
</copy> </copy>
</target> </target>
<target if="has.custom.manifest" name="-copy-manifest"> <target name="-copy-manifest" if="has.custom.manifest">
<mkdir dir="${build.meta.inf.dir}"/> <mkdir dir="${build.meta.inf.dir}"/>
<copy todir="${build.meta.inf.dir}"> <copy todir="${build.meta.inf.dir}">
<fileset dir="${conf.dir}" includes="MANIFEST.MF"/> <fileset dir="${conf.dir}" includes="MANIFEST.MF"/>
</copy> </copy>
</target> </target>
<target if="has.persistence.xml" name="-copy-persistence-xml"> <target name="-copy-persistence-xml" if="has.persistence.xml">
<mkdir dir="${build.web.dir}/WEB-INF/classes/META-INF"/> <mkdir dir="${build.web.dir.real}/WEB-INF/classes/META-INF"/>
<copy todir="${build.web.dir}/WEB-INF/classes/META-INF"> <copy todir="${build.web.dir.real}/WEB-INF/classes/META-INF">
<fileset dir="${conf.dir}" includes="persistence.xml"/> <fileset dir="${conf.dir}" includes="persistence.xml"/>
</copy> </copy>
</target> </target>
@ -354,19 +313,19 @@
<!-- Empty placeholder for easier customization. --> <!-- Empty placeholder for easier customization. -->
<!-- You can override this target in the ../build.xml file. --> <!-- You can override this target in the ../build.xml file. -->
</target> </target>
<target depends="init,deps-jar,-pre-pre-compile,-pre-compile,-do-compile,-post-compile" description="Compile project." name="compile"/> <target name="compile" depends="init,deps-jar,-pre-pre-compile,-pre-compile,-do-compile,-post-compile" description="Compile project."/>
<target name="-pre-compile-single"> <target name="-pre-compile-single">
<!-- Empty placeholder for easier customization. --> <!-- Empty placeholder for easier customization. -->
<!-- You can override this target in the ../build.xml file. --> <!-- You can override this target in the ../build.xml file. -->
</target> </target>
<target depends="init,deps-jar,-pre-pre-compile" name="-do-compile-single"> <target name="-do-compile-single" depends="init,deps-jar,-pre-pre-compile">
<fail unless="javac.includes">Must select some files in the IDE or set javac.includes</fail> <fail unless="javac.includes">Must select some files in the IDE or set javac.includes</fail>
<webproject2:javac> <webproject2:javac>
<customize> <customize>
<patternset includes="${javac.includes}"/> <patternset includes="${javac.includes}"/>
</customize> </customize>
</webproject2:javac> </webproject2:javac>
<copy todir="${build.classes.dir}"> <copy todir="${build.classes.dir.real}">
<fileset dir="${src.dir}" excludes="${build.classes.excludes}"/> <fileset dir="${src.dir}" excludes="${build.classes.excludes}"/>
</copy> </copy>
</target> </target>
@ -374,39 +333,35 @@
<!-- Empty placeholder for easier customization. --> <!-- Empty placeholder for easier customization. -->
<!-- You can override this target in the ../build.xml file. --> <!-- You can override this target in the ../build.xml file. -->
</target> </target>
<target depends="init,deps-jar,-pre-pre-compile,-pre-compile-single,-do-compile-single,-post-compile-single" name="compile-single"/> <target name="compile-single" depends="init,deps-jar,-pre-pre-compile,-pre-compile-single,-do-compile-single,-post-compile-single"/>
<target depends="compile" description="Test compile JSP pages to expose compilation errors." if="do.compile.jsps" name="compile-jsps"> <target name="compile-jsps" depends="compile" if="do.compile.jsps" description="Test compile JSP pages to expose compilation errors.">
<mkdir dir="${build.generated.dir}/src"/> <mkdir dir="${build.generated.dir}/src"/>
<java classname="org.netbeans.modules.web.project.ant.JspC" failonerror="true" fork="true"> <java classname="org.netbeans.modules.web.project.ant.JspC" fork="true" failonerror="true">
<arg value="-uriroot"/> <arg value="-uriroot"/>
<arg file="${basedir}/${build.web.dir}"/> <arg file="${basedir}/${build.web.dir.real}"/>
<arg value="-d"/> <arg value="-d"/>
<arg file="${basedir}/${build.generated.dir}/src"/> <arg file="${basedir}/${build.generated.dir}/src"/>
<arg value="-die1"/> <arg value="-die1"/>
<arg value="-compilerSourceVM ${javac.source}"/>
<arg value="-compilerTargetVM ${javac.target}"/>
<classpath path="${java.home}/../lib/tools.jar:${copyfiles.classpath}:${jspcompilation.classpath}"/> <classpath path="${java.home}/../lib/tools.jar:${copyfiles.classpath}:${jspcompilation.classpath}"/>
</java> </java>
<mkdir dir="${build.generated.dir}/classes"/> <mkdir dir="${build.generated.dir}/classes"/>
<webproject2:javac classpath="${j2ee.platform.classpath}:${build.classes.dir}:${jspcompilation.classpath}" destdir="${build.generated.dir}/classes" srcdir="${build.generated.dir}/src"/> <webproject2:javac srcdir="${build.generated.dir}/src" destdir="${build.generated.dir}/classes" classpath="${j2ee.platform.classpath}:${build.classes.dir.real}:${jspcompilation.classpath}"/>
</target> </target>
<target depends="compile" if="jsp.includes" name="-do-compile-single-jsp"> <target name="-do-compile-single-jsp" depends="compile" if="jsp.includes">
<fail unless="javac.jsp.includes">Must select some files in the IDE or set javac.jsp.includes</fail> <fail unless="javac.jsp.includes">Must select some files in the IDE or set javac.jsp.includes</fail>
<mkdir dir="${build.generated.dir}/src"/> <mkdir dir="${build.generated.dir}/src"/>
<java classname="org.netbeans.modules.web.project.ant.JspCSingle" failonerror="true" fork="true"> <java classname="org.netbeans.modules.web.project.ant.JspCSingle" fork="true" failonerror="true">
<arg value="-uriroot"/> <arg value="-uriroot"/>
<arg file="${basedir}/${build.web.dir}"/> <arg file="${basedir}/${build.web.dir.real}"/>
<arg value="-d"/> <arg value="-d"/>
<arg file="${basedir}/${build.generated.dir}/src"/> <arg file="${basedir}/${build.generated.dir}/src"/>
<arg value="-die1"/> <arg value="-die1"/>
<arg value="-jspc.files"/> <arg value="-jspc.files"/>
<arg path="${jsp.includes}"/> <arg path="${jsp.includes}"/>
<arg value="-compilerSourceVM ${javac.source}"/>
<arg value="-compilerTargetVM ${javac.target}"/>
<classpath path="${java.home}/../lib/tools.jar:${copyfiles.classpath}:${jspcompilation.classpath}"/> <classpath path="${java.home}/../lib/tools.jar:${copyfiles.classpath}:${jspcompilation.classpath}"/>
</java> </java>
<mkdir dir="${build.generated.dir}/classes"/> <mkdir dir="${build.generated.dir}/classes"/>
<webproject2:javac classpath="${j2ee.platform.classpath}:${build.classes.dir}:${jspcompilation.classpath}" destdir="${build.generated.dir}/classes" srcdir="${build.generated.dir}/src"> <webproject2:javac srcdir="${build.generated.dir}/src" destdir="${build.generated.dir}/classes" classpath="${j2ee.platform.classpath}:${build.classes.dir.real}:${jspcompilation.classpath}">
<customize> <customize>
<patternset includes="${javac.jsp.includes}"/> <patternset includes="${javac.jsp.includes}"/>
</customize> </customize>
@ -423,146 +378,144 @@
<!-- Empty placeholder for easier customization. --> <!-- Empty placeholder for easier customization. -->
<!-- You can override this target in the ../build.xml file. --> <!-- You can override this target in the ../build.xml file. -->
</target> </target>
<target depends="init,compile,compile-jsps,-pre-dist" if="do.war.package.without.custom.manifest" name="-do-dist-without-manifest"> <target name="-do-dist-without-manifest" if="do.war.package.without.custom.manifest" depends="init,compile,compile-jsps,-pre-dist">
<dirname file="${dist.war}" property="dist.jar.dir"/> <dirname property="dist.jar.dir" file="${dist.war}"/>
<mkdir dir="${dist.jar.dir}"/>
<jar compress="${jar.compress}" jarfile="${dist.war}">
<fileset dir="${build.web.dir}"/>
</jar>
</target>
<target depends="init,compile,compile-jsps,-pre-dist" if="do.war.package.with.custom.manifest" name="-do-dist-with-manifest">
<dirname file="${dist.war}" property="dist.jar.dir"/>
<mkdir dir="${dist.jar.dir}"/>
<jar compress="${jar.compress}" jarfile="${dist.war}" manifest="${build.meta.inf.dir}/MANIFEST.MF">
<fileset dir="${build.web.dir}"/>
</jar>
</target>
<target depends="init,compile,compile-jsps,-pre-dist" if="do.tmp.war.package.without.custom.manifest" name="-do-tmp-dist-without-manifest">
<dirname file="${dist.war}" property="dist.jar.dir"/>
<mkdir dir="${dist.jar.dir}"/> <mkdir dir="${dist.jar.dir}"/>
<jar compress="${jar.compress}" jarfile="${dist.war}"> <jar jarfile="${dist.war}" compress="${jar.compress}">
<fileset dir="${build.web.dir}"/> <fileset dir="${build.web.dir.real}"/>
</jar> </jar>
</target> </target>
<target depends="init,compile,compile-jsps,-pre-dist" if="do.tmp.war.package.with.custom.manifest" name="-do-tmp-dist-with-manifest"> <target name="-do-dist-with-manifest" if="do.war.package.with.custom.manifest" depends="init,compile,compile-jsps,-pre-dist">
<dirname file="${dist.war}" property="dist.jar.dir"/> <dirname property="dist.jar.dir" file="${dist.war}"/>
<mkdir dir="${dist.jar.dir}"/> <mkdir dir="${dist.jar.dir}"/>
<jar compress="${jar.compress}" jarfile="${dist.war}" manifest="${build.meta.inf.dir}/MANIFEST.MF"> <jar manifest="${build.meta.inf.dir}/MANIFEST.MF" jarfile="${dist.war}" compress="${jar.compress}">
<fileset dir="${build.web.dir}"/> <fileset dir="${build.web.dir.real}"/>
</jar> </jar>
</target> </target>
<target depends="init,compile,compile-jsps,-pre-dist,-do-dist-with-manifest,-do-dist-without-manifest" name="do-dist"/> <target name="do-dist" depends="init,compile,compile-jsps,-pre-dist,-do-dist-with-manifest,-do-dist-without-manifest"/>
<target depends="init" if="dist.ear.dir" name="library-inclusion-in-manifest"> <target name="library-inclusion-in-manifest" depends="init" if="dist.ear.dir">
<basename file="${libs.jsf-designtime.classpath.libfile.2}" property="included.lib.libs.jsf-designtime.classpath.2"/> <basename property="included.lib.libs.jsf-designtime.classpath.2" file="${libs.jsf-designtime.classpath.libfile.2}"/>
<basename file="${libs.jsf-designtime.classpath.libfile.1}" property="included.lib.libs.jsf-designtime.classpath.1"/> <basename property="included.lib.libs.jsf-designtime.classpath.1" file="${libs.jsf-designtime.classpath.libfile.1}"/>
<copy-ear-war file="${libs.jsf-designtime.classpath.libfile.2}" propname="included.lib.libs.jsf-designtime.classpath.2.X"/> <copy-ear-war file="${libs.jsf-designtime.classpath.libfile.2}" propname="included.lib.libs.jsf-designtime.classpath.2.X"/>
<copy-ear-war file="${libs.jsf-designtime.classpath.libfile.1}" propname="included.lib.libs.jsf-designtime.classpath.1.X"/> <copy-ear-war file="${libs.jsf-designtime.classpath.libfile.1}" propname="included.lib.libs.jsf-designtime.classpath.1.X"/>
<basename file="${libs.jsfsupport-designtime.classpath.libfile.4}" property="included.lib.libs.jsfsupport-designtime.classpath.4"/> <basename property="included.lib.libs.jsfsupport-designtime.classpath.3" file="${libs.jsfsupport-designtime.classpath.libfile.3}"/>
<basename file="${libs.jsfsupport-designtime.classpath.libfile.3}" property="included.lib.libs.jsfsupport-designtime.classpath.3"/> <basename property="included.lib.libs.jsfsupport-designtime.classpath.2" file="${libs.jsfsupport-designtime.classpath.libfile.2}"/>
<basename file="${libs.jsfsupport-designtime.classpath.libfile.2}" property="included.lib.libs.jsfsupport-designtime.classpath.2"/> <basename property="included.lib.libs.jsfsupport-designtime.classpath.1" file="${libs.jsfsupport-designtime.classpath.libfile.1}"/>
<basename file="${libs.jsfsupport-designtime.classpath.libfile.1}" property="included.lib.libs.jsfsupport-designtime.classpath.1"/>
<copy-ear-war file="${libs.jsfsupport-designtime.classpath.libfile.4}" propname="included.lib.libs.jsfsupport-designtime.classpath.4.X"/>
<copy-ear-war file="${libs.jsfsupport-designtime.classpath.libfile.3}" propname="included.lib.libs.jsfsupport-designtime.classpath.3.X"/> <copy-ear-war file="${libs.jsfsupport-designtime.classpath.libfile.3}" propname="included.lib.libs.jsfsupport-designtime.classpath.3.X"/>
<copy-ear-war file="${libs.jsfsupport-designtime.classpath.libfile.2}" propname="included.lib.libs.jsfsupport-designtime.classpath.2.X"/> <copy-ear-war file="${libs.jsfsupport-designtime.classpath.libfile.2}" propname="included.lib.libs.jsfsupport-designtime.classpath.2.X"/>
<copy-ear-war file="${libs.jsfsupport-designtime.classpath.libfile.1}" propname="included.lib.libs.jsfsupport-designtime.classpath.1.X"/> <copy-ear-war file="${libs.jsfsupport-designtime.classpath.libfile.1}" propname="included.lib.libs.jsfsupport-designtime.classpath.1.X"/>
<basename file="${libs.webui-designtime.classpath.libfile.2}" property="included.lib.libs.webui-designtime.classpath.2"/> <basename property="included.lib.libs.webui-designtime.classpath.2" file="${libs.webui-designtime.classpath.libfile.2}"/>
<basename file="${libs.webui-designtime.classpath.libfile.1}" property="included.lib.libs.webui-designtime.classpath.1"/> <basename property="included.lib.libs.webui-designtime.classpath.1" file="${libs.webui-designtime.classpath.libfile.1}"/>
<copy-ear-war file="${libs.webui-designtime.classpath.libfile.2}" propname="included.lib.libs.webui-designtime.classpath.2.X"/> <copy-ear-war file="${libs.webui-designtime.classpath.libfile.2}" propname="included.lib.libs.webui-designtime.classpath.2.X"/>
<copy-ear-war file="${libs.webui-designtime.classpath.libfile.1}" propname="included.lib.libs.webui-designtime.classpath.1.X"/> <copy-ear-war file="${libs.webui-designtime.classpath.libfile.1}" propname="included.lib.libs.webui-designtime.classpath.1.X"/>
<basename file="${libs.jdbcsupport-designtime.classpath}" property="included.lib.libs.jdbcsupport-designtime.classpath"/> <basename property="included.lib.libs.jdbcsupport-designtime.classpath.2" file="${libs.jdbcsupport-designtime.classpath.libfile.2}"/>
<copy-ear-war file="${libs.jdbcsupport-designtime.classpath}" propname="included.lib.libs.jdbcsupport-designtime.classpath.X"/> <basename property="included.lib.libs.jdbcsupport-designtime.classpath.1" file="${libs.jdbcsupport-designtime.classpath.libfile.1}"/>
<basename file="${libs.theme-default.classpath}" property="included.lib.libs.theme-default.classpath"/> <copy-ear-war file="${libs.jdbcsupport-designtime.classpath.libfile.2}" propname="included.lib.libs.jdbcsupport-designtime.classpath.2.X"/>
<copy-ear-war file="${libs.jdbcsupport-designtime.classpath.libfile.1}" propname="included.lib.libs.jdbcsupport-designtime.classpath.1.X"/>
<basename property="included.lib.libs.theme-default.classpath" file="${libs.theme-default.classpath}"/>
<copy-ear-war file="${libs.theme-default.classpath}" propname="included.lib.libs.theme-default.classpath.X"/> <copy-ear-war file="${libs.theme-default.classpath}" propname="included.lib.libs.theme-default.classpath.X"/>
<basename file="${libs.jstl11.classpath.libfile.2}" property="included.lib.libs.jstl11.classpath.2"/> <basename property="included.lib.libs.jstl11.classpath.2" file="${libs.jstl11.classpath.libfile.2}"/>
<basename file="${libs.jstl11.classpath.libfile.1}" property="included.lib.libs.jstl11.classpath.1"/> <basename property="included.lib.libs.jstl11.classpath.1" file="${libs.jstl11.classpath.libfile.1}"/>
<copy-ear-war file="${libs.jstl11.classpath.libfile.2}" propname="included.lib.libs.jstl11.classpath.2.X"/> <copy-ear-war file="${libs.jstl11.classpath.libfile.2}" propname="included.lib.libs.jstl11.classpath.2.X"/>
<copy-ear-war file="${libs.jstl11.classpath.libfile.1}" propname="included.lib.libs.jstl11.classpath.1.X"/> <copy-ear-war file="${libs.jstl11.classpath.libfile.1}" propname="included.lib.libs.jstl11.classpath.1.X"/>
<basename file="${file.reference.activation.jar}" property="included.lib.file.reference.activation.jar"/> <basename property="included.lib.file.reference.activation.jar" file="${file.reference.activation.jar}"/>
<copy-ear-war file="${file.reference.activation.jar}" propname="included.lib.file.reference.activation.jar.X"/> <copy-ear-war file="${file.reference.activation.jar}" propname="included.lib.file.reference.activation.jar.X"/>
<basename file="${file.reference.mail.jar}" property="included.lib.file.reference.mail.jar"/> <basename property="included.lib.file.reference.mail.jar" file="${file.reference.mail.jar}"/>
<copy-ear-war file="${file.reference.mail.jar}" propname="included.lib.file.reference.mail.jar.X"/> <copy-ear-war file="${file.reference.mail.jar}" propname="included.lib.file.reference.mail.jar.X"/>
<basename file="${file.reference.postgresql-8.2-506.jdbc4.jar}" property="included.lib.file.reference.postgresql-8.2-506.jdbc4.jar"/> <basename property="included.lib.file.reference.postgresql-8.2-506.jdbc4.jar" file="${file.reference.postgresql-8.2-506.jdbc4.jar}"/>
<copy-ear-war file="${file.reference.postgresql-8.2-506.jdbc4.jar}" propname="included.lib.file.reference.postgresql-8.2-506.jdbc4.jar.X"/> <copy-ear-war file="${file.reference.postgresql-8.2-506.jdbc4.jar}" propname="included.lib.file.reference.postgresql-8.2-506.jdbc4.jar.X"/>
<basename file="${libs.rowset-ri.classpath}" property="included.lib.libs.rowset-ri.classpath"/> <basename property="included.lib.file.reference.iText-2.0.8.jar" file="${file.reference.iText-2.0.8.jar}"/>
<copy-ear-war file="${libs.rowset-ri.classpath}" propname="included.lib.libs.rowset-ri.classpath.X"/>
<basename file="${file.reference.iText-2.0.8.jar}" property="included.lib.file.reference.iText-2.0.8.jar"/>
<copy-ear-war file="${file.reference.iText-2.0.8.jar}" propname="included.lib.file.reference.iText-2.0.8.jar.X"/> <copy-ear-war file="${file.reference.iText-2.0.8.jar}" propname="included.lib.file.reference.iText-2.0.8.jar.X"/>
<copy file="${libs.jsf-runtime.classpath.libfile.6}" todir="${build.web.dir}/WEB-INF/lib"/> <basename property="included.lib.file.reference.evolute.jar" file="${file.reference.evolute.jar}"/>
<copy file="${libs.jsf-runtime.classpath.libfile.5}" todir="${build.web.dir}/WEB-INF/lib"/> <copy-ear-war file="${file.reference.evolute.jar}" propname="included.lib.file.reference.evolute.jar.X"/>
<copy file="${libs.jsf-runtime.classpath.libfile.4}" todir="${build.web.dir}/WEB-INF/lib"/> <basename property="included.lib.file.reference.fop.jar" file="${file.reference.fop.jar}"/>
<copy file="${libs.jsf-runtime.classpath.libfile.3}" todir="${build.web.dir}/WEB-INF/lib"/> <copy-ear-war file="${file.reference.fop.jar}" propname="included.lib.file.reference.fop.jar.X"/>
<copy file="${libs.jsf-runtime.classpath.libfile.2}" todir="${build.web.dir}/WEB-INF/lib"/> <basename property="included.lib.file.reference.jdom.jar" file="${file.reference.jdom.jar}"/>
<copy file="${libs.jsf-runtime.classpath.libfile.1}" todir="${build.web.dir}/WEB-INF/lib"/> <copy-ear-war file="${file.reference.jdom.jar}" propname="included.lib.file.reference.jdom.jar.X"/>
<copy file="${libs.jsfsupport-runtime.classpath.libfile.4}" todir="${build.web.dir}/WEB-INF/lib"/> <basename property="included.lib.file.reference.avalon-framework-4.2.0.jar" file="${file.reference.avalon-framework-4.2.0.jar}"/>
<copy file="${libs.jsfsupport-runtime.classpath.libfile.3}" todir="${build.web.dir}/WEB-INF/lib"/> <copy-ear-war file="${file.reference.avalon-framework-4.2.0.jar}" propname="included.lib.file.reference.avalon-framework-4.2.0.jar.X"/>
<copy file="${libs.jsfsupport-runtime.classpath.libfile.2}" todir="${build.web.dir}/WEB-INF/lib"/> <basename property="included.lib.file.reference.batik.jar" file="${file.reference.batik.jar}"/>
<copy file="${libs.jsfsupport-runtime.classpath.libfile.1}" todir="${build.web.dir}/WEB-INF/lib"/> <copy-ear-war file="${file.reference.batik.jar}" propname="included.lib.file.reference.batik.jar.X"/>
<copy file="${libs.webui-runtime.classpath.libfile.2}" todir="${build.web.dir}/WEB-INF/lib"/> <copy file="${libs.jsf-runtime.classpath.libfile.6}" todir="${build.web.dir.real}/WEB-INF/lib"/>
<copy file="${libs.webui-runtime.classpath.libfile.1}" todir="${build.web.dir}/WEB-INF/lib"/> <copy file="${libs.jsf-runtime.classpath.libfile.5}" todir="${build.web.dir.real}/WEB-INF/lib"/>
<copy file="${libs.jdbcsupport-runtime.classpath}" todir="${build.web.dir}/WEB-INF/lib"/> <copy file="${libs.jsf-runtime.classpath.libfile.4}" todir="${build.web.dir.real}/WEB-INF/lib"/>
<copy file="${libs.exceptionhandler-runtime.classpath}" todir="${build.web.dir}/WEB-INF/lib"/> <copy file="${libs.jsf-runtime.classpath.libfile.3}" todir="${build.web.dir.real}/WEB-INF/lib"/>
<copy file="${libs.theme-default.classpath}" todir="${build.web.dir}/WEB-INF/lib"/> <copy file="${libs.jsf-runtime.classpath.libfile.2}" todir="${build.web.dir.real}/WEB-INF/lib"/>
<copy file="${libs.jstl11.classpath.libfile.2}" todir="${build.web.dir}/WEB-INF/lib"/> <copy file="${libs.jsf-runtime.classpath.libfile.1}" todir="${build.web.dir.real}/WEB-INF/lib"/>
<copy file="${libs.jstl11.classpath.libfile.1}" todir="${build.web.dir}/WEB-INF/lib"/> <copy file="${libs.jsfsupport-runtime.classpath.libfile.3}" todir="${build.web.dir.real}/WEB-INF/lib"/>
<mkdir dir="${build.web.dir}/META-INF"/> <copy file="${libs.jsfsupport-runtime.classpath.libfile.2}" todir="${build.web.dir.real}/WEB-INF/lib"/>
<manifest file="${build.web.dir}/META-INF/MANIFEST.MF" mode="update"> <copy file="${libs.jsfsupport-runtime.classpath.libfile.1}" todir="${build.web.dir.real}/WEB-INF/lib"/>
<attribute name="Class-Path" value="${included.lib.libs.jsf-designtime.classpath.1.X} ${included.lib.libs.jsf-designtime.classpath.2.X} ${included.lib.libs.jsfsupport-designtime.classpath.1.X} ${included.lib.libs.jsfsupport-designtime.classpath.2.X} ${included.lib.libs.jsfsupport-designtime.classpath.3.X} ${included.lib.libs.jsfsupport-designtime.classpath.4.X} ${included.lib.libs.webui-designtime.classpath.1.X} ${included.lib.libs.webui-designtime.classpath.2.X} ${included.lib.libs.jdbcsupport-designtime.classpath} ${included.lib.libs.theme-default.classpath} ${included.lib.libs.jstl11.classpath.1.X} ${included.lib.libs.jstl11.classpath.2.X} ${included.lib.file.reference.activation.jar} ${included.lib.file.reference.mail.jar} ${included.lib.file.reference.postgresql-8.2-506.jdbc4.jar} ${included.lib.libs.rowset-ri.classpath} ${included.lib.file.reference.iText-2.0.8.jar} "/> <copy file="${libs.webui-runtime.classpath.libfile.2}" todir="${build.web.dir.real}/WEB-INF/lib"/>
<copy file="${libs.webui-runtime.classpath.libfile.1}" todir="${build.web.dir.real}/WEB-INF/lib"/>
<copy file="${libs.jdbcsupport-runtime.classpath.libfile.2}" todir="${build.web.dir.real}/WEB-INF/lib"/>
<copy file="${libs.jdbcsupport-runtime.classpath.libfile.1}" todir="${build.web.dir.real}/WEB-INF/lib"/>
<copy file="${libs.exceptionhandler-runtime.classpath}" todir="${build.web.dir.real}/WEB-INF/lib"/>
<copy file="${libs.theme-default.classpath}" todir="${build.web.dir.real}/WEB-INF/lib"/>
<copy file="${libs.jstl11.classpath.libfile.2}" todir="${build.web.dir.real}/WEB-INF/lib"/>
<copy file="${libs.jstl11.classpath.libfile.1}" todir="${build.web.dir.real}/WEB-INF/lib"/>
<mkdir dir="${build.web.dir.real}/META-INF"/>
<manifest file="${build.web.dir.real}/META-INF/MANIFEST.MF" mode="update">
<attribute name="Class-Path" value="${included.lib.libs.jsf-designtime.classpath.1.X} ${included.lib.libs.jsf-designtime.classpath.2.X} ${included.lib.libs.jsfsupport-designtime.classpath.1.X} ${included.lib.libs.jsfsupport-designtime.classpath.2.X} ${included.lib.libs.jsfsupport-designtime.classpath.3.X} ${included.lib.libs.webui-designtime.classpath.1.X} ${included.lib.libs.webui-designtime.classpath.2.X} ${included.lib.libs.jdbcsupport-designtime.classpath.1.X} ${included.lib.libs.jdbcsupport-designtime.classpath.2.X} ${included.lib.libs.theme-default.classpath} ${included.lib.libs.jstl11.classpath.1.X} ${included.lib.libs.jstl11.classpath.2.X} ${included.lib.file.reference.activation.jar} ${included.lib.file.reference.mail.jar} ${included.lib.file.reference.postgresql-8.2-506.jdbc4.jar} ${included.lib.file.reference.iText-2.0.8.jar} ${included.lib.file.reference.evolute.jar} ${included.lib.file.reference.fop.jar} ${included.lib.file.reference.jdom.jar} ${included.lib.file.reference.avalon-framework-4.2.0.jar} ${included.lib.file.reference.batik.jar} "/>
</manifest> </manifest>
<delete dir="${dist.ear.dir}/temp"/> <delete dir="${dist.ear.dir}/temp"/>
</target> </target>
<target depends="init" name="library-inclusion-in-archive" unless="dist.ear.dir"> <target name="library-inclusion-in-archive" depends="init" unless="dist.ear.dir">
<copy file="${libs.jsf-designtime.classpath.libfile.2}" todir="${build.web.dir}/WEB-INF/lib"/> <copy file="${libs.jsf-designtime.classpath.libfile.2}" todir="${build.web.dir.real}/WEB-INF/lib"/>
<copy file="${libs.jsf-designtime.classpath.libfile.1}" todir="${build.web.dir}/WEB-INF/lib"/> <copy file="${libs.jsf-designtime.classpath.libfile.1}" todir="${build.web.dir.real}/WEB-INF/lib"/>
<copy file="${libs.jsfsupport-designtime.classpath.libfile.4}" todir="${build.web.dir}/WEB-INF/lib"/> <copy file="${libs.jsfsupport-designtime.classpath.libfile.3}" todir="${build.web.dir.real}/WEB-INF/lib"/>
<copy file="${libs.jsfsupport-designtime.classpath.libfile.3}" todir="${build.web.dir}/WEB-INF/lib"/> <copy file="${libs.jsfsupport-designtime.classpath.libfile.2}" todir="${build.web.dir.real}/WEB-INF/lib"/>
<copy file="${libs.jsfsupport-designtime.classpath.libfile.2}" todir="${build.web.dir}/WEB-INF/lib"/> <copy file="${libs.jsfsupport-designtime.classpath.libfile.1}" todir="${build.web.dir.real}/WEB-INF/lib"/>
<copy file="${libs.jsfsupport-designtime.classpath.libfile.1}" todir="${build.web.dir}/WEB-INF/lib"/> <copy file="${libs.webui-designtime.classpath.libfile.2}" todir="${build.web.dir.real}/WEB-INF/lib"/>
<copy file="${libs.webui-designtime.classpath.libfile.2}" todir="${build.web.dir}/WEB-INF/lib"/> <copy file="${libs.webui-designtime.classpath.libfile.1}" todir="${build.web.dir.real}/WEB-INF/lib"/>
<copy file="${libs.webui-designtime.classpath.libfile.1}" todir="${build.web.dir}/WEB-INF/lib"/> <copy file="${libs.jdbcsupport-designtime.classpath.libfile.2}" todir="${build.web.dir.real}/WEB-INF/lib"/>
<copy file="${libs.jdbcsupport-designtime.classpath}" todir="${build.web.dir}/WEB-INF/lib"/> <copy file="${libs.jdbcsupport-designtime.classpath.libfile.1}" todir="${build.web.dir.real}/WEB-INF/lib"/>
<copy file="${libs.theme-default.classpath}" todir="${build.web.dir}/WEB-INF/lib"/> <copy file="${libs.theme-default.classpath}" todir="${build.web.dir.real}/WEB-INF/lib"/>
<copy file="${libs.jstl11.classpath.libfile.2}" todir="${build.web.dir}/WEB-INF/lib"/> <copy file="${libs.jstl11.classpath.libfile.2}" todir="${build.web.dir.real}/WEB-INF/lib"/>
<copy file="${libs.jstl11.classpath.libfile.1}" todir="${build.web.dir}/WEB-INF/lib"/> <copy file="${libs.jstl11.classpath.libfile.1}" todir="${build.web.dir.real}/WEB-INF/lib"/>
<copy file="${file.reference.activation.jar}" todir="${build.web.dir}/WEB-INF/lib"/> <copy file="${file.reference.activation.jar}" todir="${build.web.dir.real}/WEB-INF/lib"/>
<copy file="${file.reference.mail.jar}" todir="${build.web.dir}/WEB-INF/lib"/> <copy file="${file.reference.mail.jar}" todir="${build.web.dir.real}/WEB-INF/lib"/>
<copy file="${file.reference.postgresql-8.2-506.jdbc4.jar}" todir="${build.web.dir}/WEB-INF/lib"/> <copy file="${file.reference.postgresql-8.2-506.jdbc4.jar}" todir="${build.web.dir.real}/WEB-INF/lib"/>
<copy file="${libs.rowset-ri.classpath}" todir="${build.web.dir}/WEB-INF/lib"/> <copy file="${file.reference.iText-2.0.8.jar}" todir="${build.web.dir.real}/WEB-INF/lib"/>
<copy file="${file.reference.iText-2.0.8.jar}" todir="${build.web.dir}/WEB-INF/lib"/> <copy file="${file.reference.evolute.jar}" todir="${build.web.dir.real}/WEB-INF/lib"/>
<copy file="${libs.jsf-runtime.classpath.libfile.6}" todir="${build.web.dir}/WEB-INF/lib"/> <copy file="${file.reference.fop.jar}" todir="${build.web.dir.real}/WEB-INF/lib"/>
<copy file="${libs.jsf-runtime.classpath.libfile.5}" todir="${build.web.dir}/WEB-INF/lib"/> <copy file="${file.reference.jdom.jar}" todir="${build.web.dir.real}/WEB-INF/lib"/>
<copy file="${libs.jsf-runtime.classpath.libfile.4}" todir="${build.web.dir}/WEB-INF/lib"/> <copy file="${file.reference.avalon-framework-4.2.0.jar}" todir="${build.web.dir.real}/WEB-INF/lib"/>
<copy file="${libs.jsf-runtime.classpath.libfile.3}" todir="${build.web.dir}/WEB-INF/lib"/> <copy file="${file.reference.batik.jar}" todir="${build.web.dir.real}/WEB-INF/lib"/>
<copy file="${libs.jsf-runtime.classpath.libfile.2}" todir="${build.web.dir}/WEB-INF/lib"/> <copy file="${libs.jsf-runtime.classpath.libfile.6}" todir="${build.web.dir.real}/WEB-INF/lib"/>
<copy file="${libs.jsf-runtime.classpath.libfile.1}" todir="${build.web.dir}/WEB-INF/lib"/> <copy file="${libs.jsf-runtime.classpath.libfile.5}" todir="${build.web.dir.real}/WEB-INF/lib"/>
<copy file="${libs.jsfsupport-runtime.classpath.libfile.4}" todir="${build.web.dir}/WEB-INF/lib"/> <copy file="${libs.jsf-runtime.classpath.libfile.4}" todir="${build.web.dir.real}/WEB-INF/lib"/>
<copy file="${libs.jsfsupport-runtime.classpath.libfile.3}" todir="${build.web.dir}/WEB-INF/lib"/> <copy file="${libs.jsf-runtime.classpath.libfile.3}" todir="${build.web.dir.real}/WEB-INF/lib"/>
<copy file="${libs.jsfsupport-runtime.classpath.libfile.2}" todir="${build.web.dir}/WEB-INF/lib"/> <copy file="${libs.jsf-runtime.classpath.libfile.2}" todir="${build.web.dir.real}/WEB-INF/lib"/>
<copy file="${libs.jsfsupport-runtime.classpath.libfile.1}" todir="${build.web.dir}/WEB-INF/lib"/> <copy file="${libs.jsf-runtime.classpath.libfile.1}" todir="${build.web.dir.real}/WEB-INF/lib"/>
<copy file="${libs.webui-runtime.classpath.libfile.2}" todir="${build.web.dir}/WEB-INF/lib"/> <copy file="${libs.jsfsupport-runtime.classpath.libfile.3}" todir="${build.web.dir.real}/WEB-INF/lib"/>
<copy file="${libs.webui-runtime.classpath.libfile.1}" todir="${build.web.dir}/WEB-INF/lib"/> <copy file="${libs.jsfsupport-runtime.classpath.libfile.2}" todir="${build.web.dir.real}/WEB-INF/lib"/>
<copy file="${libs.jdbcsupport-runtime.classpath}" todir="${build.web.dir}/WEB-INF/lib"/> <copy file="${libs.jsfsupport-runtime.classpath.libfile.1}" todir="${build.web.dir.real}/WEB-INF/lib"/>
<copy file="${libs.exceptionhandler-runtime.classpath}" todir="${build.web.dir}/WEB-INF/lib"/> <copy file="${libs.webui-runtime.classpath.libfile.2}" todir="${build.web.dir.real}/WEB-INF/lib"/>
<copy file="${libs.theme-default.classpath}" todir="${build.web.dir}/WEB-INF/lib"/> <copy file="${libs.webui-runtime.classpath.libfile.1}" todir="${build.web.dir.real}/WEB-INF/lib"/>
<copy file="${libs.jstl11.classpath.libfile.2}" todir="${build.web.dir}/WEB-INF/lib"/> <copy file="${libs.jdbcsupport-runtime.classpath.libfile.2}" todir="${build.web.dir.real}/WEB-INF/lib"/>
<copy file="${libs.jstl11.classpath.libfile.1}" todir="${build.web.dir}/WEB-INF/lib"/> <copy file="${libs.jdbcsupport-runtime.classpath.libfile.1}" todir="${build.web.dir.real}/WEB-INF/lib"/>
</target> <copy file="${libs.exceptionhandler-runtime.classpath}" todir="${build.web.dir.real}/WEB-INF/lib"/>
<target depends="init,compile,compile-jsps,-pre-dist,library-inclusion-in-manifest" name="do-ear-dist"> <copy file="${libs.theme-default.classpath}" todir="${build.web.dir.real}/WEB-INF/lib"/>
<dirname file="${dist.ear.war}" property="dist.jar.dir"/> <copy file="${libs.jstl11.classpath.libfile.2}" todir="${build.web.dir.real}/WEB-INF/lib"/>
<copy file="${libs.jstl11.classpath.libfile.1}" todir="${build.web.dir.real}/WEB-INF/lib"/>
</target>
<target name="do-ear-dist" depends="init,compile,compile-jsps,-pre-dist,library-inclusion-in-manifest">
<dirname property="dist.jar.dir" file="${dist.ear.war}"/>
<mkdir dir="${dist.jar.dir}"/> <mkdir dir="${dist.jar.dir}"/>
<jar compress="${jar.compress}" jarfile="${dist.ear.war}" manifest="${build.web.dir}/META-INF/MANIFEST.MF"> <jar jarfile="${dist.ear.war}" compress="${jar.compress}" manifest="${build.web.dir.real}/META-INF/MANIFEST.MF">
<fileset dir="${build.web.dir}"/> <fileset dir="${build.web.dir.real}"/>
</jar> </jar>
</target> </target>
<target name="-post-dist"> <target name="-post-dist">
<!-- Empty placeholder for easier customization. --> <!-- Empty placeholder for easier customization. -->
<!-- You can override this target in the ../build.xml file. --> <!-- You can override this target in the ../build.xml file. -->
</target> </target>
<target depends="init,compile,-pre-dist,do-dist,-post-dist" description="Build distribution (WAR)." name="dist"/> <target name="dist" depends="init,compile,-pre-dist,do-dist,-post-dist" description="Build distribution (WAR)."/>
<target depends="init,compile,-pre-dist,do-ear-dist,-post-dist" description="Build distribution (WAR) to be packaged into an EAR." name="dist-ear"/> <target name="dist-ear" depends="init,compile,-pre-dist,do-ear-dist,-post-dist" description="Build distribution (WAR) to be packaged into an EAR."/>
<!-- <!--
EXECUTION SECTION EXECUTION SECTION
--> -->
<target depends="run-deploy,run-display-browser" description="Deploy to server and show in browser." name="run"/> <target name="run" depends="run-deploy,run-display-browser" description="Deploy to server and show in browser."/>
<target name="-pre-run-deploy"> <target name="-pre-run-deploy">
<!-- Empty placeholder for easier customization. --> <!-- Empty placeholder for easier customization. -->
<!-- You can override this target in the ../build.xml file. --> <!-- You can override this target in the ../build.xml file. -->
@ -582,11 +535,9 @@
<target name="-run-deploy-am"> <target name="-run-deploy-am">
<!-- Task to deploy to the Access Manager runtime. --> <!-- Task to deploy to the Access Manager runtime. -->
</target> </target>
<target depends="init,compile,compile-jsps,-do-compile-single-jsp,-pre-dist,-do-tmp-dist-with-manifest,-do-tmp-dist-without-manifest,-pre-run-deploy,-pre-nbmodule-run-deploy,-run-deploy-nb,-init-deploy-ant,-deploy-ant,-run-deploy-am,-post-nbmodule-run-deploy,-post-run-deploy" name="run-deploy"> <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"/>
<nbjpdaappreloaded/> <target name="-run-deploy-nb" if="netbeans.home">
</target> <nbdeploy debugmode="false" clientUrlPart="${client.urlPart}" forceRedeploy="${forceRedeploy}"/>
<target if="netbeans.home" name="-run-deploy-nb">
<nbdeploy clientUrlPart="${client.urlPart}" debugmode="false" forceRedeploy="${forceRedeploy}"/>
</target> </target>
<target name="-init-deploy-ant" unless="netbeans.home"> <target name="-init-deploy-ant" unless="netbeans.home">
<property name="deploy.ant.archive" value="${dist.war}"/> <property name="deploy.ant.archive" value="${dist.war}"/>
@ -594,15 +545,15 @@
<property name="deploy.ant.resource.dir" value="${resource.dir}"/> <property name="deploy.ant.resource.dir" value="${resource.dir}"/>
<property name="deploy.ant.enabled" value="true"/> <property name="deploy.ant.enabled" value="true"/>
</target> </target>
<target depends="dist,-run-undeploy-nb,-init-deploy-ant,-undeploy-ant" name="run-undeploy"/> <target name="run-undeploy" depends="dist,-run-undeploy-nb,-init-deploy-ant,-undeploy-ant"/>
<target if="netbeans.home" name="-run-undeploy-nb"> <target name="-run-undeploy-nb" if="netbeans.home">
<fail message="Undeploy is not supported from within the IDE"/> <fail message="Undeploy is not supported from within the IDE"/>
</target> </target>
<target depends="init,-pre-dist,dist,-post-dist" name="verify"> <target name="verify" depends="init,dist">
<nbverify file="${dist.war}"/> <nbverify file="${dist.war}"/>
</target> </target>
<target depends="run-deploy,-init-display-browser,-display-browser-nb,-display-browser-cl" name="run-display-browser"/> <target name="run-display-browser" depends="run-deploy,-init-display-browser,-display-browser-nb,-display-browser-cl"/>
<target if="do.display.browser" name="-init-display-browser"> <target name="-init-display-browser" if="do.display.browser">
<condition property="do.display.browser.nb"> <condition property="do.display.browser.nb">
<isset property="netbeans.home"/> <isset property="netbeans.home"/>
</condition> </condition>
@ -610,14 +561,14 @@
<isset property="deploy.ant.enabled"/> <isset property="deploy.ant.enabled"/>
</condition> </condition>
</target> </target>
<target if="do.display.browser.nb" name="-display-browser-nb"> <target name="-display-browser-nb" if="do.display.browser.nb">
<nbbrowse url="${client.url}"/> <nbbrowse url="${client.url}"/>
</target> </target>
<target if="do.display.browser.cl" name="-get-browser" unless="browser"> <target name="-get-browser" if="do.display.browser.cl" unless="browser">
<condition property="browser" value="rundll32"> <condition property="browser" value="rundll32">
<os family="windows"/> <os family="windows"/>
</condition> </condition>
<condition else="" property="browser.args" value="url.dll,FileProtocolHandler"> <condition property="browser.args" value="url.dll,FileProtocolHandler" else="">
<os family="windows"/> <os family="windows"/>
</condition> </condition>
<condition property="browser" value="/usr/bin/open"> <condition property="browser" value="/usr/bin/open">
@ -652,7 +603,7 @@
<available file="/opt/csw/bin/mozilla"/> <available file="/opt/csw/bin/mozilla"/>
</condition> </condition>
</target> </target>
<target depends="-get-browser" if="do.display.browser.cl" name="-display-browser-cl"> <target name="-display-browser-cl" depends="-get-browser" if="do.display.browser.cl">
<fail unless="browser"> <fail unless="browser">
Browser not found, cannot launch the deployed application. Try to set the BROWSER environment variable. Browser not found, cannot launch the deployed application. Try to set the BROWSER environment variable.
</fail> </fail>
@ -662,54 +613,54 @@
<arg line="${browser.args} ${browse.url}"/> <arg line="${browser.args} ${browse.url}"/>
</exec> </exec>
</target> </target>
<target depends="init,compile-single" name="run-main"> <target name="run-main" depends="init,compile-single">
<fail unless="run.class">Must select one file in the IDE or set run.class</fail> <fail unless="run.class">Must select one file in the IDE or set run.class</fail>
<webproject1:java classname="${run.class}"/> <webproject1:java classname="${run.class}"/>
</target> </target>
<!-- <!--
DEBUGGING SECTION DEBUGGING SECTION
--> -->
<target depends="init,compile,compile-jsps,-do-compile-single-jsp,-pre-dist,-do-tmp-dist-with-manifest,-do-tmp-dist-without-manifest" description="Debug project in IDE." if="netbeans.home" name="debug"> <target name="debug" description="Debug project in IDE." depends="init,compile,compile-jsps,-do-compile-single-jsp,dist" if="netbeans.home">
<nbdeploy clientUrlPart="${client.urlPart}" debugmode="true"/> <nbdeploy debugmode="true" clientUrlPart="${client.urlPart}"/>
<antcall target="connect-debugger"/> <antcall target="connect-debugger"/>
<antcall target="debug-display-browser"/> <antcall target="debug-display-browser"/>
</target> </target>
<target name="connect-debugger" unless="is.debugged"> <target name="connect-debugger" unless="is.debugged">
<nbjpdaconnect address="${jpda.address}" host="${jpda.host}" name="${name}" transport="${jpda.transport}"> <nbjpdaconnect name="${name}" host="${jpda.host}" address="${jpda.address}" transport="${jpda.transport}">
<classpath> <classpath>
<path path="${debug.classpath}:${j2ee.platform.classpath}:${ws.debug.classpaths}"/> <path path="${debug.classpath}:${ws.debug.classpaths}"/>
</classpath> </classpath>
<sourcepath> <sourcepath>
<path path="${web.docbase.dir}:${ws.web.docbase.dirs}"/> <path path="${web.docbase.dir}:${ws.web.docbase.dirs}"/>
</sourcepath> </sourcepath>
</nbjpdaconnect> </nbjpdaconnect>
</target> </target>
<target if="do.display.browser" name="debug-display-browser"> <target name="debug-display-browser" if="do.display.browser">
<nbbrowse url="${client.url}"/> <nbbrowse url="${client.url}"/>
</target> </target>
<target depends="init,compile,compile-jsps,-do-compile-single-jsp,debug" if="netbeans.home" name="debug-single"/> <target name="debug-single" if="netbeans.home" depends="init,compile,compile-jsps,-do-compile-single-jsp,debug"/>
<target depends="init" if="netbeans.home" name="-debug-start-debugger"> <target name="-debug-start-debugger" if="netbeans.home" depends="init">
<webproject1:nbjpdastart name="${debug.class}"/> <webproject1:nbjpdastart name="${debug.class}"/>
</target> </target>
<target depends="init,compile-single" if="netbeans.home" name="-debug-start-debuggee-single"> <target name="-debug-start-debuggee-single" if="netbeans.home" depends="init,compile-single">
<fail unless="debug.class">Must select one file in the IDE or set debug.class</fail> <fail unless="debug.class">Must select one file in the IDE or set debug.class</fail>
<webproject1:debug classname="${debug.class}"/> <webproject1:debug classname="${debug.class}"/>
</target> </target>
<target depends="init,compile-single,-debug-start-debugger,-debug-start-debuggee-single" if="netbeans.home" name="debug-single-main"/> <target name="debug-single-main" if="netbeans.home" depends="init,compile-single,-debug-start-debugger,-debug-start-debuggee-single"/>
<target depends="init" name="-pre-debug-fix"> <target name="-pre-debug-fix" depends="init">
<fail unless="fix.includes">Must set fix.includes</fail> <fail unless="fix.includes">Must set fix.includes</fail>
<property name="javac.includes" value="${fix.includes}.java"/> <property name="javac.includes" value="${fix.includes}.java"/>
</target> </target>
<target depends="init,-pre-debug-fix,compile-single" if="netbeans.home" name="-do-debug-fix"> <target name="-do-debug-fix" if="netbeans.home" depends="init,-pre-debug-fix,compile-single">
<webproject1:nbjpdareload/> <webproject1:nbjpdareload/>
</target> </target>
<target depends="init,-pre-debug-fix,-do-debug-fix" if="netbeans.home" name="debug-fix"/> <target name="debug-fix" if="netbeans.home" depends="init,-pre-debug-fix,-do-debug-fix"/>
<!-- <!--
JAVADOC SECTION JAVADOC SECTION
--> -->
<target depends="init" name="javadoc-build"> <target name="javadoc-build" depends="init">
<mkdir dir="${dist.javadoc.dir}"/> <mkdir dir="${dist.javadoc.dir}"/>
<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}"> <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">
<classpath> <classpath>
<path path="${javac.classpath}:${j2ee.platform.classpath}"/> <path path="${javac.classpath}:${j2ee.platform.classpath}"/>
</classpath> </classpath>
@ -720,23 +671,23 @@
<fileset dir="${src.dir}" includes="*.java"/> <fileset dir="${src.dir}" includes="*.java"/>
</javadoc> </javadoc>
</target> </target>
<target depends="init,javadoc-build" if="netbeans.home" name="javadoc-browse" unless="no.javadoc.preview"> <target name="javadoc-browse" if="netbeans.home" unless="no.javadoc.preview" depends="init,javadoc-build">
<nbbrowse file="${dist.javadoc.dir}/index.html"/> <nbbrowse file="${dist.javadoc.dir}/index.html"/>
</target> </target>
<target depends="init,javadoc-build,javadoc-browse" description="Build Javadoc." name="javadoc"/> <target name="javadoc" depends="init,javadoc-build,javadoc-browse" description="Build Javadoc."/>
<!-- <!--
JUNIT COMPILATION SECTION JUNIT COMPILATION SECTION
--> -->
<target depends="init,compile" if="have.tests" name="-pre-pre-compile-test"> <target name="-pre-pre-compile-test" if="have.tests" depends="init,compile">
<mkdir dir="${build.test.classes.dir}"/> <mkdir dir="${build.test.classes.dir}"/>
</target> </target>
<target name="-pre-compile-test"> <target name="-pre-compile-test">
<!-- Empty placeholder for easier customization. --> <!-- Empty placeholder for easier customization. -->
<!-- You can override this target in the ../build.xml file. --> <!-- You can override this target in the ../build.xml file. -->
</target> </target>
<target depends="init,compile,-pre-pre-compile-test,-pre-compile-test" if="have.tests" name="-do-compile-test"> <target name="-do-compile-test" if="have.tests" depends="init,compile,-pre-pre-compile-test,-pre-compile-test">
<webproject2:javac classpath="${javac.test.classpath}:${j2ee.platform.classpath}" debug="true" destdir="${build.test.classes.dir}" srcdir="${test.src.dir}"/> <webproject2:javac srcdir="${test.src.dir}" destdir="${build.test.classes.dir}" debug="true" classpath="${javac.test.classpath}:${j2ee.platform.classpath}"/>
<copy todir="${build.test.classes.dir}"> <copy todir="${build.test.classes.dir}">
<fileset dir="${test.src.dir}" excludes="**/*.java"/> <fileset dir="${test.src.dir}" excludes="**/*.java"/>
</copy> </copy>
@ -745,14 +696,14 @@
<!-- Empty placeholder for easier customization. --> <!-- Empty placeholder for easier customization. -->
<!-- You can override this target in the ../build.xml file. --> <!-- You can override this target in the ../build.xml file. -->
</target> </target>
<target depends="init,compile,-pre-pre-compile-test,-pre-compile-test,-do-compile-test,-post-compile-test" name="compile-test"/> <target name="compile-test" depends="init,compile,-pre-pre-compile-test,-pre-compile-test,-do-compile-test,-post-compile-test"/>
<target name="-pre-compile-test-single"> <target name="-pre-compile-test-single">
<!-- Empty placeholder for easier customization. --> <!-- Empty placeholder for easier customization. -->
<!-- You can override this target in the ../build.xml file. --> <!-- You can override this target in the ../build.xml file. -->
</target> </target>
<target depends="init,compile,-pre-pre-compile-test,-pre-compile-test-single" if="have.tests" name="-do-compile-test-single"> <target name="-do-compile-test-single" if="have.tests" depends="init,compile,-pre-pre-compile-test,-pre-compile-test-single">
<fail unless="javac.includes">Must select some files in the IDE or set javac.includes</fail> <fail unless="javac.includes">Must select some files in the IDE or set javac.includes</fail>
<webproject2:javac classpath="${javac.test.classpath}:${j2ee.platform.classpath}" debug="true" destdir="${build.test.classes.dir}" srcdir="${test.src.dir}"> <webproject2:javac srcdir="${test.src.dir}" destdir="${build.test.classes.dir}" debug="true" classpath="${javac.test.classpath}:${j2ee.platform.classpath}">
<customize> <customize>
<patternset includes="${javac.includes}"/> <patternset includes="${javac.includes}"/>
</customize> </customize>
@ -765,85 +716,75 @@
<!-- Empty placeholder for easier customization. --> <!-- Empty placeholder for easier customization. -->
<!-- You can override this target in the ../build.xml file. --> <!-- You can override this target in the ../build.xml file. -->
</target> </target>
<target depends="init,compile,-pre-pre-compile-test,-pre-compile-test-single,-do-compile-test-single,-post-compile-test-single" name="compile-test-single"/> <target name="compile-test-single" depends="init,compile,-pre-pre-compile-test,-pre-compile-test-single,-do-compile-test-single,-post-compile-test-single"/>
<!-- <!--
JUNIT EXECUTION SECTION JUNIT EXECUTION SECTION
--> -->
<target depends="init" if="have.tests" name="-pre-test-run"> <target name="-pre-test-run" if="have.tests" depends="init">
<mkdir dir="${build.test.results.dir}"/> <mkdir dir="${build.test.results.dir}"/>
</target> </target>
<target depends="init,compile-test,-pre-test-run" if="have.tests" name="-do-test-run"> <target name="-do-test-run" if="have.tests" depends="init,compile-test,-pre-test-run">
<webproject2:junit/> <webproject2:junit/>
</target> </target>
<target depends="init,compile-test,-pre-test-run,-do-test-run" if="have.tests" name="-post-test-run"> <target name="-post-test-run" if="have.tests" depends="init,compile-test,-pre-test-run,-do-test-run">
<fail if="tests.failed">Some tests failed; see details above.</fail> <fail if="tests.failed">Some tests failed; see details above.</fail>
</target> </target>
<target depends="init" if="have.tests" name="test-report"/> <target name="test-report" if="have.tests" depends="init"/>
<target depends="init" if="netbeans.home+have.tests" name="-test-browse"/> <target name="-test-browse" if="netbeans.home+have.tests" depends="init"/>
<target depends="init,compile-test,-pre-test-run,-do-test-run,test-report,-post-test-run,-test-browse" description="Run unit tests." name="test"/> <target name="test" depends="init,compile-test,-pre-test-run,-do-test-run,test-report,-post-test-run,-test-browse" description="Run unit tests."/>
<target depends="init" if="have.tests" name="-pre-test-run-single"> <target name="-pre-test-run-single" if="have.tests" depends="init">
<mkdir dir="${build.test.results.dir}"/> <mkdir dir="${build.test.results.dir}"/>
</target> </target>
<target depends="init,compile-test-single,-pre-test-run-single" if="have.tests" name="-do-test-run-single"> <target name="-do-test-run-single" if="have.tests" depends="init,compile-test-single,-pre-test-run-single">
<fail unless="test.includes">Must select some files in the IDE or set test.includes</fail> <fail unless="test.includes">Must select some files in the IDE or set test.includes</fail>
<webproject2:junit includes="${test.includes}"/> <webproject2:junit includes="${test.includes}"/>
</target> </target>
<target depends="init,compile-test-single,-pre-test-run-single,-do-test-run-single" if="have.tests" name="-post-test-run-single"> <target name="-post-test-run-single" if="have.tests" depends="init,compile-test-single,-pre-test-run-single,-do-test-run-single">
<fail if="tests.failed">Some tests failed; see details above.</fail> <fail if="tests.failed">Some tests failed; see details above.</fail>
</target> </target>
<target depends="init,compile-test-single,-pre-test-run-single,-do-test-run-single,-post-test-run-single" description="Run single unit test." name="test-single"/> <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."/>
<!-- <!--
JUNIT DEBUGGING SECTION JUNIT DEBUGGING SECTION
--> -->
<target depends="init,compile-test" if="have.tests" name="-debug-start-debuggee-test"> <target name="-debug-start-debuggee-test" if="have.tests" depends="init,compile-test">
<fail unless="test.class">Must select one file in the IDE or set test.class</fail> <fail unless="test.class">Must select one file in the IDE or set test.class</fail>
<property location="${build.test.results.dir}/TEST-${test.class}.xml" name="test.report.file"/> <webproject1:debug classname="junit.textui.TestRunner" classpath="${debug.test.classpath}" args="${test.class}"/>
<delete file="${test.report.file}"/>
<!-- must exist, otherwise the XML formatter would fail -->
<mkdir dir="${build.test.results.dir}"/>
<webproject1:debug args="${test.class}" classname="org.apache.tools.ant.taskdefs.optional.junit.JUnitTestRunner" classpath="${ant.home}/lib/ant.jar:${ant.home}/lib/ant-junit.jar:${debug.test.classpath}">
<customize>
<arg value="showoutput=true"/>
<arg value="formatter=org.apache.tools.ant.taskdefs.optional.junit.BriefJUnitResultFormatter"/>
<arg value="formatter=org.apache.tools.ant.taskdefs.optional.junit.XMLJUnitResultFormatter,${test.report.file}"/>
</customize>
</webproject1:debug>
</target> </target>
<target depends="init,compile-test" if="netbeans.home+have.tests" name="-debug-start-debugger-test"> <target name="-debug-start-debugger-test" if="netbeans.home+have.tests" depends="init,compile-test">
<webproject1:nbjpdastart classpath="${debug.test.classpath}" name="${test.class}"/> <webproject1:nbjpdastart name="${test.class}" classpath="${debug.test.classpath}"/>
</target> </target>
<target depends="init,compile-test,-debug-start-debugger-test,-debug-start-debuggee-test" name="debug-test"/> <target name="debug-test" depends="init,compile-test,-debug-start-debugger-test,-debug-start-debuggee-test"/>
<target depends="init,-pre-debug-fix,compile-test-single" if="netbeans.home" name="-do-debug-fix-test"> <target name="-do-debug-fix-test" if="netbeans.home" depends="init,-pre-debug-fix,compile-test-single">
<webproject1:nbjpdareload dir="${build.test.classes.dir}"/> <webproject1:nbjpdareload dir="${build.test.classes.dir}"/>
</target> </target>
<target depends="init,-pre-debug-fix,-do-debug-fix-test" if="netbeans.home" name="debug-fix-test"/> <target name="debug-fix-test" if="netbeans.home" depends="init,-pre-debug-fix,-do-debug-fix-test"/>
<!-- <!--
CLEANUP SECTION CLEANUP SECTION
--> -->
<target depends="init" if="no.dist.ear.dir" name="deps-clean" unless="no.deps"/> <target name="deps-clean" depends="init" if="no.dist.ear.dir" unless="no.deps"/>
<target depends="init" name="do-clean"> <target name="do-clean" depends="init">
<condition property="build.dir.to.clean" value="${build.web.dir}"> <condition value="${build.web.dir.real}" property="build.dir.to.clean">
<isset property="dist.ear.dir"/> <isset property="dist.ear.dir"/>
</condition> </condition>
<property name="build.dir.to.clean" value="${build.web.dir}"/> <property value="${build.web.dir.real}" name="build.dir.to.clean"/>
<delete includeEmptyDirs="true" quiet="true"> <delete includeEmptyDirs="true" quiet="true">
<fileset dir="${build.dir.to.clean}/WEB-INF/lib"/> <fileset dir="${build.dir.to.clean}/WEB-INF/lib"/>
</delete> </delete>
<delete dir="${build.dir}"/> <delete dir="${build.dir}"/>
<available file="${build.dir.to.clean}/WEB-INF/lib" property="status.clean-failed" type="dir"/> <available file="${build.dir.to.clean}/WEB-INF/lib" type="dir" property="status.clean-failed"/>
<delete dir="${dist.dir}"/> <delete dir="${dist.dir}"/>
</target> </target>
<target depends="do-clean" if="status.clean-failed" name="check-clean"> <target name="check-clean" depends="do-clean" if="status.clean-failed">
<echo message="Warning: unable to delete some files in ${build.web.dir}/WEB-INF/lib - they are probably locked by the J2EE server. "/> <echo message="Warning: unable to delete some files in ${build.web.dir.real}/WEB-INF/lib - they are probably locked by the J2EE server. "/>
<echo level="info" message="To delete all files undeploy the module from Server Registry in Runtime tab and then use Clean again."/> <echo level="info" message="To delete all files undeploy the module from Server Registry in Runtime tab and then use Clean again."/>
</target> </target>
<target name="-post-clean"> <target name="-post-clean">
<!-- Empty placeholder for easier customization. --> <!-- Empty placeholder for easier customization. -->
<!-- You can override this target in the ../build.xml file. --> <!-- You can override this target in the ../build.xml file. -->
</target> </target>
<target depends="init,deps-clean,do-clean,check-clean,-post-clean" description="Clean build products." name="clean"/> <target name="clean" depends="init,deps-clean,do-clean,check-clean,-post-clean" description="Clean build products."/>
<target depends="clean" description="Clean build products." name="clean-ear"/> <target name="clean-ear" depends="clean" description="Clean build products."/>
</project> </project>

@ -1,8 +1,8 @@
build.xml.data.CRC32=344e64b2 build.xml.data.CRC32=9736285c
build.xml.script.CRC32=82e52d07 build.xml.script.CRC32=ab1471e9
build.xml.stylesheet.CRC32=cfd7ba16 build.xml.stylesheet.CRC32=95be3570
# This file is used by a NetBeans-based IDE to track changes in generated files such as build-impl.xml. # This file is used by a NetBeans-based IDE to track changes in generated files such as build-impl.xml.
# Do not edit this file. You may delete it but then the IDE will never regenerate such files for you. # Do not edit this file. You may delete it but then the IDE will never regenerate such files for you.
nbproject/build-impl.xml.data.CRC32=344e64b2 nbproject/build-impl.xml.data.CRC32=9736285c
nbproject/build-impl.xml.script.CRC32=e5818321 nbproject/build-impl.xml.script.CRC32=8213162e
nbproject/build-impl.xml.stylesheet.CRC32=723dd8e7 nbproject/build-impl.xml.stylesheet.CRC32=ac43bae1

@ -19,11 +19,16 @@ dist.ear.war=${dist.dir}/${war.ear.name}
dist.javadoc.dir=${dist.dir}/javadoc dist.javadoc.dir=${dist.dir}/javadoc
dist.war=${dist.dir}/${war.name} dist.war=${dist.dir}/${war.name}
file.reference.activation.jar=jars/activation.jar file.reference.activation.jar=jars/activation.jar
file.reference.avalon-framework-4.2.0.jar=lib/avalon-framework-4.2.0.jar
file.reference.batik.jar=lib/batik.jar
file.reference.evolute.jar=lib/evolute.jar
file.reference.fop.jar=lib/fop.jar
file.reference.iText-2.0.8.jar=lib/iText-2.0.8.jar file.reference.iText-2.0.8.jar=lib/iText-2.0.8.jar
file.reference.jdom.jar=lib/jdom.jar
file.reference.mail.jar=jars/mail.jar file.reference.mail.jar=jars/mail.jar
file.reference.postgresql-8.2-506.jdbc4.jar=jars/postgresql-8.2-506.jdbc4.jar file.reference.postgresql-8.2-506.jdbc4.jar=jars/postgresql-8.2-506.jdbc4.jar
j2ee.platform=1.4 j2ee.platform=1.4
j2ee.server.type=Tomcat60 j2ee.server.type=Tomcat55
jar.compress=false jar.compress=false
javac.classpath=\ javac.classpath=\
${libs.jsf-designtime.classpath}:\ ${libs.jsf-designtime.classpath}:\
@ -36,7 +41,12 @@ javac.classpath=\
${file.reference.mail.jar}:\ ${file.reference.mail.jar}:\
${file.reference.postgresql-8.2-506.jdbc4.jar}:\ ${file.reference.postgresql-8.2-506.jdbc4.jar}:\
${libs.rowset-ri.classpath}:\ ${libs.rowset-ri.classpath}:\
${file.reference.iText-2.0.8.jar} ${file.reference.iText-2.0.8.jar}:\
${file.reference.evolute.jar}:\
${file.reference.fop.jar}:\
${file.reference.jdom.jar}:\
${file.reference.avalon-framework-4.2.0.jar}:\
${file.reference.batik.jar}
# Space-separated list of extra javac options # Space-separated list of extra javac options
javac.compilerargs= javac.compilerargs=
javac.debug=true javac.debug=true

@ -11,7 +11,7 @@
<file>${libs.jsf-designtime.classpath}</file> <file>${libs.jsf-designtime.classpath}</file>
<path-in-war>WEB-INF/lib</path-in-war> <path-in-war>WEB-INF/lib</path-in-war>
</library> </library>
<library files="4"> <library files="3">
<file>${libs.jsfsupport-designtime.classpath}</file> <file>${libs.jsfsupport-designtime.classpath}</file>
<path-in-war>WEB-INF/lib</path-in-war> <path-in-war>WEB-INF/lib</path-in-war>
</library> </library>
@ -19,7 +19,7 @@
<file>${libs.webui-designtime.classpath}</file> <file>${libs.webui-designtime.classpath}</file>
<path-in-war>WEB-INF/lib</path-in-war> <path-in-war>WEB-INF/lib</path-in-war>
</library> </library>
<library files="1"> <library files="2">
<file>${libs.jdbcsupport-designtime.classpath}</file> <file>${libs.jdbcsupport-designtime.classpath}</file>
<path-in-war>WEB-INF/lib</path-in-war> <path-in-war>WEB-INF/lib</path-in-war>
</library> </library>
@ -43,7 +43,7 @@
<file>${file.reference.postgresql-8.2-506.jdbc4.jar}</file> <file>${file.reference.postgresql-8.2-506.jdbc4.jar}</file>
<path-in-war>WEB-INF/lib</path-in-war> <path-in-war>WEB-INF/lib</path-in-war>
</library> </library>
<library files="1"> <library>
<file>${libs.rowset-ri.classpath}</file> <file>${libs.rowset-ri.classpath}</file>
<path-in-war>WEB-INF/lib</path-in-war> <path-in-war>WEB-INF/lib</path-in-war>
</library> </library>
@ -51,13 +51,33 @@
<file>${file.reference.iText-2.0.8.jar}</file> <file>${file.reference.iText-2.0.8.jar}</file>
<path-in-war>WEB-INF/lib</path-in-war> <path-in-war>WEB-INF/lib</path-in-war>
</library> </library>
<library files="1">
<file>${file.reference.evolute.jar}</file>
<path-in-war>WEB-INF/lib</path-in-war>
</library>
<library files="1">
<file>${file.reference.fop.jar}</file>
<path-in-war>WEB-INF/lib</path-in-war>
</library>
<library files="1">
<file>${file.reference.jdom.jar}</file>
<path-in-war>WEB-INF/lib</path-in-war>
</library>
<library files="1">
<file>${file.reference.avalon-framework-4.2.0.jar}</file>
<path-in-war>WEB-INF/lib</path-in-war>
</library>
<library files="1">
<file>${file.reference.batik.jar}</file>
<path-in-war>WEB-INF/lib</path-in-war>
</library>
</web-module-libraries> </web-module-libraries>
<web-module-additional-libraries> <web-module-additional-libraries>
<library files="6"> <library files="6">
<file>${libs.jsf-runtime.classpath}</file> <file>${libs.jsf-runtime.classpath}</file>
<path-in-war>WEB-INF/lib</path-in-war> <path-in-war>WEB-INF/lib</path-in-war>
</library> </library>
<library files="4"> <library files="3">
<file>${libs.jsfsupport-runtime.classpath}</file> <file>${libs.jsfsupport-runtime.classpath}</file>
<path-in-war>WEB-INF/lib</path-in-war> <path-in-war>WEB-INF/lib</path-in-war>
</library> </library>
@ -65,7 +85,7 @@
<file>${libs.webui-runtime.classpath}</file> <file>${libs.webui-runtime.classpath}</file>
<path-in-war>WEB-INF/lib</path-in-war> <path-in-war>WEB-INF/lib</path-in-war>
</library> </library>
<library files="1"> <library files="2">
<file>${libs.jdbcsupport-runtime.classpath}</file> <file>${libs.jdbcsupport-runtime.classpath}</file>
<path-in-war>WEB-INF/lib</path-in-war> <path-in-war>WEB-INF/lib</path-in-war>
</library> </library>

@ -45,6 +45,7 @@ import java.util.Calendar;
import java.util.Date; import java.util.Date;
import java.util.ListIterator; import java.util.ListIterator;
import java.util.Properties; import java.util.Properties;
import javax.activation.DataHandler;
import javax.faces.FacesException; import javax.faces.FacesException;
import javax.faces.FactoryFinder; import javax.faces.FactoryFinder;
import javax.faces.application.ApplicationFactory; import javax.faces.application.ApplicationFactory;
@ -13983,6 +13984,7 @@ public class AnaliseAcidenteTrabalho extends AbstractPageBean {
private void sendEmailToRhFase4(AnaliseAcidente a) private void sendEmailToRhFase4(AnaliseAcidente a)
{ {
System.out.println("SEND EMAIL TO RH FASE 4");
Acidentado ac = getSessionBean1().getAcidentado(); Acidentado ac = getSessionBean1().getAcidentado();
String assunto = "SIPRP Fecho do Processo de Análise de Acidente de Trabalho nº " + a.getAnalise_nr() + " Ficheiro para Impressão"; String assunto = "SIPRP Fecho do Processo de Análise de Acidente de Trabalho nº " + a.getAnalise_nr() + " Ficheiro para Impressão";
@ -14003,6 +14005,7 @@ public class AnaliseAcidenteTrabalho extends AbstractPageBean {
catch(Exception ex) catch(Exception ex)
{ {
ex.printStackTrace(); ex.printStackTrace();
System.out.println("EMAIL FASE 4 ERROR : " + ex.getMessage());
} }
} }
catch(Exception ex) catch(Exception ex)
@ -14093,7 +14096,42 @@ public class AnaliseAcidenteTrabalho extends AbstractPageBean {
private void sendEmailWithPdf(AnaliseAcidente a, String emailTo, String emailFrom, String assunto, String texto_email) throws Exception private void sendEmailWithPdf(AnaliseAcidente a, String emailTo, String emailFrom, String assunto, String texto_email) throws Exception
{ {
PdfGenerator pdf = new PdfGenerator(a); System.out.println("SEND EMAIL WITH PDF");
UtilizadoresDataProvider udp = new UtilizadoresDataProvider();
Utilizador ut = udp.getUtilizador(a.getTecnico_saude_id());
Utilizador um = udp.getUtilizador(a.getMedico_id());
AnalisesDataProvider adp = new AnalisesDataProvider();
Acidentado ac = adp.getAcidentado(a.getAcidentado_id());
Estabelecimento e = new Estabelecimento();
e.setId(a.getEstabelecimento_id());
e.setNome(adp.getEstabelecimentoNome(a.getEstabelecimento_id()));
Seccao s = adp.getSeccao(a.getSeccao_id());
Causa c = adp.getCausa(a.getCausas());
ArrayList recList = adp.getRecomendacoesByAnalise(a.getId());
Recomendacao[] recArray = new Recomendacao[recList.size()];
ListIterator iter = recList.listIterator();
int i = 0;
while(iter.hasNext())
{
Recomendacao rec = (Recomendacao) iter.next();
recArray[i] = rec;
i++;
}
//Recomendacao recArray[] = (Recomendacao)recList.toArray();
ArrayList medList = adp.getMedidasByAnalise(a.getId());
//Medida medArray[] = (Medida)medList.toArray();
Medida[] medArray = new Medida[medList.size()];
iter = medList.listIterator();
i = 0;
while(iter.hasNext())
{
Medida med = (Medida) iter.next();
medArray[i] = med;
i++;
}
PdfGenerator pdf = new PdfGenerator(Global.IMAGE_FOLDER, e, ut, um, a, ac, s, recArray, medArray, c);
ByteArrayDataSource ds = new ByteArrayDataSource(pdf.generatePdf(), ByteArrayDataSource ds = new ByteArrayDataSource(pdf.generatePdf(),
"application/pdf"); "application/pdf");
Properties props = new Properties(); Properties props = new Properties();
@ -14124,14 +14162,16 @@ public class AnaliseAcidenteTrabalho extends AbstractPageBean {
multipart.addBodyPart(msgBodyPart); multipart.addBodyPart(msgBodyPart);
MimeBodyPart pdfPart = new MimeBodyPart(); MimeBodyPart pdfPart = new MimeBodyPart();
pdfPart.setContent(ds,"application/pdf"); //pdfPart.setContent(ds,"application/pdf");
pdfPart.setDataHandler(new DataHandler(ds));
pdfPart.setHeader("Content-Transfer-Encoding","base64"); pdfPart.setHeader("Content-Transfer-Encoding","base64");
pdfPart.setHeader("Content-Disposition","attachment"); pdfPart.setHeader("Content-Disposition","attachment");
pdfPart.setFileName("AnaliseAcidente" + a.getAnalise_nr()); String pdfname = "Analise" + a.getAnalise_nr();
pdfPart.setFileName(pdfname);
multipart.addBodyPart(pdfPart,1); multipart.addBodyPart(pdfPart,1);
msg.setContent(multipart); msg.setContent(multipart);
Transport.send(msg); Transport.send(msg);
System.out.println("Email Enviado !!!! "); System.out.println("Email Enviado !!!! " + emailTo);
} }
public String butImprimir_action() { public String butImprimir_action() {

@ -21,8 +21,8 @@ import javax.servlet.http.HttpSession;
* @author lluis * @author lluis
*/ */
public class Db { public class Db {
String connectionURL = "jdbc:postgresql://storage:5432/siprp"; //testes //String connectionURL = "jdbc:postgresql://storage:5432/siprp"; //testes
//String connectionURL = "jdbc:postgresql://localhost:5436/siprp"; //real String connectionURL = "jdbc:postgresql://localhost:5436/siprp"; //real
String User = "postgres"; String User = "postgres";
String Pass = null; String Pass = null;
Connection connection = null; Connection connection = null;

@ -21,8 +21,8 @@ import javax.servlet.http.HttpSession;
* @author lluis * @author lluis
*/ */
public class Dblocal { public class Dblocal {
String connectionURL = "jdbc:postgresql://storage:5432/siprp_local"; //testes //String connectionURL = "jdbc:postgresql://storage:5432/siprp_local"; //testes
//String connectionURL = "jdbc:postgresql://localhost:5436/siprp_local_3"; String connectionURL = "jdbc:postgresql://localhost:5436/siprp_local_3";
String User = "postgres"; String User = "postgres";
String Pass = null; String Pass = null;
Connection connection = null; Connection connection = null;

@ -41,7 +41,8 @@ public class PdfGenerator
protected final Causa causa; protected final Causa causa;
protected final URL urlSiprp; protected final URL urlSiprp;
protected final URL urlAuchan; protected final URL urlAuchan;
protected Vector<URL> imagens = new Vector<URL>(); //protected Vector<URL> imagens = new Vector<URL>();
protected Vector imagens = new Vector();
public static void main( String args[] ) public static void main( String args[] )
throws Exception throws Exception

Loading…
Cancel
Save