| <!-- |
| |
| Copyright (c) 2002, 2018 Oracle and/or its affiliates. All rights reserved. |
| |
| This program and the accompanying materials are made available under the |
| terms of the Eclipse Public License v. 2.0, which is available at |
| http://www.eclipse.org/legal/epl-2.0. |
| |
| This Source Code may also be made available under the following Secondary |
| Licenses when the conditions for such availability set forth in the |
| Eclipse Public License v. 2.0 are satisfied: GNU General Public License, |
| version 2 with the GNU Classpath Exception, which is available at |
| https://www.gnu.org/software/classpath/license.html. |
| |
| SPDX-License-Identifier: EPL-2.0 OR GPL-2.0 WITH Classpath-exception-2.0 |
| |
| --> |
| |
| <!DOCTYPE project [ |
| <!ENTITY commonSetup SYSTEM "file:./../../../config/properties.xml"> |
| <!ENTITY commonBuild SYSTEM "file:./../../../config/common.xml"> |
| <!ENTITY testproperties SYSTEM "file:./build.properties"> |
| ]> |
| |
| <project name="RPC Encoded Oneway " default="all" basedir="."> |
| |
| <!-- include common.xml and testcommon.xml --> |
| &commonSetup; |
| &commonBuild; |
| &testproperties; |
| |
| <target name="run.wscompile"> |
| <exec executable="${WSCOMPILE}" failonerror="true" > |
| <arg line="-source 1.1.2 ${wscompile.command}" /> |
| </exec> |
| </target> |
| |
| <!-- NOTE. the simple mapping test and full mapping test can |
| only be run one at a time, I didn't want to set up two |
| tests for this. --> |
| <!-- |
| <target name="all" depends="clean,build,deploy,run,undeploy"/> |
| --> |
| |
| <target name="all" depends="simple-mapping, full-mapping"/> |
| <target name="simple-mapping" |
| depends="build-simple-mapping,deploy,assemble-client, run,undeploy"/> |
| <target name="full-mapping" |
| depends="build-full-mapping,deploy,run,undeploy"/> |
| |
| <target name="compile" depends=""> |
| <antcall target="compile-common"> |
| <param name="src" value="rpcencoded"/> |
| </antcall> |
| </target> |
| |
| <target name="build-simple-mapping" depends="init-common, clean"> |
| <antcall target="wscompile"/> |
| <copy file="NoMetadata.SimpleTest.xml" tofile="${mappingfile.name}"/> |
| <antcall target="assemble"/> |
| </target> |
| |
| <target name="build-full-mapping" depends="init-common, clean"> |
| <delete file="${mappingfile.name}"/> |
| <antcall target="gen-mapping"/> |
| <antcall target="wscompile"/> |
| <antcall target="assemble"/> |
| </target> |
| |
| <target name="assemble" depends="init-common, compile"> |
| <copy todir="${build.classes.dir}/WEB-INF/wsdl" file="SimpleTest.wsdl"/> |
| |
| <!-- nasty workaround for the harness to include the mapping file for wars --> |
| <copy todir="${build.classes.dir}/tmp" file="${mappingfile.name}"/> |
| |
| <antcall target="webclient-war-common"> |
| <param name="hasWebclient" value="yes"/> |
| </antcall> |
| <antcall target="ear-common" /> |
| </target> |
| |
| <target name="assemble-client" depends="init-common"> |
| <antcall target="compile-common"> |
| <param name="src" value="client"/> |
| </antcall> |
| <copy todir="${build.classes.dir}/META-INF/wsdl" |
| file="SimpleTest.wsdl"/> |
| <copy todir="${build.classes.dir}" |
| file="NoMetadata.SimpleTest.xml"/> |
| <unjar src="${env.APS_HOME}/lib/reporter.jar" |
| dest="${build.classes.dir}"/> |
| <antcall target="appclient-jar-common"> |
| <param name="appclientjar.classes" |
| value="NoMetadata.SimpleTest.xml,META-INF/wsdl/**,rpcencoded/*.class,com/**" /> |
| </antcall> |
| <move file="${assemble.dir}/${appname}-client.jar" toFile="${assemble.dir}/${appname}AppClient.jar"/> |
| </target> |
| |
| <target name="run" depends="init-common"> |
| <antcall target="runclient-common"> |
| <param name="appclient.application.args" value="http://${http.host}:${http.port}//RPCEncodedOneway/Hello"/> |
| </antcall> |
| </target> |
| |
| <target name="deploy" |
| depends="init-common"> |
| <antcall target="deploy-common"/> |
| </target> |
| |
| <target name="clean" depends="init-common"> |
| <antcall target="clean-common"/> |
| <delete dir="output"/> |
| <delete dir="vo_output"/> |
| <delete file="${mappingfile.name}"/> |
| <delete file="onewayModel.txt"/> |
| <delete file ="/tmp/debugModel.txt"/> |
| <delete file ="/tmp/debugModel.model"/> |
| </target> |
| |
| <target name="undeploy" depends="init-common"> |
| <antcall target="undeploy-common"/> |
| </target> |
| |
| <target name="wscompile" depends="init-common"> |
| <mkdir dir="vo_output"/> |
| <antcall target="run.wscompile"> |
| <param name="wscompile.command" |
| value="-import -keep -d vo_output -classpath . wscompile_config.xml"/> |
| </antcall> |
| <copy todir="${build.classes.dir}/rpcencoded"> |
| <fileset dir="vo_output/rpcencoded" |
| includes="Hello.class"/> |
| </copy> |
| <delete dir="vo_output"/> |
| </target> |
| |
| |
| <target name="gen-mapping" depends="init-common"> |
| <mkdir dir="output"/> |
| <antcall target="run.wscompile"> |
| <!-- use model --> |
| <!-- |
| <param name="wscompile.command" |
| value="-gen -cp . -keep -d output -Xdebugmodel:onewayModel.txt -model ${mappingfile.name} wscompile_config.xml"/> |
| --> |
| |
| <!-- use mapping --> |
| <param name="wscompile.command" |
| value="-import -cp . -keep -d output -Xdebugmodel:onewayModel.txt -mapping ${mappingfile.name} wscompile_config.xml"/> |
| </antcall> |
| <delete dir="output"/> |
| </target> |
| |
| <target name="usage"> |
| <echo> |
| Usage: |
| ant all (Executes the WebServices test) |
| ant clean |
| </echo> |
| </target> |
| </project> |