You are viewing a plain text version of this content. The canonical link for it is here.
Posted to pubscribe-commits@ws.apache.org by ip...@apache.org on 2005/07/11 21:44:52 UTC
svn commit: r210191 - in /webservices/pubscribe/trunk/src/template: ./
ReadMe.txt _TEMPLATE_.wsdl build.properties build.xml soapclient.xml
Author: ips
Date: Mon Jul 11 12:44:50 2005
New Revision: 210191
URL: http://svn.apache.org/viewcvs?rev=210191&view=rev
Log:
template app
Added:
webservices/pubscribe/trunk/src/template/
webservices/pubscribe/trunk/src/template/ReadMe.txt
webservices/pubscribe/trunk/src/template/_TEMPLATE_.wsdl
webservices/pubscribe/trunk/src/template/build.properties
webservices/pubscribe/trunk/src/template/build.xml
webservices/pubscribe/trunk/src/template/soapclient.xml
Added: webservices/pubscribe/trunk/src/template/ReadMe.txt
URL: http://svn.apache.org/viewcvs/webservices/pubscribe/trunk/src/template/ReadMe.txt?rev=210191&view=auto
==============================================================================
--- webservices/pubscribe/trunk/src/template/ReadMe.txt (added)
+++ webservices/pubscribe/trunk/src/template/ReadMe.txt Mon Jul 11 12:44:50 2005
@@ -0,0 +1,2 @@
+Pubscribe application template
+==============================
Added: webservices/pubscribe/trunk/src/template/_TEMPLATE_.wsdl
URL: http://svn.apache.org/viewcvs/webservices/pubscribe/trunk/src/template/_TEMPLATE_.wsdl?rev=210191&view=auto
==============================================================================
--- webservices/pubscribe/trunk/src/template/_TEMPLATE_.wsdl (added)
+++ webservices/pubscribe/trunk/src/template/_TEMPLATE_.wsdl Mon Jul 11 12:44:50 2005
@@ -0,0 +1,439 @@
+<?xml version="1.0"?>
+
+<definitions name="MyDefinition"
+ targetNamespace="http://abc.com/my/wsdl/namespace"
+ xmlns="http://schemas.xmlsoap.org/wsdl/"
+ xmlns:tns="http://abc.com/my/wsdl/namespace"
+ xmlns:xsd="http://www.w3.org/2001/XMLSchema"
+ xmlns:soap="http://schemas.xmlsoap.org/wsdl/soap/"
+ xmlns:wsrp="http://docs.oasis-open.org/wsrf/2004/06/wsrf-WS-ResourceProperties-1.2-draft-01.xsd"
+ xmlns:wsrpw="http://docs.oasis-open.org/wsrf/2004/06/wsrf-WS-ResourceProperties-1.2-draft-01.wsdl"
+ xmlns:wsrlw="http://docs.oasis-open.org/wsrf/2004/06/wsrf-WS-ResourceLifetime-1.2-draft-01.wsdl"
+ xmlns:wsntw="http://docs.oasis-open.org/wsn/2004/06/wsn-WS-BaseNotification-1.2-draft-01.wsdl"
+ xmlns:mex="http://schemas.xmlsoap.org/ws/2004/09/mex"
+ xmlns:wsa04="http://schemas.xmlsoap.org/ws/2004/08/addressing">
+
+ <import namespace="http://docs.oasis-open.org/wsrf/2004/06/wsrf-WS-ResourceProperties-1.2-draft-01.wsdl"
+ location="../spec/wsrf/WS-ResourceProperties-1_2-Draft_01.wsdl"/>
+
+ <import namespace="http://docs.oasis-open.org/wsrf/2004/06/wsrf-WS-ResourceLifetime-1.2-draft-01.wsdl"
+ location="../spec/wsrf/WS-ResourceLifetime-1_2-Draft_01.wsdl"/>
+
+ <import namespace="http://docs.oasis-open.org/wsn/2004/06/wsn-WS-BaseNotification-1.2-draft-01.wsdl"
+ location="../spec/wsn/WS-BaseNotification-1_2-Draft_01.wsdl"/>
+
+ <types>
+ <schema elementFormDefault="qualified"
+ targetNamespace="http://abc.com/my/wsdl/namespace"
+ xmlns="http://www.w3.org/2001/XMLSchema"
+ xmlns:xsd="http://www.w3.org/2001/XMLSchema"
+ xmlns:wsrl="http://docs.oasis-open.org/wsrf/2004/06/wsrf-WS-ResourceLifetime-1.2-draft-01.xsd"
+ xmlns:wsbf="http://docs.oasis-open.org/wsrf/2004/06/wsrf-WS-BaseFaults-1.2-draft-01.xsd"
+ xmlns:wsnt="http://docs.oasis-open.org/wsn/2004/06/wsn-WS-BaseNotification-1.2-draft-01.xsd">
+
+ <xsd:import namespace="http://docs.oasis-open.org/wsrf/2004/06/wsrf-WS-BaseFaults-1.2-draft-01.xsd"
+ schemaLocation="../spec/wsrf/WS-BaseFaults-1_2-Draft_01.xsd"/>
+
+ <xsd:import namespace="http://docs.oasis-open.org/wsrf/2004/06/wsrf-WS-ResourceLifetime-1.2-draft-01.xsd"
+ schemaLocation="../spec/wsrf/WS-ResourceLifetime-1_2.xsd"/>
+
+ <xsd:import namespace="http://docs.oasis-open.org/wsn/2004/06/wsn-WS-BaseNotification-1.2-draft-01.xsd"
+ schemaLocation="../spec/wsn/WS-BaseNotification-1_2-Draft_01.xsd"/>
+
+ <!-- *** Add an element definition here for each of your custom resource properties *** -->
+ <!-- *** e.g.: <element name="MyProperty" type="xsd:string" /> *** -->
+
+ <!-- Resource Properties Document Schema -->
+ <element name="ResourceProperties">
+ <complexType>
+ <sequence>
+
+ <!-- *** If you wish to implement the wsrl:ScheduledResourceTermination portType,
+ uncomment the below two lines *** -->
+ <!--
+ <element ref="wsrl:CurrentTime" />
+ <element ref="wsrl:TerminationTime" />
+ -->
+
+ <!-- *** If you wish to implement the wsnt:NotificationProducer portType,
+ uncomment the below three lines *** -->
+ <!--
+ <element ref="wsnt:Topic" maxOccurs="unbounded" />
+ <element ref="wsnt:FixedTopicSet" />
+ <element ref="wsnt:TopicExpressionDialects" maxOccurs="unbounded" />
+ -->
+
+ <!-- *** Add an element ref here for each of the custom resource property elements you defined above *** -->
+ <!-- *** e.g.: <element ref="tns:MyProperty" /> (NOTE: default is minOccurs="1" and maxOccurs="1") *** -->
+ <!-- *** or: <element ref="tns:MyOtherProperty" minOccurs="0" maxOccurs="unbounded" /> *** -->
+
+ <!-- *** Uncomment the below any element if you want to permit resource property elements
+ with arbitrary names (not generally recommended) *** -->
+ <!--
+ <any minOccurs="0" maxOccurs="unbounded" namespace="##other" processContents="lax"/>
+ -->
+
+ </sequence>
+ </complexType>
+ </element>
+
+ <!-- *** Add element definitions for custom request/response/fault types here *** -->
+
+ </schema>
+ </types>
+
+ <!-- *** Add message definitions for custom request/response/fault types here *** -->
+
+ <portType name="MyPortType" wsrp:ResourceProperties="tns:ResourceProperties">
+
+ <operation name="GetResourceProperty">
+ <input name="GetResourcePropertyRequest" message="wsrpw:GetResourcePropertyRequest"/>
+ <output name="GetResourcePropertyResponse" message="wsrpw:GetResourcePropertyResponse"/>
+ <fault name="ResourceUnknownFault" message="wsrpw:ResourceUnknownFault"/>
+ <fault name="InvalidResourcePropertyQNameFault" message="wsrpw:InvalidResourcePropertyQNameFault"/>
+ </operation>
+
+ <!-- *** If you wish to implement the WSRP GetMultipleResourceProperties portType,
+ uncomment the below operation block *** -->
+ <!--
+ <operation name="GetMultipleResourceProperties">
+ <input name="GetMultipleResourcePropertiesRequest" message="wsrpw:GetMultipleResourcePropertiesRequest"/>
+ <output name="GetMultipleResourcePropertiesResponse" message="wsrpw:GetMultipleResourcePropertiesResponse"/>
+ <fault name="ResourceUnknownFault" message="wsrpw:ResourceUnknownFault"/>
+ <fault name="InvalidResourcePropertyQNameFault" message="wsrpw:InvalidResourcePropertyQNameFault"/>
+ </operation>
+ -->
+
+ <!-- *** If you wish to implement the WSRP SetResourceProperties portType,
+ uncomment the below operation block *** -->
+ <!--
+ <operation name="SetResourceProperties">
+ <input name="SetResourcePropertiesRequest" message="wsrpw:SetResourcePropertiesRequest"/>
+ <output name="SetResourcePropertiesResponse" message="wsrpw:SetResourcePropertiesResponse"/>
+ <fault name="ResourceUnknownFault" message="wsrpw:ResourceUnknownFault"/>
+ <fault name="InvalidResourcePropertyQNameFault" message="wsrpw:InvalidResourcePropertyQNameFault"/>
+ <fault name="InvalidSetResourcePropertiesRequestContentFault" message="wsrpw:InvalidSetResourcePropertiesRequestContentFault"/>
+ <fault name="UnableToModifyResourcePropertyFault" message="wsrpw:UnableToModifyResourcePropertyFault"/>
+ <fault name="SetResourcePropertyRequestFailedFault" message="wsrpw:SetResourcePropertyRequestFailedFault"/>
+ </operation>
+ -->
+
+ <!-- *** If you wish to implement the WSRP QueryResourceProperties portType,
+ uncomment the below operation block *** -->
+ <!--
+ <operation name="QueryResourceProperties">
+ <input name="QueryResourcePropertiesRequest" message="wsrpw:QueryResourcePropertiesRequest"/>
+ <output name="QueryResourcePropertiesResponse" message="wsrpw:QueryResourcePropertiesResponse"/>
+ <fault name="ResourceUnknownFault" message="wsrpw:ResourceUnknownFault"/>
+ <fault name="InvalidResourcePropertyQNameFault" message="wsrpw:InvalidResourcePropertyQNameFault"/>
+ <fault name="UnknownQueryExpressionDialectFault" message="wsrpw:UnknownQueryExpressionDialectFault"/>
+ <fault name="InvalidQueryExpressionFault" message="wsrpw:InvalidQueryExpressionFault"/>
+ <fault name="QueryEvaluationErrorFault" message="wsrpw:QueryEvaluationErrorFault"/>
+ </operation>
+ -->
+
+ <!-- *** If you wish to implement the WSRL ImmediateResourceTermination portType,
+ uncomment the below operation block *** -->
+ <!--
+ <operation name="Destroy">
+ <input message="wsrlw:DestroyRequest"/>
+ <output message="wsrlw:DestroyResponse"/>
+ <fault name="ResourceUnknownFault" message="wsrlw:ResourceUnknownFault"/>
+ <fault name="ResourceNotDestroyedFault" message="wsrlw:ResourceNotDestroyedFault"/>
+ </operation>
+ -->
+
+ <!-- *** If you wish to implement the WSRL ScheduledResourceTermination portType,
+ uncomment the below operation block *** -->
+ <!--
+ <operation name="SetTerminationTime">
+ <input message="wsrlw:SetTerminationTimeRequest"/>
+ <output message="wsrlw:SetTerminationTimeResponse"/>
+ <fault name="ResourceUnknownFault" message="wsrlw:ResourceUnknownFault"/>
+ <fault name="UnableToSetTerminationTimeFault" message="wsrlw:UnableToSetTerminationTimeFault"/>
+ <fault name="TerminationTimeChangeRejectedFault" message="wsrlw:TerminationTimeChangeRejectedFault"/>
+ </operation>
+ -->
+
+ <!-- *** If you wish to implement the WSNT NotificationProducer portType,
+ uncomment the below two operation blocks *** -->
+ <!--
+ <operation name="Subscribe">
+ <input message="wsntw:SubscribeRequest" />
+ <output message="wsntw:SubscribeResponse" />
+ <fault name="ResourceUnknownFault" message="wsntw:ResourceUnknownFault" />
+ <fault name="SubscribeCreationFailedFault" message="wsntw:SubscribeCreationFailedFault" />
+ <fault name="TopicPathDialectUnknownFault" message="wsntw:TopicPathDialectUnknownFault" />
+ </operation>
+
+ <operation name="GetCurrentMessage">
+ <input message="wsntw:GetCurrentMessageRequest" />
+ <output message="wsntw:GetCurrentMessageResponse" />
+ <fault name="ResourceUnknownFault" message="wsntw:ResourceUnknownFault" />
+ <fault name="InvalidTopicExpressionFault" message="wsntw:InvalidTopicExpressionFault" />
+ <fault name="TopicNotSupportedFault" message="wsntw:TopicNotSupportedFault" />
+ <fault name="NoCurrentMessageOnTopicFault" message="wsntw:NoCurrentMessageOnTopicFault" />
+ </operation>
+ -->
+
+ <!-- *** If you wish to implement the WSNT NotificationConsumer portType,
+ uncomment the below two operation blocks *** -->
+ <!--
+ <operation name="Notify">
+ <input name="Notify" message="wsntw:Notify"/>
+ </operation>
+ -->
+
+ <!-- *** If you wish to implement the WS-MetadataExchange MetadataExchange portType,
+ uncomment the below operation block *** -->
+ <!--
+ <operation name="GetMetadata" >
+ <input message="mex:GetMetadataMsg"
+ wsa04:Action="http://schemas.xmlsoap.org/ws/2004/09/mex/GetMetadata/Request" />
+ <output message="mex:GetMetadataResponseMsg"
+ wsa04:Action="http://schemas.xmlsoap.org/ws/2004/09/mex/GetMetadata/Response" />
+ </operation>
+ <operation name="Get" >
+ <input message="mex:GetMsg"
+ wsa04:Action="http://schemas.xmlsoap.org/ws/2004/09/mex/Get/Request" />
+ <output message="mex:GetResponseMsg"
+ wsa04:Action="http://schemas.xmlsoap.org/ws/2004/09/mex/Get/Response" />
+ </operation>
+ -->
+
+ <!-- *** Add an operation block here for each of your custom operations *** -->
+
+ </portType>
+
+ <binding name="MySoapHttpBinding" type="tns:MyPortType">
+
+ <soap:binding style="document" transport="http://schemas.xmlsoap.org/soap/http"/>
+
+ <operation name="GetResourceProperty">
+ <soap:operation style="document"/>
+ <input>
+ <soap:body use="literal"/>
+ </input>
+ <output>
+ <soap:body use="literal"/>
+ </output>
+ <fault name="ResourceUnknownFault">
+ <soap:fault name="ResourceUnknownFault" use="literal"/>
+ </fault>
+ <fault name="InvalidResourcePropertyQNameFault">
+ <soap:fault name="InvalidResourcePropertyQNameFault" use="literal"/>
+ </fault>
+ </operation>
+
+ <!-- *** If you wish to implement the WSRP GetMultipleResourceProperties portType,
+ uncomment the below operation block *** -->
+ <!--
+ <operation name="GetMultipleResourceProperties">
+ <soap:operation style="document"/>
+ <input>
+ <soap:body use="literal"/>
+ </input>
+ <output>
+ <soap:body use="literal"/>
+ </output>
+ <fault name="ResourceUnknownFault">
+ <soap:fault name="ResourceUnknownFault" use="literal"/>
+ </fault>
+ <fault name="InvalidResourcePropertyQNameFault">
+ <soap:fault name="InvalidResourcePropertyQNameFault" use="literal"/>
+ </fault>
+ </operation>
+ -->
+
+ <!-- *** If you wish to implement the WSRP SetResourceProperties portType,
+ uncomment the below operation block *** -->
+ <!--
+ <operation name="SetResourceProperties">
+ <soap:operation style="document"/>
+ <input>
+ <soap:body use="literal"/>
+ </input>
+ <output>
+ <soap:body use="literal"/>
+ </output>
+ <fault name="ResourceUnknownFault">
+ <soap:fault name="ResourceUnknownFault" use="literal"/>
+ </fault>
+ <fault name="InvalidResourcePropertyQNameFault">
+ <soap:fault name="InvalidResourcePropertyQNameFault" use="literal"/>
+ </fault>
+ <fault name="UnableToModifyResourcePropertyFault">
+ <soap:fault name="UnableToModifyResourcePropertyFault" use="literal"/>
+ </fault>
+ <fault name="InvalidSetResourcePropertiesRequestContentFault">
+ <soap:fault name="InvalidSetResourcePropertiesRequestContentFault" use="literal"/>
+ </fault>
+ <fault name="SetResourcePropertyRequestFailedFault">
+ <soap:fault name="SetResourcePropertyRequestFailedFault" use="literal"/>
+ </fault>
+ </operation>
+ -->
+
+ <!-- *** If you wish to implement the WSRP QueryResourceProperties portType,
+ uncomment the below operation block *** -->
+ <!--
+ <operation name="QueryResourceProperties">
+ <soap:operation style="document"/>
+ <input>
+ <soap:body use="literal"/>
+ </input>
+ <output>
+ <soap:body use="literal"/>
+ </output>
+ <fault name="ResourceUnknownFault">
+ <soap:fault name="ResourceUnknownFault" use="literal"/>
+ </fault>
+ <fault name="InvalidResourcePropertyQNameFault">
+ <soap:fault name="InvalidResourcePropertyQNameFault" use="literal"/>
+ </fault>
+ <fault name="UnknownQueryExpressionDialectFault">
+ <soap:fault name="UnknownQueryExpressionDialectFault" use="literal"/>
+ </fault>
+ <fault name="InvalidQueryExpressionFault">
+ <soap:fault name="InvalidQueryExpressionFault" use="literal"/>
+ </fault>
+ <fault name="QueryEvaluationErrorFault">
+ <soap:fault name="QueryEvaluationErrorFault" use="literal"/>
+ </fault>
+ </operation>
+ -->
+
+ <!-- *** If you wish to implement the WSRL ImmediateResourceTermination portType,
+ uncomment the below operation block *** -->
+ <!--
+ <operation name="Destroy">
+ <soap:operation style="document"/>
+ <input>
+ <soap:body use="literal"/>
+ </input>
+ <output>
+ <soap:body use="literal"/>
+ </output>
+ <fault name="ResourceUnknownFault">
+ <soap:fault name="ResourceUnknownFault" use="literal"/>
+ </fault>
+ <fault name="ResourceNotDestroyedFault">
+ <soap:fault name="ResourceNotDestroyedFault" use="literal"/>
+ </fault>
+ </operation>
+ -->
+
+ <!-- *** If you wish to implement the WSRL ScheduledResourceTermination portType,
+ uncomment the below operation block *** -->
+ <!--
+ <operation name="SetTerminationTime">
+ <soap:operation style="document"/>
+ <input>
+ <soap:body use="literal"/>
+ </input>
+ <output>
+ <soap:body use="literal"/>
+ </output>
+ <fault name="ResourceUnknownFault">
+ <soap:fault name="ResourceUnknownFault" use="literal"/>
+ </fault>
+ <fault name="UnableToSetTerminationTimeFault">
+ <soap:fault name="UnableToSetTerminationTimeFault" use="literal"/>
+ </fault>
+ <fault name="TerminationTimeChangeRejectedFault">
+ <soap:fault name="TerminationTimeChangeRejectedFault" use="literal"/>
+ </fault>
+ </operation>
+ -->
+
+ <!-- *** If you wish to implement the WSNT NotificationProducer portType,
+ uncomment the below two operation blocks *** -->
+ <!--
+ <operation name="Subscribe">
+ <soap:operation style="document"/>
+ <input>
+ <soap:body use="literal"/>
+ </input>
+ <output>
+ <soap:body use="literal"/>
+ </output>
+ <fault name="ResourceUnknownFault">
+ <soap:fault name="ResourceUnknownFault" use="literal"/>
+ </fault>
+ <fault name="SubscribeCreationFailedFault">
+ <soap:fault name="SubscribeCreationFailedFault" use="literal"/>
+ </fault>
+ <fault name="TopicPathDialectUnknownFault">
+ <soap:fault name="TopicPathDialectUnknownFault" use="literal"/>
+ </fault>
+ </operation>
+ <operation name="GetCurrentMessage">
+ <soap:operation style="document"/>
+ <input>
+ <soap:body use="literal"/>
+ </input>
+ <output>
+ <soap:body use="literal"/>
+ </output>
+ <fault name="ResourceUnknownFault">
+ <soap:fault name="ResourceUnknownFault" use="literal"/>
+ </fault>
+ <fault name="InvalidTopicExpressionFault">
+ <soap:fault name="InvalidTopicExpressionFault" use="literal"/>
+ </fault>
+ <fault name="TopicNotSupportedFault">
+ <soap:fault name="TopicPathDialectUnknownFault" use="literal"/>
+ </fault>
+ <fault name="NoCurrentMessageOnTopicFault">
+ <soap:fault name="NoCurrentMessageOnTopicFault" use="literal"/>
+ </fault>
+ </operation>
+ -->
+
+ <!-- *** If you wish to implement the WSNT NotificationConsumer portType,
+ uncomment the below two operation blocks *** -->
+ <!--
+ <operation name="Notify">
+ <soap:operation style="document"/>
+ <input>
+ <soap:body use="literal"/>
+ </input>
+ </operation>
+ -->
+
+ <!-- *** If you wish to implement the WS-MetadataExchange MetadataExchange portType,
+ uncomment the below operation block *** -->
+ <!--
+ <operation name="GetMetadata" >
+ <soap:operation style="document"/>
+ <input>
+ <soap:body use="literal"/>
+ </input>
+ <output>
+ <soap:body use="literal"/>
+ </output>
+ </operation>
+ <operation name="Get" >
+ <soap:operation style="document"/>
+ <input>
+ <soap:body use="literal"/>
+ </input>
+ <output>
+ <soap:body use="literal"/>
+ </output>
+ </operation>
+ -->
+
+ <!-- *** Add an operation block here for each of your custom operations *** -->
+
+ </binding>
+
+ <service name="MyService">
+ <!-- Note: the port name becomes the service name in the wsdd generated by Wsdl2Java -->
+ <!-- *** Change the port name and the soap:address location below to reflect the desired endpoint URL *** -->
+ <port name="MyPort" binding="tns:MySoapHttpBinding">
+ <soap:address location="http://localhost:8080/wsrf/services/MyPort" />
+ </port>
+ </service>
+
+</definitions>
Added: webservices/pubscribe/trunk/src/template/build.properties
URL: http://svn.apache.org/viewcvs/webservices/pubscribe/trunk/src/template/build.properties?rev=210191&view=auto
==============================================================================
--- webservices/pubscribe/trunk/src/template/build.properties (added)
+++ webservices/pubscribe/trunk/src/template/build.properties Mon Jul 11 12:44:50 2005
@@ -0,0 +1,12 @@
+base.url=http://localhost:8080/pubscribe/services
+
+# Uncomment and modify the below entry to point to the deployed
+# pubscribe webapp directory (e.g. ${env.CATALINA_HOME}/webapps/pubscribe).
+
+#pubscribe.webapp.dir=${env.CATALINA_HOME}/webapps/pubscribe
+
+# Uncomment and modify the below lines if you require a proxy to connect to external web sites
+
+#http.proxyHost=proxy.xyz.com
+#http.proxyPort=8088
+#http.nonProxyHosts=localhost
Added: webservices/pubscribe/trunk/src/template/build.xml
URL: http://svn.apache.org/viewcvs/webservices/pubscribe/trunk/src/template/build.xml?rev=210191&view=auto
==============================================================================
--- webservices/pubscribe/trunk/src/template/build.xml (added)
+++ webservices/pubscribe/trunk/src/template/build.xml Mon Jul 11 12:44:50 2005
@@ -0,0 +1,77 @@
+<?xml version="1.0"?>
+
+<project name="generate" default="usage" basedir=".">
+
+ <property environment="env" />
+ <property file="build.properties" />
+ <property file="../build.properties" />
+
+ <!-- workaround for those IDEs that dont set ant.home as per the ant script -->
+ <property name="ant.home" value="env.ANT_HOME"/>
+
+ <property name="out.dir" location="generated"/>
+ <property name="lib.dir" location="${out.dir}/.xmlbeans/lib"/>
+ <property name="source.wsdl" location="${basedir}" />
+
+ <target name="init">
+
+ <available file="../../webapps/pubscribe" type="dir" property="dist.pubscribe.webapp.dir" value="../../webapps/pubscribe" />
+ <condition property="pubscribe.webapp.dir" value="${dist.pubscribe.webapp.dir}">
+ <isset property="dist.pubscribe.webapp.dir"/>
+ </condition>
+
+ <fail unless="pubscribe.webapp.dir" message="webapp dir ../../webapps/pubscribe does not exist." />
+ <echo>Using webapp dir: ${pubscribe.webapp.dir}</echo>
+ <mkdir dir="${lib.dir}" />
+ <path id="pubscribe.classpath.id">
+ <pathelement location="${pubscribe.webapp.dir}/WEB-INF/classes" />
+ <fileset dir="${pubscribe.webapp.dir}/WEB-INF/lib" includes="*.jar" />
+ <fileset dir="${lib.dir}" includes="*.jar" />
+ <pathelement location="${activation.jar}" />
+ <pathelement location="${mail.jar}" />
+ </path>
+ <property name="pubscribe.classpath" refid="pubscribe.classpath.id" />
+
+ </target>
+
+ <target name="generate"
+ depends="init"
+ description="generate Axis service classes and XMLBeans types for a WSN WSDL">
+
+ <property name="tmp.dir" location="${pubscribe.webapp.dir}/_tmp_" />
+ <mkdir dir="${tmp.dir}" />
+ <copy todir="${tmp.dir}" overwrite="true" >
+ <fileset dir="${source.wsdl}">
+ <include name="**/*.wsdl"/>
+ <include name="**/*.xsd"/>
+ <exclude name="_TEMPLATE_.wsdl"/>
+ </fileset>
+ </copy>
+ <mkdir dir="${pubscribe.webapp.dir}/wsdl" />
+
+ <taskdef name="wsdl2Java" classname="org.apache.ws.notification.tool.WsnWsdl2JavaTask" classpath="${pubscribe.classpath}" />
+
+ <wsdl2Java outputDir="${out.dir}"
+ classpath="${pubscribe.classpath}"
+ verbose="false"
+ proxyHost="${http.proxyHost}"
+ proxyPort="${http.proxyPort}"
+ nonProxyHosts="${http.nonProxyHosts}">
+ <wsdls dir="${tmp.dir}">
+ <include name="**/*.wsdl" />
+ </wsdls>
+ </wsdl2Java>
+
+ <delete dir="${tmp.dir}" />
+
+ </target>
+
+ <target name="usage">
+ <java classname="org.apache.tools.ant.Main">
+ <arg value="-buildfile" />
+ <arg value="${ant.file}" />
+ <arg value="-projecthelp" />
+ </java>
+ </target>
+
+</project>
Added: webservices/pubscribe/trunk/src/template/soapclient.xml
URL: http://svn.apache.org/viewcvs/webservices/pubscribe/trunk/src/template/soapclient.xml?rev=210191&view=auto
==============================================================================
--- webservices/pubscribe/trunk/src/template/soapclient.xml (added)
+++ webservices/pubscribe/trunk/src/template/soapclient.xml Mon Jul 11 12:44:50 2005
@@ -0,0 +1,63 @@
+<?xml version="1.0"?>
+
+<project name="soapClient" default="sendRequest" basedir=".">
+
+ <property environment="env" />
+ <property file="build.properties" />
+ <property file="../build.properties" />
+
+ <!-- workaround for those IDEs that dont set ant.home as per the ant script -->
+ <property name="ant.home" value="env.ANT_HOME"/>
+
+
+ <target name="init">
+
+ <available file="../../webapps/wsrf" type="dir" property="dist.wsrf.webapp.dir" value="../../webapps/wsrf" />
+ <condition property="wsrf.webapp.dir" value="${dist.wsrf.webapp.dir}">
+ <isset property="dist.wsrf.webapp.dir"/>
+ </condition>
+ <fail unless="wsrf.webapp.dir" message="webapp dir ../../webapps/wsrf does not exist." />
+ <echo>Using webapp dir: ${wsrf.webapp.dir}</echo>
+
+ <path id="wsrf.classpath.id">
+ <pathelement location="${wsrf.webapp.dir}/WEB-INF/classes" />
+ <fileset dir="${wsrf.webapp.dir}/WEB-INF/lib" includes="*.jar" />
+ <pathelement location="${activation.jar}" />
+ <pathelement location="${mail.jar}" />
+ </path>
+ <property name="wsrf.classpath" refid="wsrf.classpath.id" />
+
+ </target>
+
+ <target name="sendRequest"
+ depends="init"
+ description="sends a SOAP request">
+
+ <fail unless="url" message="Please set the url property via -Durl=... when invoking this script." />
+ <fail unless="xml" message="Please set the xml property via -Dxml=... when invoking this script." />
+ <echo>Reading SOAP request from: ${xml} ,,,</echo>
+ <available file="${xml}" property="xml.exists" />
+ <fail unless="xml.exists" message="The specified request XML file ${xml} does not exist." />
+ <available file="${xml}" type="file" property="xml.is.file" />
+ <fail unless="xml.is.file" message="The specified request XML file ${xml} exists but is not a file." />
+
+ <echo>Sending SOAP request to ${url} ...</echo>
+ <echo />
+ <echo>========================== REQUEST ============================</echo>
+ <concat><path><pathelement location="${xml}" /></path></concat>
+ <echo />
+ <echo>========================== RESPONSE ============================</echo>
+ <taskdef name="soapClient" classname="org.apache.ws.util.soap.SoapClientTask" classpath="${wsrf.classpath}" />
+ <soapClient serviceURL="${url}" requestFile="${xml}" soapAction="${action}" />
+
+ </target>
+
+ <target name="usage">
+ <java classname="org.apache.tools.ant.Main">
+ <arg value="-buildfile" />
+ <arg value="${ant.file}" />
+ <arg value="-projecthelp" />
+ </java>
+ </target>
+
+</project>