summaryrefslogtreecommitdiff
path: root/ruby_1_8_5/test/wsdl/raa
diff options
context:
space:
mode:
Diffstat (limited to 'ruby_1_8_5/test/wsdl/raa')
-rw-r--r--ruby_1_8_5/test/wsdl/raa/RAA.rb243
-rw-r--r--ruby_1_8_5/test/wsdl/raa/RAAServant.rb99
-rw-r--r--ruby_1_8_5/test/wsdl/raa/RAAService.rb100
-rw-r--r--ruby_1_8_5/test/wsdl/raa/README.txt8
-rw-r--r--ruby_1_8_5/test/wsdl/raa/raa.wsdl264
-rw-r--r--ruby_1_8_5/test/wsdl/raa/server.rb103
-rw-r--r--ruby_1_8_5/test/wsdl/raa/test_raa.rb71
7 files changed, 888 insertions, 0 deletions
diff --git a/ruby_1_8_5/test/wsdl/raa/RAA.rb b/ruby_1_8_5/test/wsdl/raa/RAA.rb
new file mode 100644
index 0000000000..aff0525480
--- /dev/null
+++ b/ruby_1_8_5/test/wsdl/raa/RAA.rb
@@ -0,0 +1,243 @@
+# http://www.ruby-lang.org/xmlns/soap/interface/RAA/0.0.2/
+class Category
+ @@schema_type = "Category"
+ @@schema_ns = "http://www.ruby-lang.org/xmlns/soap/interface/RAA/0.0.2/"
+
+ def major
+ @major
+ end
+
+ def major=(value)
+ @major = value
+ end
+
+ def minor
+ @minor
+ end
+
+ def minor=(value)
+ @minor = value
+ end
+
+ def initialize(major = nil,
+ minor = nil)
+ @major = major
+ @minor = minor
+ end
+end
+
+# http://www.ruby-lang.org/xmlns/soap/interface/RAA/0.0.2/
+class Product
+ @@schema_type = "Product"
+ @@schema_ns = "http://www.ruby-lang.org/xmlns/soap/interface/RAA/0.0.2/"
+
+ def id
+ @id
+ end
+
+ def id=(value)
+ @id = value
+ end
+
+ def name
+ @name
+ end
+
+ def name=(value)
+ @name = value
+ end
+
+ def short_description
+ @short_description
+ end
+
+ def short_description=(value)
+ @short_description = value
+ end
+
+ def version
+ @version
+ end
+
+ def version=(value)
+ @version = value
+ end
+
+ def status
+ @status
+ end
+
+ def status=(value)
+ @status = value
+ end
+
+ def homepage
+ @homepage
+ end
+
+ def homepage=(value)
+ @homepage = value
+ end
+
+ def download
+ @download
+ end
+
+ def download=(value)
+ @download = value
+ end
+
+ def license
+ @license
+ end
+
+ def license=(value)
+ @license = value
+ end
+
+ def description
+ @description
+ end
+
+ def description=(value)
+ @description = value
+ end
+
+ def initialize(id = nil,
+ name = nil,
+ short_description = nil,
+ version = nil,
+ status = nil,
+ homepage = nil,
+ download = nil,
+ license = nil,
+ description = nil)
+ @id = id
+ @name = name
+ @short_description = short_description
+ @version = version
+ @status = status
+ @homepage = homepage
+ @download = download
+ @license = license
+ @description = description
+ end
+end
+
+# http://www.ruby-lang.org/xmlns/soap/interface/RAA/0.0.2/
+class Owner
+ @@schema_type = "Owner"
+ @@schema_ns = "http://www.ruby-lang.org/xmlns/soap/interface/RAA/0.0.2/"
+
+ def id
+ @id
+ end
+
+ def id=(value)
+ @id = value
+ end
+
+ def email
+ @email
+ end
+
+ def email=(value)
+ @email = value
+ end
+
+ def name
+ @name
+ end
+
+ def name=(value)
+ @name = value
+ end
+
+ def initialize(id = nil,
+ email = nil,
+ name = nil)
+ @id = id
+ @email = email
+ @name = name
+ end
+end
+
+# http://www.ruby-lang.org/xmlns/soap/interface/RAA/0.0.2/
+class Info
+ @@schema_type = "Info"
+ @@schema_ns = "http://www.ruby-lang.org/xmlns/soap/interface/RAA/0.0.2/"
+
+ def category
+ @category
+ end
+
+ def category=(value)
+ @category = value
+ end
+
+ def product
+ @product
+ end
+
+ def product=(value)
+ @product = value
+ end
+
+ def owner
+ @owner
+ end
+
+ def owner=(value)
+ @owner = value
+ end
+
+ def created
+ @created
+ end
+
+ def created=(value)
+ @created = value
+ end
+
+ def updated
+ @updated
+ end
+
+ def updated=(value)
+ @updated = value
+ end
+
+ def initialize(category = nil,
+ product = nil,
+ owner = nil,
+ created = nil,
+ updated = nil)
+ @category = category
+ @product = product
+ @owner = owner
+ @created = created
+ @updated = updated
+ end
+end
+
+# http://www.ruby-lang.org/xmlns/soap/interface/RAA/0.0.2/
+class InfoArray < Array
+ # Contents type should be dumped here...
+ @@schema_type = "InfoArray"
+ @@schema_ns = "http://www.ruby-lang.org/xmlns/soap/interface/RAA/0.0.2/"
+end
+
+# http://www.ruby-lang.org/xmlns/soap/interface/RAA/0.0.2/
+class StringArray < Array
+ # Contents type should be dumped here...
+ @@schema_type = "StringArray"
+ @@schema_ns = "http://www.ruby-lang.org/xmlns/soap/interface/RAA/0.0.2/"
+end
+
+# http://xml.apache.org/xml-soap
+class Map < Array
+ # Contents type should be dumped here...
+ @@schema_type = "Map"
+ @@schema_ns = "http://xml.apache.org/xml-soap"
+end
+
diff --git a/ruby_1_8_5/test/wsdl/raa/RAAServant.rb b/ruby_1_8_5/test/wsdl/raa/RAAServant.rb
new file mode 100644
index 0000000000..68380f8e48
--- /dev/null
+++ b/ruby_1_8_5/test/wsdl/raa/RAAServant.rb
@@ -0,0 +1,99 @@
+class RAABaseServicePortType
+ # SYNOPSIS
+ # getAllListings
+ #
+ # ARGS
+ # N/A
+ #
+ # RETURNS
+ # return StringArray - {http://www.ruby-lang.org/xmlns/soap/interface/RAA/0.0.2/}StringArray
+ #
+ # RAISES
+ # (undefined)
+ #
+ def getAllListings
+ #raise NotImplementedError.new
+ ["ruby", "soap4r"]
+ end
+
+ # SYNOPSIS
+ # getProductTree
+ #
+ # ARGS
+ # N/A
+ #
+ # RETURNS
+ # return Map - {http://xml.apache.org/xml-soap}Map
+ #
+ # RAISES
+ # (undefined)
+ #
+ def getProductTree
+ raise NotImplementedError.new
+ end
+
+ # SYNOPSIS
+ # getInfoFromCategory(category)
+ #
+ # ARGS
+ # category Category - {http://www.ruby-lang.org/xmlns/soap/interface/RAA/0.0.2/}Category
+ #
+ # RETURNS
+ # return InfoArray - {http://www.ruby-lang.org/xmlns/soap/interface/RAA/0.0.2/}InfoArray
+ #
+ # RAISES
+ # (undefined)
+ #
+ def getInfoFromCategory(category)
+ raise NotImplementedError.new
+ end
+
+ # SYNOPSIS
+ # getModifiedInfoSince(timeInstant)
+ #
+ # ARGS
+ # timeInstant - {http://www.w3.org/2001/XMLSchema}dateTime
+ #
+ # RETURNS
+ # return InfoArray - {http://www.ruby-lang.org/xmlns/soap/interface/RAA/0.0.2/}InfoArray
+ #
+ # RAISES
+ # (undefined)
+ #
+ def getModifiedInfoSince(timeInstant)
+ raise NotImplementedError.new
+ end
+
+ # SYNOPSIS
+ # getInfoFromName(productName)
+ #
+ # ARGS
+ # productName - {http://www.w3.org/2001/XMLSchema}string
+ #
+ # RETURNS
+ # return Info - {http://www.ruby-lang.org/xmlns/soap/interface/RAA/0.0.2/}Info
+ #
+ # RAISES
+ # (undefined)
+ #
+ def getInfoFromName(productName)
+ raise NotImplementedError.new
+ end
+
+ # SYNOPSIS
+ # getInfoFromOwnerId(ownerId)
+ #
+ # ARGS
+ # ownerId - {http://www.w3.org/2001/XMLSchema}int
+ #
+ # RETURNS
+ # return InfoArray - {http://www.ruby-lang.org/xmlns/soap/interface/RAA/0.0.2/}InfoArray
+ #
+ # RAISES
+ # (undefined)
+ #
+ def getInfoFromOwnerId(ownerId)
+ raise NotImplementedError.new
+ end
+end
+
diff --git a/ruby_1_8_5/test/wsdl/raa/RAAService.rb b/ruby_1_8_5/test/wsdl/raa/RAAService.rb
new file mode 100644
index 0000000000..9d0813304c
--- /dev/null
+++ b/ruby_1_8_5/test/wsdl/raa/RAAService.rb
@@ -0,0 +1,100 @@
+#!/usr/bin/env ruby
+require 'RAAServant.rb'
+
+require 'soap/rpc/standaloneServer'
+
+class RAABaseServicePortType
+ MappingRegistry = SOAP::Mapping::Registry.new
+
+ MappingRegistry.set(
+ StringArray,
+ ::SOAP::SOAPArray,
+ ::SOAP::Mapping::Registry::TypedArrayFactory,
+ { :type => XSD::QName.new("http://www.w3.org/2001/XMLSchema", "string") }
+ )
+ MappingRegistry.set(
+ Map,
+ ::SOAP::SOAPArray,
+ ::SOAP::Mapping::Registry::TypedArrayFactory,
+ { :type => XSD::QName.new("http://www.w3.org/2001/XMLSchema", "anyType") }
+ )
+ MappingRegistry.set(
+ Category,
+ ::SOAP::SOAPStruct,
+ ::SOAP::Mapping::Registry::TypedStructFactory,
+ { :type => XSD::QName.new("http://www.ruby-lang.org/xmlns/soap/interface/RAA/0.0.2/", "Category") }
+ )
+ MappingRegistry.set(
+ InfoArray,
+ ::SOAP::SOAPArray,
+ ::SOAP::Mapping::Registry::TypedArrayFactory,
+ { :type => XSD::QName.new("http://www.ruby-lang.org/xmlns/soap/interface/RAA/0.0.2/", "Info") }
+ )
+ MappingRegistry.set(
+ Info,
+ ::SOAP::SOAPStruct,
+ ::SOAP::Mapping::Registry::TypedStructFactory,
+ { :type => XSD::QName.new("http://www.ruby-lang.org/xmlns/soap/interface/RAA/0.0.2/", "Info") }
+ )
+ MappingRegistry.set(
+ Product,
+ ::SOAP::SOAPStruct,
+ ::SOAP::Mapping::Registry::TypedStructFactory,
+ { :type => XSD::QName.new("http://www.ruby-lang.org/xmlns/soap/interface/RAA/0.0.2/", "Product") }
+ )
+ MappingRegistry.set(
+ Owner,
+ ::SOAP::SOAPStruct,
+ ::SOAP::Mapping::Registry::TypedStructFactory,
+ { :type => XSD::QName.new("http://www.ruby-lang.org/xmlns/soap/interface/RAA/0.0.2/", "Owner") }
+ )
+
+
+ Methods = [
+ ["getAllListings", "getAllListings", [
+ ["retval", "return",
+ [::SOAP::SOAPArray, "http://www.w3.org/2001/XMLSchema", "string"]]], "", "http://www.ruby-lang.org/xmlns/soap/interface/RAA/0.0.2/"],
+ ["getProductTree", "getProductTree", [
+ ["retval", "return",
+ [::SOAP::SOAPArray, "http://www.w3.org/2001/XMLSchema", "anyType"]]], "", "http://www.ruby-lang.org/xmlns/soap/interface/RAA/0.0.2/"],
+ ["getInfoFromCategory", "getInfoFromCategory", [
+ ["in", "category",
+ [::SOAP::SOAPStruct, "http://www.ruby-lang.org/xmlns/soap/interface/RAA/0.0.2/", "Category"]],
+ ["retval", "return",
+ [::SOAP::SOAPArray, "http://www.ruby-lang.org/xmlns/soap/interface/RAA/0.0.2/", "Info"]]], "", "http://www.ruby-lang.org/xmlns/soap/interface/RAA/0.0.2/"],
+ ["getModifiedInfoSince", "getModifiedInfoSince", [
+ ["in", "timeInstant",
+ [SOAP::SOAPDateTime]],
+ ["retval", "return",
+ [::SOAP::SOAPArray, "http://www.ruby-lang.org/xmlns/soap/interface/RAA/0.0.2/", "Info"]]], "", "http://www.ruby-lang.org/xmlns/soap/interface/RAA/0.0.2/"],
+ ["getInfoFromName", "getInfoFromName", [
+ ["in", "productName",
+ [SOAP::SOAPString]],
+ ["retval", "return",
+ [::SOAP::SOAPStruct, "http://www.ruby-lang.org/xmlns/soap/interface/RAA/0.0.2/", "Info"]]], "", "http://www.ruby-lang.org/xmlns/soap/interface/RAA/0.0.2/"],
+ ["getInfoFromOwnerId", "getInfoFromOwnerId", [
+ ["in", "ownerId",
+ [SOAP::SOAPInt]],
+ ["retval", "return",
+ [::SOAP::SOAPArray, "http://www.ruby-lang.org/xmlns/soap/interface/RAA/0.0.2/", "Info"]]], "", "http://www.ruby-lang.org/xmlns/soap/interface/RAA/0.0.2/"]
+ ]
+end
+
+class App < SOAP::RPC::StandaloneServer
+ def initialize(*arg)
+ super
+
+ servant = RAABaseServicePortType.new
+ RAABaseServicePortType::Methods.each do |name_as, name, params, soapaction, namespace|
+ qname = XSD::QName.new(namespace, name_as)
+ @router.add_method(servant, qname, soapaction, name, params)
+ end
+
+ self.mapping_registry = RAABaseServicePortType::MappingRegistry
+ end
+end
+
+# Change listen port.
+if $0 == __FILE__
+ App.new('app', nil, '0.0.0.0', 10080).start
+end
diff --git a/ruby_1_8_5/test/wsdl/raa/README.txt b/ruby_1_8_5/test/wsdl/raa/README.txt
new file mode 100644
index 0000000000..efbaf9d87c
--- /dev/null
+++ b/ruby_1_8_5/test/wsdl/raa/README.txt
@@ -0,0 +1,8 @@
+RAAServant.rb: based on the file which is generated with the following command;
+ bin/wsdl2ruby.rb --wsdl raa.wsdl --servant_skelton --force
+
+RAAService.rb: generated with the following command;
+ bin/wsdl2ruby.rb --wsdl raa.wsdl --standalone_server_stub --force
+
+RAA.rb: generated with the following command;
+ bin/wsdl2ruby.rb --wsdl raa.wsdl --classdef --force
diff --git a/ruby_1_8_5/test/wsdl/raa/raa.wsdl b/ruby_1_8_5/test/wsdl/raa/raa.wsdl
new file mode 100644
index 0000000000..78376893dd
--- /dev/null
+++ b/ruby_1_8_5/test/wsdl/raa/raa.wsdl
@@ -0,0 +1,264 @@
+<?xml version="1.0"?>
+<definitions
+ name="RAA"
+ targetNamespace="http://www.ruby-lang.org/xmlns/soap/interface/RAA/0.0.2/"
+ xmlns:tns="http://www.ruby-lang.org/xmlns/soap/interface/RAA/0.0.2/"
+ xmlns:txd="http://www.ruby-lang.org/xmlns/soap/interface/RAA/0.0.2/"
+ xmlns="http://schemas.xmlsoap.org/wsdl/"
+ xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/"
+ xmlns:xsd="http://www.w3.org/2001/XMLSchema"
+ xmlns:soap="http://schemas.xmlsoap.org/wsdl/soap/"
+ xmlns:soapenc="http://schemas.xmlsoap.org/soap/encoding/"
+ xmlns:apachesoap="http://xml.apache.org/xml-soap">
+
+ <types>
+ <schema
+ xmlns="http://www.w3.org/2001/XMLSchema"
+ targetNamespace="http://www.ruby-lang.org/xmlns/soap/interface/RAA/0.0.2/">
+
+ <complexType name="Category">
+ <all>
+ <element name="major" type="string"/>
+ <element name="minor" type="string"/>
+ </all>
+ </complexType>
+
+ <complexType name="Product">
+ <all>
+ <element name="id" type="int"/>
+ <element name="name" type="string"/>
+ <element name="short_description" type="string"/>
+ <element name="version" type="string"/>
+ <element name="status" type="string"/>
+ <element name="homepage" type="anyURI"/>
+ <element name="download" type="anyURI"/>
+ <element name="license" type="string"/>
+ <element name="description" type="string"/>
+ </all>
+ </complexType>
+
+ <complexType name="Owner">
+ <all>
+ <element name="id" type="int"/>
+ <element name="email" type="anyURI"/>
+ <element name="name" type="string"/>
+ </all>
+ </complexType>
+
+ <complexType name="Info">
+ <all>
+ <element name="category" type="txd:Category"/>
+ <element name="product" type="txd:Product"/>
+ <element name="owner" type="txd:Owner"/>
+ <element name="created" type="xsd:dateTime"/>
+ <element name="updated" type="xsd:dateTime"/>
+ </all>
+ </complexType>
+
+ <import namespace="http://schemas.xmlsoap.org/soap/encoding/"/>
+ <complexType name="InfoArray">
+ <complexContent>
+ <restriction base="soapenc:Array">
+ <attribute ref="soapenc:arrayType" wsdl:arrayType="txd:Info[]"/>
+ </restriction>
+ </complexContent>
+ </complexType>
+
+ <complexType name="StringArray">
+ <complexContent>
+ <restriction base="soapenc:Array">
+ <attribute ref="soapenc:arrayType" wsdl:arrayType="xsd:string[]"/>
+ </restriction>
+ </complexContent>
+ </complexType>
+ </schema>
+
+ <!-- type definition for ApacheSOAP's Map -->
+ <schema
+ xmlns="http://www.w3.org/2001/XMLSchema"
+ targetNamespace="http://xml.apache.org/xml-soap">
+ <complexType name="Map">
+ <sequence>
+ <element name="item" minOccurs="0" maxOccurs="unbounded">
+ <complexType>
+ <sequence>
+ <element name="key" type="anyType" />
+ <element name="value" type="anyType" />
+ </sequence>
+ </complexType>
+ </element>
+ </sequence>
+ </complexType>
+ </schema>
+ </types>
+
+ <message name="getAllListingsRequest"/>
+ <message name="getAllListingsResponse">
+ <part name="return" type="txd:StringArray"/>
+ </message>
+
+ <message name="getProductTreeRequest"/>
+ <message name="getProductTreeResponse">
+ <part name="return" type="apachesoap:Map"/>
+ </message>
+
+ <message name="getInfoFromCategoryRequest">
+ <part name="category" type="txd:Category"/>
+ </message>
+ <message name="getInfoFromCategoryResponse">
+ <part name="return" type="txd:InfoArray"/>
+ </message>
+
+ <message name="getModifiedInfoSinceRequest">
+ <part name="timeInstant" type="xsd:dateTime"/>
+ </message>
+ <message name="getModifiedInfoSinceResponse">
+ <part name="return" type="txd:InfoArray"/>
+ </message>
+
+ <message name="getInfoFromNameRequest">
+ <part name="productName" type="xsd:string"/>
+ </message>
+ <message name="getInfoFromNameResponse">
+ <part name="return" type="txd:Info"/>
+ </message>
+
+ <message name="getInfoFromOwnerIdRequest">
+ <part name="ownerId" type="xsd:int"/>
+ </message>
+ <message name="getInfoFromOwnerIdResponse">
+ <part name="return" type="txd:InfoArray"/>
+ </message>
+
+ <portType name="RAABaseServicePortType">
+ <operation name="getAllListings"
+ parameterOrder="">
+ <input message="tns:getAllListingsRequest"/>
+ <output message="tns:getAllListingsResponse"/>
+ </operation>
+
+ <operation name="getProductTree"
+ parameterOrder="">
+ <input message="tns:getProductTreeRequest"/>
+ <output message="tns:getProductTreeResponse"/>
+ </operation>
+
+ <operation name="getInfoFromCategory"
+ parameterOrder="category">
+ <input message="tns:getInfoFromCategoryRequest"/>
+ <output message="tns:getInfoFromCategoryResponse"/>
+ </operation>
+
+ <operation name="getModifiedInfoSince"
+ parameterOrder="timeInstant">
+ <input message="tns:getModifiedInfoSinceRequest"/>
+ <output message="tns:getModifiedInfoSinceResponse"/>
+ </operation>
+
+ <operation name="getInfoFromName"
+ parameterOrder="productName">
+ <input message="tns:getInfoFromNameRequest"/>
+ <output message="tns:getInfoFromNameResponse"/>
+ </operation>
+
+ <operation name="getInfoFromOwnerId"
+ parameterOrder="ownerId">
+ <input message="tns:getInfoFromOwnerIdRequest"/>
+ <output message="tns:getInfoFromOwnerIdResponse"/>
+ </operation>
+ </portType>
+
+ <binding name="RAABaseServicePortBinding" type="tns:RAABaseServicePortType">
+ <soap:binding style="rpc" transport="http://schemas.xmlsoap.org/soap/http"/>
+
+ <operation name="getAllListings">
+ <soap:operation soapAction=""/>
+ <input>
+ <soap:body use="encoded"
+ encodingStyle="http://schemas.xmlsoap.org/soap/encoding/"
+ namespace="http://www.ruby-lang.org/xmlns/soap/interface/RAA/0.0.2/"/>
+ </input>
+ <output>
+ <soap:body use="encoded"
+ encodingStyle="http://schemas.xmlsoap.org/soap/encoding/"
+ namespace="http://www.ruby-lang.org/xmlns/soap/interface/RAA/0.0.2/"/>
+ </output>
+ </operation>
+
+ <operation name="getProductTree">
+ <soap:operation soapAction=""/>
+ <input>
+ <soap:body use="encoded"
+ encodingStyle="http://schemas.xmlsoap.org/soap/encoding/"
+ namespace="http://www.ruby-lang.org/xmlns/soap/interface/RAA/0.0.2/"/>
+ </input>
+ <output>
+ <soap:body use="encoded"
+ encodingStyle="http://schemas.xmlsoap.org/soap/encoding/"
+ namespace="http://www.ruby-lang.org/xmlns/soap/interface/RAA/0.0.2/"/>
+ </output>
+ </operation>
+
+ <operation name="getInfoFromCategory">
+ <soap:operation soapAction=""/>
+ <input>
+ <soap:body use="encoded"
+ encodingStyle="http://schemas.xmlsoap.org/soap/encoding/"
+ namespace="http://www.ruby-lang.org/xmlns/soap/interface/RAA/0.0.2/"/>
+ </input>
+ <output>
+ <soap:body use="encoded"
+ encodingStyle="http://schemas.xmlsoap.org/soap/encoding/"
+ namespace="http://www.ruby-lang.org/xmlns/soap/interface/RAA/0.0.2/"/>
+ </output>
+ </operation>
+
+ <operation name="getModifiedInfoSince">
+ <soap:operation soapAction=""/>
+ <input>
+ <soap:body use="encoded"
+ encodingStyle="http://schemas.xmlsoap.org/soap/encoding/"
+ namespace="http://www.ruby-lang.org/xmlns/soap/interface/RAA/0.0.2/"/>
+ </input>
+ <output>
+ <soap:body use="encoded"
+ encodingStyle="http://schemas.xmlsoap.org/soap/encoding/"
+ namespace="http://www.ruby-lang.org/xmlns/soap/interface/RAA/0.0.2/"/>
+ </output>
+ </operation>
+
+ <operation name="getInfoFromName">
+ <soap:operation soapAction=""/>
+ <input>
+ <soap:body use="encoded"
+ encodingStyle="http://schemas.xmlsoap.org/soap/encoding/"
+ namespace="http://www.ruby-lang.org/xmlns/soap/interface/RAA/0.0.2/"/>
+ </input>
+ <output>
+ <soap:body use="encoded"
+ encodingStyle="http://schemas.xmlsoap.org/soap/encoding/"
+ namespace="http://www.ruby-lang.org/xmlns/soap/interface/RAA/0.0.2/"/>
+ </output>
+ </operation>
+
+ <operation name="getInfoFromOwnerId">
+ <soap:operation soapAction=""/>
+ <input>
+ <soap:body use="encoded"
+ encodingStyle="http://schemas.xmlsoap.org/soap/encoding/"
+ namespace="http://www.ruby-lang.org/xmlns/soap/interface/RAA/0.0.2/"/>
+ </input>
+ <output>
+ <soap:body use="encoded"
+ encodingStyle="http://schemas.xmlsoap.org/soap/encoding/"
+ namespace="http://www.ruby-lang.org/xmlns/soap/interface/RAA/0.0.2/"/>
+ </output>
+ </operation>
+ </binding>
+
+ <service name="RAAService">
+ <port name="RAABaseServicePort" binding="tns:RAABaseServicePortBinding">
+ <soap:address location="http://raa.ruby-lang.org/soap/1.0.2/"/>
+ </port>
+ </service>
+</definitions>
diff --git a/ruby_1_8_5/test/wsdl/raa/server.rb b/ruby_1_8_5/test/wsdl/raa/server.rb
new file mode 100644
index 0000000000..87bbc6f569
--- /dev/null
+++ b/ruby_1_8_5/test/wsdl/raa/server.rb
@@ -0,0 +1,103 @@
+#!/usr/bin/env ruby
+require 'soap/rpc/standaloneServer'
+require 'RAA.rb'
+
+class RAABaseServicePortType
+ MappingRegistry = SOAP::Mapping::Registry.new
+
+ MappingRegistry.set(
+ StringArray,
+ ::SOAP::SOAPArray,
+ ::SOAP::Mapping::Registry::TypedArrayFactory,
+ { :type => XSD::QName.new("http://www.w3.org/2001/XMLSchema", "string") }
+ )
+ MappingRegistry.set(
+ Map,
+ ::SOAP::SOAPStruct,
+ ::SOAP::Mapping::Registry::TypedStructFactory,
+ { :type => XSD::QName.new("http://xml.apache.org/xml-soap", "Map") }
+ )
+ MappingRegistry.set(
+ Category,
+ ::SOAP::SOAPStruct,
+ ::SOAP::Mapping::Registry::TypedStructFactory,
+ { :type => XSD::QName.new("http://www.ruby-lang.org/xmlns/soap/interface/RAA/0.0.2/", "Category") }
+ )
+ MappingRegistry.set(
+ InfoArray,
+ ::SOAP::SOAPArray,
+ ::SOAP::Mapping::Registry::TypedArrayFactory,
+ { :type => XSD::QName.new("http://www.ruby-lang.org/xmlns/soap/interface/RAA/0.0.2/", "Info") }
+ )
+ MappingRegistry.set(
+ Info,
+ ::SOAP::SOAPStruct,
+ ::SOAP::Mapping::Registry::TypedStructFactory,
+ { :type => XSD::QName.new("http://www.ruby-lang.org/xmlns/soap/interface/RAA/0.0.2/", "Info") }
+ )
+ MappingRegistry.set(
+ Product,
+ ::SOAP::SOAPStruct,
+ ::SOAP::Mapping::Registry::TypedStructFactory,
+ { :type => XSD::QName.new("http://www.ruby-lang.org/xmlns/soap/interface/RAA/0.0.2/", "Product") }
+ )
+ MappingRegistry.set(
+ Owner,
+ ::SOAP::SOAPStruct,
+ ::SOAP::Mapping::Registry::TypedStructFactory,
+ { :type => XSD::QName.new("http://www.ruby-lang.org/xmlns/soap/interface/RAA/0.0.2/", "Owner") }
+ )
+
+ Methods = [
+ ["getAllListings", "getAllListings", [
+ ["retval", "return",
+ [::SOAP::SOAPArray, "http://www.w3.org/2001/XMLSchema", "string"]]],
+ "", "http://www.ruby-lang.org/xmlns/soap/interface/RAA/0.0.2/"],
+ ["getProductTree", "getProductTree", [
+ ["retval", "return",
+ [::SOAP::SOAPStruct, "http://xml.apache.org/xml-soap", "Map"]]],
+ "", "http://www.ruby-lang.org/xmlns/soap/interface/RAA/0.0.2/"],
+ ["getInfoFromCategory", "getInfoFromCategory", [
+ ["in", "category",
+ [::SOAP::SOAPStruct, "http://www.ruby-lang.org/xmlns/soap/interface/RAA/0.0.2/", "Category"]],
+ ["retval", "return",
+ [::SOAP::SOAPArray, "http://www.ruby-lang.org/xmlns/soap/interface/RAA/0.0.2/", "Info"]]],
+ "", "http://www.ruby-lang.org/xmlns/soap/interface/RAA/0.0.2/"],
+ ["getModifiedInfoSince", "getModifiedInfoSince", [
+ ["in", "timeInstant",
+ [SOAP::SOAPDateTime]],
+ ["retval", "return",
+ [::SOAP::SOAPArray, "http://www.ruby-lang.org/xmlns/soap/interface/RAA/0.0.2/", "Info"]]],
+ "", "http://www.ruby-lang.org/xmlns/soap/interface/RAA/0.0.2/"],
+ ["getInfoFromName", "getInfoFromName", [
+ ["in", "productName",
+ [SOAP::SOAPString]],
+ ["retval", "return",
+ [::SOAP::SOAPStruct, "http://www.ruby-lang.org/xmlns/soap/interface/RAA/0.0.2/", "Info"]]],
+ "", "http://www.ruby-lang.org/xmlns/soap/interface/RAA/0.0.2/"],
+ ["getInfoFromOwnerId", "getInfoFromOwnerId", [
+ ["in", "ownerId",
+ [SOAP::SOAPInt]],
+ ["retval", "return",
+ [::SOAP::SOAPArray, "http://www.ruby-lang.org/xmlns/soap/interface/RAA/0.0.2/", "Info"]]],
+ "", "http://www.ruby-lang.org/xmlns/soap/interface/RAA/0.0.2/"]
+ ]
+
+ def getAllListings
+ ["ruby", "soap4r"]
+ end
+end
+
+class RAABaseServiceServer < SOAP::RPC::StandaloneServer
+ def initialize(*arg)
+ super
+
+ servant = RAABaseServicePortType.new
+ RAABaseServicePortType::Methods.each do |name_as, name, params, soapaction, namespace|
+ qname = XSD::QName.new(namespace, name_as)
+ @router.add_method(servant, qname, soapaction, name, params)
+ end
+
+ self.mapping_registry = RAABaseServicePortType::MappingRegistry
+ end
+end
diff --git a/ruby_1_8_5/test/wsdl/raa/test_raa.rb b/ruby_1_8_5/test/wsdl/raa/test_raa.rb
new file mode 100644
index 0000000000..0b00042ffb
--- /dev/null
+++ b/ruby_1_8_5/test/wsdl/raa/test_raa.rb
@@ -0,0 +1,71 @@
+require 'test/unit'
+require 'soap/wsdlDriver'
+require 'RAA.rb'
+require 'RAAServant.rb'
+require 'RAAService.rb'
+
+
+module WSDL
+module RAA
+
+
+class TestRAA < Test::Unit::TestCase
+ DIR = File.dirname(File.expand_path(__FILE__))
+
+ Port = 17171
+
+ def setup
+ setup_server
+ setup_client
+ end
+
+ def setup_server
+ @server = App.new('RAA server', nil, '0.0.0.0', Port)
+ @server.level = Logger::Severity::ERROR
+ @t = Thread.new {
+ Thread.current.abort_on_exception = true
+ @server.start
+ }
+ end
+
+ def setup_client
+ wsdl = File.join(DIR, 'raa.wsdl')
+ @raa = ::SOAP::WSDLDriverFactory.new(wsdl).create_rpc_driver
+ @raa.endpoint_url = "http://localhost:#{Port}/"
+ end
+
+ def teardown
+ teardown_server
+ teardown_client
+ end
+
+ def teardown_server
+ @server.shutdown
+ @t.kill
+ @t.join
+ end
+
+ def teardown_client
+ @raa.reset_stream
+ end
+
+ def test_raa
+ assert_equal(["ruby", "soap4r"], @raa.getAllListings)
+ end
+
+ def foo
+ p @raa.getProductTree()
+ p @raa.getInfoFromCategory(Category.new("Library", "XML"))
+ t = Time.at(Time.now.to_i - 24 * 3600)
+ p @raa.getModifiedInfoSince(t)
+ p @raa.getModifiedInfoSince(DateTime.new(t.year, t.mon, t.mday, t.hour, t.min, t.sec))
+ o = @raa.getInfoFromName("SOAP4R")
+ p o.type
+ p o.owner.name
+ p o
+ end
+end
+
+
+end
+end