<project name="evo-app-ws-client-build" > 
	
	<import file="common/evo-app-build-common.xml" />
	
	<path id="jaxws.classpath">
		<path refid="lib.tools.classpath"/>
		<pathelement location="${java.home}/../lib/tools.jar" />
	</path>
	
	<target name="receitas-gen-client" depends="app-build" description="generates client">
		<taskdef name="wsimport" classname="com.sun.tools.ws.ant.WsImport">
			<classpath refid="lib.tools.classpath" />
		</taskdef>
		<java fork="false" classname="com.evolute.ssl.InstallCert" classpathref="app.build.classpath">
			<arg value="${app.ws.wsdl.url.host}"/>
			<arg value="${app.ws.wsdl.url.port}"/>
			<arg value="${app.ssl.truststore.file}"/>
			<arg value="${app.ssl.truststore.pass}"/>
			<arg value="true"/>
			<arg value="true"/>
		</java>
		<wsimport fork="false" debug="true" verbose="true" keep="true" sourcedestdir="${app.src.dir}" package="${app.ws.dest.package}" wsdl="${app.ws.wsdl.url}">
			<jvmarg value="-Djavax.net.ssl.trustStore=${basedir}/jssecacerts" />
			<jvmarg value="-Djavax.net.ssl.trustStorePassword=changeit" />
			<jvmarg value="-Djavax.net.ssl.keyStore=${basedir}/jssecacerts" />
			<jvmarg value="-Djavax.net.ssl.keyStorePassword=changeit" />
		</wsimport>
	</target>
	
</project>