axis-c-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Sam Carleton <scarle...@gmail.com>
Subject Re: [OT] wsdl services, binding, and ports
Date Sat, 04 Apr 2009 06:09:07 GMT
On Fri, Apr 3, 2009 at 4:20 PM, Samisa Abeysinghe <samisa@wso2.com> wrote:
> The following articles are on WSDL tool of Axis2. In addtion to Axis2 tool,
> it also talks about various aspects of WSDL.
>
> http://wso2.org/library/2873
>
> http://wso2.org/library/2935

Samisa,

Thank you for the links, they are very helpful.  Unfortunately neither
one answers my original off topic question:

Is it possible to have multiple port types in one WSDL.  I have tried
to create a WSDL with two port's, both with one operation, the WSDL
seems to validate correctly.  When I run WSDL2C, it only creates one
of the operations.  I don't know if what I am trying to do is
impossible or I am doing something wrong.  At the bottom is my WSDL.

Sam

-----------------------------------------------
<?xml version="1.0" encoding="UTF-8" standalone="no"?>
<wsdl:definitions xmlns:soap="http://schemas.xmlsoap.org/wsdl/soap/"
xmlns:tns="urn:mmpp:pasadena"
xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/"
xmlns:xsd="http://www.w3.org/2001/XMLSchema"
xmlns:ns="http://schemas.xmlsoap.org/soap/encoding/"
name="NodeManager" targetNamespace="urn:mmpp:pasadena">
	<wsdl:types>
		<xsd:schema targetNamespace="urn:mmpp:pasadena">
			<xsd:element name="getNode">
				<xsd:complexType>
					<xsd:sequence>
						<xsd:element name="nodeId" type="xsd:string"/>
						<xsd:element name="userId" type="xsd:string"/>
					</xsd:sequence>
				</xsd:complexType>
			</xsd:element>
			<xsd:element name="getNodeResponse">
				<xsd:complexType>
					<xsd:sequence>
						<xsd:element name="currentNode" type="tns:NodeType"/>
					</xsd:sequence>
				</xsd:complexType>
			</xsd:element>
			<xsd:complexType name="NodeType">
				<xsd:sequence>
					<xsd:element name="objectId" type="xsd:string"/>
					<xsd:element name="name" type="xsd:string"/>
					<xsd:element name="parentNode" type="tns:NodeType" nillable="true"/>
					<xsd:element name="areChildrenGalleries" type="xsd:boolean"
nillable="true"/>
					<xsd:element name="children" type="tns:NodeType" minOccurs="0"
maxOccurs="unbounded"/>
				</xsd:sequence>
			</xsd:complexType>
			<xsd:element name="getCarts">
				<xsd:complexType>
					<xsd:sequence>
						<xsd:element name="nodeId" type="xsd:string"/>
					</xsd:sequence>
				</xsd:complexType>
			</xsd:element>
			<xsd:element name="getCartsResponse">
				<xsd:complexType>
					<xsd:sequence>
						<xsd:element name="carts" type="xsd:string"/>
					</xsd:sequence>
				</xsd:complexType>
			</xsd:element>
		</xsd:schema>
	</wsdl:types>
	<wsdl:message name="getNodeRequest">
		<wsdl:part name="parameters" element="tns:getNode"/>
	</wsdl:message>
	<wsdl:message name="getNodeResponse">
		<wsdl:part name="parameters" element="tns:getNodeResponse"/>
	</wsdl:message>
	<wsdl:message name="getCartsRequest">
		<wsdl:part name="parameters" element="tns:getCarts"/>
	</wsdl:message>
	<wsdl:message name="getCartsResponse">
		<wsdl:part name="parameters" element="tns:getCartsResponse"/>
	</wsdl:message>
	
	<wsdl:portType name="NodeManager">
		<wsdl:operation name="getNode">
			<wsdl:input message="tns:getNodeRequest"/>
			<wsdl:output message="tns:getNodeResponse"/>
		</wsdl:operation>
	</wsdl:portType>
	
	<wsdl:portType name="CartService">
		<wsdl:operation name="getCarts">
			<wsdl:input message="tns:getCartsRequest"/>
			<wsdl:output message="tns:getCartsResponse"/>
		</wsdl:operation>
	</wsdl:portType>

	<wsdl:binding name="NodeManagerSOAP" type="tns:NodeManager">
		<soap:binding style="document"
transport="http://schemas.xmlsoap.org/soap/http"/>
		<wsdl:operation name="getNode">
			<soap:operation soapAction="urn:mmpp:NodeManager/getNode"/>
			<wsdl:input>
				<soap:body use="literal"/>
			</wsdl:input>
			<wsdl:output>
				<soap:body use="literal"/>
			</wsdl:output>
		</wsdl:operation>
	</wsdl:binding>
	
	<wsdl:binding name="CartServiceSOAP" type="tns:CartService">
		<soap:binding style="document"
transport="http://schemas.xmlsoap.org/soap/http"/>
		<wsdl:operation name="getCarts">
			<soap:operation soapAction="urn:mmpp:CartService/getCarts"/>
			<wsdl:input>
				<soap:body use="literal"/>
			</wsdl:input>
			<wsdl:output>
				<soap:body use="literal"/>
			</wsdl:output>
		</wsdl:operation>
	</wsdl:binding>
	
	<wsdl:service name="Pasadena">
		<wsdl:port name="CartServiceSOAP" binding="tns:CartServiceSOAP">
			<soap:address location="http://localhost/axis2/services/CartService"/>
		</wsdl:port>
		<wsdl:port name="NodeManagerSOAP" binding="tns:NodeManagerSOAP">
			<soap:address location="http://localhost/axis2/services/NodeManager"/>
		</wsdl:port>
	</wsdl:service>
</wsdl:definitions>

Mime
View raw message