Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.
Comment: Migrated to Confluence 5.3

Scenarios

Bottom Up

A: Client Reference -> interface.java -> Databinding(JAXB) -> binding.sca -> binding.sca -> Databinding(JAXB) -> interface.java -> Service -> implementation.java(local)
B: Client Reference -> interface.java -> Databinding(JAXB) -> binding.sca -> binding.sca -> Databinding(JAXB) -> interface.java -> Service -> implementation.java(@Remotable)
C: Client Reference -> interface.java -> Databinding(JAXB) -> Databinding(Axiom) -> binding.ws -> binding.ws -> interface.java -> Databindng(Axiom) -> Databinding(JAXB) -> Service -> implementation.java(@Remotable)
D C/MTOM: Client Reference -> interface.wsdl java -> Databinding(JAXB) -> Databinding(Axiom) -> binding.ws -> SOAP/MTOM -> binding.ws -> interface.wsdl java -> Databindng(Axiom) -> Databinding(JAXB) -> Service -> implementation.java(@Remotable)

Top Down

ED: Client Reference -> interface.java wsdl (doc/lit/wrapped) -> Databinding(JAXB) -> Databinding(Axiom) -> binding.ws -> binding.ws -> interface.wsdl(doc/lit/wrapped) -> Databindng(Axiom) -> Databinding(JAXB) -> Service (-> implementation.java(@Remotable)
F D/MTOM: Client Reference -> interface.wsdl (doc/lit/wrapped) -> Databinding(JAXB) -> Databinding(Axiom) -> binding.ws -> SOAP/MTOM -> binding.ws -> interface.java wsdl(doc/lit/wrapped) -> Databindng(Axiom) -> Databinding(JAXB) -> Service -> implementation.java(@Remotable)

Support

E: Reference -> interface.java -> Databinding(JAXB) -> Databinding(Axiom) -> binding.ws -> binding.ws -> interface.wsdl(doc/lit/wrapped) -> Databindng(Axiom) -> Databinding(JAXB) -> Service -> implementation.java(@Remotable)
F: Reference -> interface.wsdl(doc/lit/wrapped) -> Databinding(JAXB) -> Databinding(Axiom) -> binding.ws -> binding.ws -> interface.java -> Databindng(Axiom) -> Databinding(JAXB) -> Service -> implementation.java(@Remotable)
G: Reference -> interface.wsdl (doc/lit/bare) -> Databinding(JAXB) -> Databinding(Axiom) -> binding.ws -> binding.ws -> interface.wsdl(doc/lit/bare) -> Databindng(Axiom) -> Databinding(JAXB) -> Service -> implementation.java(@Remotable)
H: Reference -> interface.java -> Databinding(JAXB) -> Databinding(Axiom) -> binding.ws -> binding.ws -> interface.wsdl(doc/lit/bare) -> Databindng(Axiom) -> Databinding(JAXB) -> Service -> implementation.java(@Remotable)
I: Reference -> interface.wsdl(doc/lit/bare) -> Databinding(JAXB) -> Databinding(Axiom) -> binding.ws -> binding.ws -> interface.java -> Databindng(Axiom) -> Databinding(JAXB) -> Service -> implementation.java(@Remotable)

We should look at some binding.ws(portType), binding.ws(binding), binding.ws(port) scenarios also.

Support

Data Type

A

B

C

C ?wsdl

C/MTOM

D

D/MTOM

E

F

G

H

I

Notes

PrimitiveTypes

 

 

Data Type

A

B

C doc/lit/wrapped

C doc/lit/bare

C ?wsdl

D

E

F

Notes

PrimitiveTypes

 

 

 

 

 

 

 

 

boolean

(tick)

(tick)

(tick)

 

(tick)

 

 

 

 

byte

(tick)

(tick)

(tick)

 

(tick)

 

 

 

 

short

(tick)

(tick)

(tick)

 

(tick)

 

 

 

 

int  

(tick)  (tick)

 

(tick)  

 

(tick)  

 

boolean

 (tick) 

(tick)

 (tick)

long (tick)

(tick)

(tick)

(tick)

 (tick)

(tick)

 

 

 

 

byte

(tick)

(tick)

(tick)

(tick) float

(tick)

(tick)

(tick)

 (tick)

(tick)

 

 

 

 

double short

(tick)

(tick)

(tick)

 (tick)

(tick)

 (tick) 

(tick)

 

 

(tick)

(tick) Standard Types

 

 

 

  

int

 (tick) 

(tick)

 

(tick)

(tick) java.lang.String

(tick)

(tick)

(tick)

 (tick)

(tick)

 

 

 

 

java.math.BigInteger long

(tick)

(tick)

(tick)

 (tick)

(tick)

 (tick)

 

(tick)

(tick)

(tick)

 

 

 

 

float

(tick)

(tick)

(tick)

(tick) java.math.BigDecimal

(tick)

(tick)

(tick)

 (tick)

(tick)

 

 

 

 

java.util.Calendar double

(tick)

(tick)

(tick)

 (tick)

(tick)

 

 

 

 

(tick)

(tick) java.util.Date

(tick)

(tick) (tick)

 

 

(tick)  

 

Standard Types

 

 

 

javax.xml.namespace.QName

(tick)

(tick)

 

 

 

  (tick)

 

(tick)  

 

 

 

 

java.net.URIlang.String

(tick)

(tick)

(tick)

(tick)

(tick)

(tick)

(tick)

 (tick)

(tick)

 

 

 

 

javax java.xmlmath.datatype.XMLGregorianCalendarBigInteger

(tick)

(tick)

(tick)

 (tick)

(tick)

 

(tick)

(tick)

(tick)

(tick)

 

 

 

 

javax java.xml.datatype.Duration math.BigDecimal

(tick)

(tick)

(tick)

(tick)

(tick)

(tick)

(tick)

 (tick)

(tick)

 

 

 

 

java.lang.Object util.Calendar

(tick)

(tick)

(tick)

(tick)

(tick)

(tick)

(error) (tick)

 (tick)

(tick)

 

 

 

 

java.awtutil.Image Date

(tick)

(tick)

(error) (tick)

 (tick)

(tick)

 

 

 

 

javax.activation.DataHandler (tick)

(tick)

(tick)

(tick)

 

(error)

 

 

 

 

javax.xml.transform.Source namespace.QName

(tick)

(tick)

(tick)

(tick)

(tick)

(tick)

(error) (tick)

 (tick)

(tick)

 

 

 

 

java.utilnet.UUIDURI

(tick)

(tick)

(tick)

 (tick)

(tick)

 (tick) 

(tick)

 (tick)

 

Arrays (tick)

 

 

 

 

 

 

 

 

javax.xml.datatype.XMLGregorianCalendar

(tick)

(tick)

(tick)

(tick) boolean

(tick)

(tick)

(tick)

(tick)  

(tick)

 

 

 

 byte

javax.xml.datatype.Duration

(tick)

(tick)

(tick)

 

(error)

 

 

 

 

(tick)

(tick) short

(tick)

(tick)

(tick) 

(tick)

 

 

 

 int

java.lang.Object

(tick)

(tick)

(tick)

 (tick)

(tick)

 

 

 

 

long

(tick)

(tick)

(tick) 

(tick)

 

 

 

 float

java.awt.Image

(tick)

(tick)

(tick)

 (tick)

(tick)

 

 

 

 

double

(tick)

(tick)

(tick) 

(tick)

 

 

 

 

java javax.langactivation.StringDataHandler

(tick)

(tick)

(tick)

 (tick)

(tick)

 

 

 

 

java.math.BigInteger

(tick)

(tick)

(tick) 

(tick)

 

 

 

 

java javax.xml.mathtransform.BigDecimalSource

(tick)

(tick)

(tick)

 (tick)

(tick)

(error)

(error)

(error)

(error)

 

 

  

TUSCANY-2387

java.util.CalendarUUID

(tick)

(tick)

(tick)

 (tick)

(tick)

 (tick)

 

 

 

java.util.Date

(tick)

(tick)

(tick) (tick)

 

 

(tick) 

 

Arrays

 

 

 

javax.xml.namespace.QName

(tick)

(tick)

 

 

 

  (error)

 

(tick)  

 

 

 

 

boolean

(tick)

(tick)

(tick)

(tick) java.net.URI

(tick)

(tick)

(tick)

 (tick)

(tick)

 

 

 

 

javax.xml.datatype.XMLGregorianCalendar byte

(tick)

(tick)

(tick)

(error)

 

(tick)

 

(tick)

(tick)

 

 

 

A byte[] must map to xs:base64Binary by default

short

(tick)

(tick)

(tick)

(tick) javax.xml.datatype.Duration

(tick)

(tick)

(tick)

 (tick)

(tick)

 

 

 

 

int

(tick)

(tick)

(tick)

(tick) java.lang.Object

(tick)

(tick)

(error) (tick)

 (tick)

(tick)

 

 

 

 

long

(tick)

(tick)

(tick)

(tick) java.awt.Image

(tick)

(error) (tick) (error)

(tick)

 (tick)

(tick)

 

 

 

 

javax.activation.DataHandler float

(tick)

(tick)

(tick)

 (tick)

(error) (tick)

 

(tick)

(tick)

(tick)

(tick)

 

 

 

 

double

(tick)

(tick)

(tick)

(tick) javax.xml.transform.Source

(tick)

(error) (tick) (error)

(tick)

 (tick)

(tick)

 

 

 

TUSCANY-2386, TUSCANY-2387  

java.utillang.UUIDString

(tick)

(tick)

(tick)

 (tick)

(tick)

 (tick) 

(tick)

(tick)  

 

Collections (tick)

 

 

 

 

 

 

 

 

java.math.BigInteger

(tick)

(tick)

(tick)

(tick) List<String>, ArrayList<String>

(tick)

(tick)

(tick)

 (tick) 

(tick)

 

 

 

 Map<String, String>, HashMap<String, String>

java.math.BigDecimal

(tick)

(tick)

(tick)

 (tick) 

(tick)

 (tick) 

(tick)

 (tick) 

(tick)

 

 

 

 

 

 

 

 

 

 

Polymorphic Types

 

 

java.util.Calendar

(tick)

(tick)

(tick)

(tick)

(tick)

(tick)

(tick)

(tick)

(tick)  

 

 

 

 

 

java.util.Date

(tick) Case1: Bean3 extends Bean2

(tick)

(tick)

(error) (tick)

 (tick) 

(tick)

 (tick) 

(tick)

 (tick)

  Parameterized Types

 

 

 

 

 

 

 

 

javax.xml.namespace.QName

(tick)

(tick)

(tick)

(tick)

(tick) TypeExplicit

(tick)

(tick)

(tick)

 

(tick)

 

 

 

 

java.net.URI

(tick)

(tick)

(tick)

(tick) TypeUnbound

(tick)

(tick)

(error) (tick)

 (tick)

(error) (tick)

 

 

 

 

javax.xml.datatype.XMLGregorianCalendar

(tick)

(tick)

(tick)

(tick) TypeExtends

(tick)

(error) (tick) (error)

(tick)

 (tick)

(tick)

 

 

 

 

javax.xml.datatype.Duration

(tick)

(tick)

(tick)

(tick) RecursiveTypeBound

(tick)

(error) (tick) (error)

(tick)

 (tick)

(tick)

 

 

 

 

java.lang.Object

(tick)

(tick)

(tick)

(tick) WildcardUnbound

(tick)

(tick)

(tick)

 (tick)

(tick)

 

 

 

 


java.awt.Image

(tick)

(tick)

(tick)

(tick) WildcardSuper

(tick)

(error) (tick) (error)

(tick)

 (tick)

(tick)

 

 

 

 WildcardExtends

javax.activation.DataHandler

(tick)

(error) (tick) (error)

(tick)

 (tick)

(tick)

 (tick)

  

(tick)

 (tick)

 

 

 

 

 

 

 

 

 

 

Variable Arguments

 

 

javax.xml.transform.Source

(tick)

(error)

(error)

(error)

(error)

(error)

(error)

(error)

(error)  

 

 

 

TUSCANY-2386, TUSCANY-2387, TUSCANY-2452

java.util.UUID

(tick)

(tick)

 

 

String...

(tick)

(tick)

 

(tick)

 

(tick)

(tick)

 

 

 

 

Exceptions Collections

 

 

 

 

 

 

 

 

 

 

 

 

 

List<String>, ArrayList<String>

(tick)

(tick)

(tick)

 

 

(tick)

 

 

 

The following are note to give more detail of the scenarios and data types.

WSDL

see http://www.ibm.com/developerworks/webservices/library/ws-whichwsdl/

JAXWS2.1 describes the supported mappings and the restrictions these place on the Java interfaces.

  • Docuement Wrapped
  • Document Bare (The java method basically one in and one out parameter)
  • RPC

A Service

Code Block

public interface HelloWorldService {
    public String getGreetings(String firstName, String lastName);
}

doc / lit / wrapped (The only one supported in Tuscany)

WSDL

(tick)

(tick)

 

 

 

 

Map<String, String>, HashMap<String, String>

(tick)

(tick)

(tick)

 

 

(tick)

 

(tick)

(tick)

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

Polymorphic Types

 

 

 

 

 

 

 

 

 

 

 

 

 

Case1: Bean3 extends Bean2

(tick)

(tick)

(tick)

(tick)

 

 

 

 

 

 

 

 

Unmarshalls to Bean2 always.

Parameterized Types

 

 

 

 

 

 

 

 

 

 

 

 

 

TypeExplicit

(tick)

(tick)

(tick)

(tick)

 

 

 

 

 

 

 

 

 

TypeUnbound

(tick)

(tick)

(tick)

(tick)

 

 

 

 

 

 

 

 

Unmarshalls to Object[] always.

TypeExtends

(tick)

(tick)

(tick)

(tick)

 

 

 

 

 

 

 

 

Unmarshalls to Bean2 always.

RecursiveTypeBound

(tick)

(tick)

(tick)

(tick)

 

 

 

 

 

 

 

 

Unmarshalls to Bean1<String> always.

WildcardUnbound

(tick)

(tick)

(tick)

(tick)

 

 

 

 

 

 

 

 

 

WildcardSuper

(tick)

(tick)

(tick)

(tick)

 

 

 

 

 

 

 

 

 

WildcardExtends

(tick)

(tick)

(tick)

(tick)

 

 

 

 

 

 

 

 

Unmarshalls to Bean2 always.

 

 

 

 

 

 

 

 

 

 

 

 

 

 

Variable Arguments

 

 

 

 

 

 

 

 

 

 

 

 

 

String...

(tick)

(tick)

(tick)

(tick)

 

(tick)

 

(tick)

(tick)

 

 

 

 

Exceptions

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

The following are note to give more detail of the scenarios and data types.

WSDL

see http://www.ibm.com/developerworks/webservices/library/ws-whichwsdl/

JAXWS2.1 describes the supported mappings and the restrictions these place on the Java interfaces.

  • Docuement Wrapped
  • Document Bare (The java method basically one in and one out parameter)
  • RPC

doc / lit / wrapped (The only one supported in Tuscany)

Java

Code Block

public interface HelloWorldService {
    public String getGreetings(String firstName, String lastName);
}

WSDL

Code Block

<wsdl:types>
        <schema elementFormDefault="qualified" targetNamespace="http://helloworld" xmlns="http://www.w3.org/2001/XMLSchema">
            <element name="getGreetings">
                <complexType>
                    <sequence>
                        <element name="firstName" type="xsd:string"/>
                        <element name="lastName" type="xsd:string"/>
                    </sequence>
                </complexType>
            </element>

            <element name="getGreetingsResponse">
                <complexType>
                    <sequence>
                        <element name="getGreetingsReturn" type="xsd:string"/>
                    </sequence>
                </complexType>
            </element>

        </schema>
    </wsdl:types>

    <wsdl:message name="getGreetingsRequest">
        <wsdl:part element="tns:getGreetings" name="parameters"/>
    </wsdl:message>

    <wsdl:message name="getGreetingsResponse">
        <wsdl:part element="tns:getGreetingsResponse" name="parameters"/>
    </wsdl:message>

    <wsdl:portType name="HelloWorld">
        <wsdl:operation name="getGreetings">
            <wsdl:input message="tns:getGreetingsRequest" name="getGreetingsRequest"/>
            <wsdl:output message="tns:getGreetingsResponse" name="getGreetingsResponse"/>
        </wsdl:operation>
    </wsdl:portType>

    <wsdl:binding name="HelloWorldSoapBinding" type="tns:HelloWorld">
        <wsdlsoap:binding style="document" transport="http://schemas.xmlsoap.org/soap/http"/>
        <wsdl:operation name="getGreetings">
            <wsdlsoap:operation soapAction=""/>
  
Code Block

    <wsdl:types>
        <schema elementFormDefault="qualified" targetNamespace="http://helloworld" xmlns="http://www.w3.org/2001/XMLSchema">
 <wsdl:input name="getGreetingsRequest">
               <element name <wsdlsoap:body use="getGreetingsliteral"/>
            </wsdl:input>
          <complexType>
  <wsdl:output name="getGreetingsResponse">
                 <sequence><wsdlsoap:body use="literal"/>
            </wsdl:output>
        </wsdl:operation>
    </wsdl:binding>

SOAP

Code Block

<Envelope xmlns="http://schemas.xmlsoap.org/soap/envelope/">
<Body>
<ns1:getGreetingsxmlns:ns1="http://helloworld">
<ns1:firstName>fred</ns1:firstName>
<ns1:secondNameName>bloggs</ns1:secondName>
</ns1:getGreetings>
</Body>
</Envelope>

doc / lit / bare (unwrapped) wsdl

There is some support but we need to find the tests

Java

Code Block

public interface HelloWorldService {
    public String getGreetings(String firstName, String lastName);
}

WSDL

Code Block

<wsdl:types><element name="firstName" type="xsd:string"/>
                        <element name="lastName" type="xsd:string"/>
                    </sequence>
        <schema elementFormDefault="qualified"       </complexType>targetNamespace="http://helloworld" xmlns="http://www.w3.org/2001/XMLSchema">

            </element>

   <complexType name="NameType">
         <element name="getGreetingsResponse">
          <sequence>
      <complexType>
                  <element  <sequence>name="firstName" type="xsd:string"/>
                        <element name="getGreetingsReturnlastName" type="xsd:string"/>
                    </sequence>
            </complexType>

            <element  </complexType>
name="getGreetings" type="tns:NameType"/>

             </element>
            <element name="getGreetingsResponse" type="xsd:string"/>

        </schema>
    </wsdl:types>

    <wsdl:message name="getGreetingsRequest">
        <wsdl:part element="tns:getGreetings" name="parameters"/>
    </wsdl:message>

    <wsdl:message name="getGreetingsResponse">
        <wsdl:part element="tns:getGreetingsResponse" name="parameters"/>
    </wsdl:message>

    <wsdl:portType name="HelloWorld">
        <wsdl:operation name="getGreetings">
            <wsdl:input message="tns:getGreetingsRequest" name="getGreetingsRequest"/>
            <wsdl:output message="tns:getGreetingsResponse" name="getGreetingsResponse"/>
        </wsdl:operation>
    </wsdl:portType>

    <wsdl:binding name="HelloWorldSoapBinding" type="tns:HelloWorld">
        <wsdlsoap:binding style="document" transport="http://schemas.xmlsoap.org/soap/http"/>
        <wsdl:operation name="getGreetings">
            <wsdlsoap:operation soapAction=""/>
            <wsdl:input name="getGreetingsRequest">
                <wsdlsoap:body use="literal"/>
            </wsdl:input>
            <wsdl:output name="getGreetingsResponse">
                <wsdlsoap:body use="literal"/>
            </wsdl:output>
        </wsdl:operation>
    </wsdl:binding>

SOAP

Needs checking.

Code Block
<Envelope xmlns="http://schemas.xmlsoap.org/soap/envelope/">
<Body>
<ns1:getGreetingsxmlns:ns1="http://helloworld">
<ns1:firstName>fred</ns1:firstName>
<ns1:secondNameName>bloggs</ns1:secondName>
</ns1:getGreetings>
</Body>
</Envelope>

doc / lit / bare (unwrapped) wsdl

...

rpc / literal

We don't support this in Tuscany

...

Excluded by SCA
Discussed in JAXWS

There is a JIRA http://issues.apache.org/jira/browse/TUSCANY-2332Image Removed

Namespaces

What do we need to say about this?

...

Code Block
boolean
byte
short 
int 
long
float 
double

Standard Types

As JAXB 2.1 (8.5.2)

Code Block
java.lang.String
java.math.BigInteger
java.math.BigDecimal
java.util.Calendar
java.util.Date
javax.xml.namespace.QName
java.net.URI
javax.xml.datatype.XMLGregorianCalendar
javax.xml.datatype.Duration 
java.lang.Object 
java.awt.Image 
javax.activation.DataHandler 
javax.xml.transform.Source 
java.util.UUID

Parameterized Types/Generics

...

Code Block
Bean1<String> someMethodTypeExplicit(Bean1<String>)
Code Block


  <xs:complexType name="someMethodTypeExplicit">
    <xs:sequence>
      <xs:element name="arg0" type="tns:bean1" minOccurs="0"/>
    </xs:sequence>
  </xs:complexType>

  <xs:complexType name="someMethodTypeExplicitResponse">
    <xs:sequence>
      <xs:element name="return" type="tns:bean1" minOccurs="0"/>
    </xs:sequence>
  </xs:complexType>

  <xs:element name="someMethodTypeExplicit" type="tns:someMethodTypeExplicit"/>

  <xs:element name="someMethodTypeExplicitResponse" type="tns:someMethodTypeExplicitResponse"/>

  <message name="someMethodTypeExplicit">
    <part name="parameters" element="tns:someMethodTypeExplicit"/>
  </message>
  <message name="someMethodTypeExplicitResponse">
    <part name="parameters" element="tns:someMethodTypeExplicitResponse"/>
  </message>

...

Code Block
<T> Bean1<T> someMethodTypeUnbound(T[] anArray)
Code Block
  <xs:complexType name="someMethodTypeUnbound">
    <xs:sequence>
      <xs:element name="arg0" type="xs:anyType" nillable="true" minOccurs="0" maxOccurs="unbounded"/>
    </xs:sequence>
  </xs:complexType>

  <xs:complexType name="someMethodTypeUnboundResponse">
    <xs:sequence>
      <xs:element name="return" type="tns:bean1" minOccurs="0"/>
    </xs:sequence>
  </xs:complexType>

  <xs:element name="someMethodTypeUnbound" type="tns:someMethodTypeUnbound"/>

  <xs:element name="someMethodTypeUnboundResponse" type="tns:someMethodTypeUnboundResponse"/>

  <message name="someMethodTypeUnbound">
    <part name="parameters" element="tns:someMethodTypeUnbound"/>
  </message>
  <message name="someMethodTypeUnboundResponse">
    <part name="parameters" element="tns:someMethodTypeUnboundResponse"/>
  </message>

...

Code Block
<T extends Bean2> Bean1<T> someMethodTypeExtends(T[] anArray)
Code Block
  <xs:complexType name="someMethodTypeExtends">
    <xs:sequence>
      <xs:element name="arg0" type="tns:bean2" nillable="true" minOccurs="0" maxOccurs="unbounded"/>
    </xs:sequence>
  </xs:complexType>

  <xs:complexType name="someMethodTypeExtendsResponse">
    <xs:sequence>
      <xs:element name="return" type="tns:bean1" minOccurs="0"/>
    </xs:sequence>
  </xs:complexType>

  <xs:element name="someMethodTypeExtends" type="tns:someMethodTypeExtends"/>


  <xs:element name="someMethodTypeExtendsResponse" type="tns:someMethodTypeExtendsResponse"/>

  <message name="someMethodTypeExtends">
    <part name="parameters" element="tns:someMethodTypeExtends"/>
  </message>
  <message name="someMethodTypeExtendsResponse">
    <part name="parameters" element="tns:someMethodTypeExtendsResponse"/>
  </message>

...

Code Block
<T extends Bean1<String>> Bean1<T> someMethodRecursiveTypeBound(T[] anArray)
Code Block
  <xs:complexType name="someMethodRecursiveTypeBound">
    <xs:sequence>
      <xs:element name="arg0" type="tns:bean1" nillable="true" minOccurs="0" maxOccurs="unbounded"/>
    </xs:sequence>
  </xs:complexType>

  <xs:complexType name="someMethodRecursiveTypeBoundResponse">
    <xs:sequence>
      <xs:element name="return" type="tns:bean1" minOccurs="0"/>
    </xs:sequence>
  </xs:complexType>

  <xs:element name="someMethodRecursiveTypeBound" type="tns:someMethodRecursiveTypeBound"/>

  <xs:element name="someMethodRecursiveTypeBoundResponse" type="tns:someMethodRecursiveTypeBoundResponse"/>

  <message name="someMethodRecursiveTypeBound">
    <part name="parameters" element="tns:someMethodRecursiveTypeBound"/>
  </message>
  <message name="someMethodRecursiveTypeBoundResponse">
    <part name="parameters" element="tns:someMethodRecursiveTypeBoundResponse"/>
  </message>

...

Code Block
Bean1<?> someMethodWildcardUnbound(Bean1<?>)
Code Block
  <xs:complexType name="someMethodWildcardUnbound">
    <xs:sequence>
      <xs:element name="arg0" type="tns:bean1" minOccurs="0"/>
    </xs:sequence>
  </xs:complexType>

  <xs:complexType name="someMethodWildcardUnboundResponse">
    <xs:sequence>
      <xs:element name="return" type="tns:bean1" minOccurs="0"/>
    </xs:sequence>
  </xs:complexType>

  <xs:element name="someMethodWildcardUnbound" type="tns:someMethodWildcardUnbound"/>

  <xs:element name="someMethodWildcardUnboundResponse" type="tns:someMethodWildcardUnboundResponse"/>

  <message name="someMethodWildcardUnbound">
    <part name="parameters" element="tns:someMethodWildcardUnbound"/>
  </message>
  <message name="someMethodWildcardUnboundResponse">
    <part name="parameters" element="tns:someMethodWildcardUnboundResponse"/>
  </message>

...

Code Block
Bean1<? super Bean3> someMethodWildcardSuper(Bean1<? super Bean3>)
Code Block
  <xs:complexType name="someMethodWildcardSuper">
    <xs:sequence>
      <xs:element name="arg0" type="tns:bean1" minOccurs="0"/>
    </xs:sequence>
  </xs:complexType>

  <xs:complexType name="someMethodWildcardSuperResponse">
    <xs:sequence>
      <xs:element name="return" type="tns:bean1" minOccurs="0"/>
    </xs:sequence>
  </xs:complexType>

  <xs:element name="someMethodWildcardSuper" type="tns:someMethodWildcardSuper"/>

  <xs:element name="someMethodWildcardSuperResponse" type="tns:someMethodWildcardSuperResponse"/>

  <message name="someMethodWildcardSuper">
    <part name="parameters" element="tns:someMethodWildcardSuper"/>
  </message>
  <message name="someMethodWildcardSuperResponse">
    <part name="parameters" element="tns:someMethodWildcardSuperResponse"/>
  </message>

...

Code Block
Bean1<? extends Bean2> someMethodWildcardExtends(Bean1<? extends Bean2>)
Code Block
  <xs:complexType name="someMethodWildcardExtends">
    <xs:sequence>
      <xs:element name="arg0" type="tns:bean1" minOccurs="0"/>
    </xs:sequence>
  </xs:complexType>

  <xs:complexType name="someMethodWildcardExtendsResponse">
    <xs:sequence>
      <xs:element name="return" type="tns:bean1" minOccurs="0"/>
    </xs:sequence>
  </xs:complexType>

  <xs:element name="someMethodWildcardExtends" type="tns:someMethodWildcardExtends"/>

  <xs:element name="someMethodWildcardExtendsResponse" type="tns:someMethodWildcardExtendsResponse"/>

  <message name="someMethodWildcardExtends">
    <part name="parameters" element="tns:someMethodWildcardExtends"/>
  </message>
  <message name="someMethodWildcardExtendsResponse">
    <part name="parameters" element="tns:someMethodWildcardExtendsResponse"/>
  </message>

...

Start From WSDL

Code Block


<wsdl:types>
    ...
    <element name="errorCode" type="xsd:int"/>
    ...
</wsdl:types>

<wsdl:message name="BadInputMsg">
    <wsdl:part element="tns:errorCode" name="parameters"/>
</wsdl:message>

<wsdl:portType name="GuessAndGreet">
    <wsdl:operation name="sendGuessAndName">
            <wsdl:input.../>
            <wsdl:fault message="tns:BadInputMsg" name="BadInputMsg"/>
 ...

Now generate Java (e.g. with wsimport) according to the JAX-WS Section 2.5 pattern:

Interface

Code Block
    public Person sendGuessAndName(...) throws BadInputMsg;    

Anchor
topdownexcgen
topdownexcgen
Exception wrappering Fault

Code Block


import javax.xml.ws.WebFault;

@WebFault(name = "errorCode", targetNamespace = "....")
public class BadInputMsg extends Exception
{
    private int faultInfo;

    public BadInputMsg(String message, int faultInfo) {
        super(message);
        this.faultInfo = faultInfo;
    }

    public BadInputMsg(String message, int faultInfo, Throwable cause) {
        super(message, cause);
        this.faultInfo = faultInfo;
    }

    public int getFaultInfo() {
        return faultInfo;
    }
}

...

Code Block
package java.sql;

public class SQLException extends Exception ... {
 ...
 public SQLException(String theReason, String theSQLState, int theErrorCode) ...

 public int getErrorCode() 
}

Tuscany

TODO - Add some details of which bits of tuscany do what w.r.t databindings, mappings and transformations in typical scenarios, e.g.

Code Block
    <component name="HelloWorldClientComponent">
        <implementation.java class="helloworld.HelloWorldClientImpl" />
	 <reference name="helloWorldService">
	        <interface.wsdl interface="http://helloworld#wsdl.interface(HelloWorld)" />
	        <binding.ws uri="http://localhost:8085/HelloWorldService"/>
	 </reference>
    </component>

    <component name="HelloWorldServiceComponent">
        <implementation.java class="helloworld.HelloWorldImpl" />
	 <service name="HelloWorldService">
	        <interface.wsdl interface="http://helloworld#wsdl.interface(HelloWorld)" />
	        <binding.ws uri="http://localhost:8085/HelloWorldService"/>
	 </service>
    </component>

...

  • databinding mapping - Creates in memory models of the WSDL interfaces and the java introspected component types.
  • interface contract mapper - Checks compatibility of
    • interfaces with component types
    • references with services
Code Block
	 
            <service name="HelloWorldService">
	        <interface.java ...

...