The system generates XML based on Java types using predefined rules.
Table 1 shows how the system converts between Java™ types and XML. The system places the XML in the types section of a Web Services Description Language (WSDL) document.
Java type | XML type |
---|---|
char or java.lang.Character | <ati:schema targetNamespace="http://xml.apache.org/xml-soap" xmlns="http://www.w3.org/2001/XMLSchema" xmlns:ati="http://www.w3.org/2001/XMLSchema"> <ati:simpleType name="char"> <ati:restriction base="xsd:string"> <ati:length value="1"/> </ati:restriction> </ati:simpleType> </ati:schema> tns2:char or tns2:char nillable = true |
boolean | xsd:boolean |
java.lang.Boolean | xsd:boolean nillable=true |
byte or java.lang.Byte | xsd:byte or xsd:byte nillable=true |
short or java.lang.Short | xsd:short or xsd:short nillable=true |
int or java.lang.Integer | xsd:int or xsd:int nillable = true |
long or java.lang.Long | xsd:long or xsd:long nillable=true |
float or java.lang.Float | xsd:float or xsd:float nillable=true |
Double or java.lang.Double | xsd:double or xsd:double nillable=true |
java.lang.String | xsd:string nillable=true |
java.math.BigInteger | xsd:integer nillable=true |
Java.math.BigDecimal | xsd:decimal nillable=true |
Java.util.Calendar | xsd:dateTime nillable=true |
java.util.Date | xsd:dateTime nillable=true |
Java.xml.namespace.QName | xsd:Qname nillable=true |
java.net.URI | xsd:anyURI nillable=true |
byte[] | xsd:base64Binary |
Array of types | xsd:complexType with an element of type and with maxocurrs > 1 or unbounded |
Java class Important: If the Java class
is a user-defined class, the class must conform to section 5.4 of JAX-RPC
1.1.
|
xsd:complexType as per rules in section 5.4 of JAX-RPC 1.1 |
java.lang.Object | xsd:anyType |
java.util classes (such as Collection, List,ArrayList,
Set, SortedSet, AbstractCollection, AbstractList, AbstractSet, Hashset LinkedHashSet,
LinkedList, Stack, Treeset) Important: Only the Java type
collections listed are currently supported.
|
<complexType name="ArrayOfXSDAnyType"> <sequence> <element maxOccurs="unbounded" minOccurs="0" name="anyType" nillable="true" type="xsd:anyType"/> </sequence> </complexType> |
|
targetNamespace="http://xml.apache.org/xml-soap" <complexType name="Item"> <all> <element name="key" type="xsd:anyType"/> <element name="value" type="xsd:anyType"/> </all> </complexType> <complexType name="Map"> <sequence> <element maxOccurs="unbounded" minOccurs="0" name="item" type="tns2:Item"/> </sequence> </complexType> |
java.util.Vector | targetNamespace="http://xml.apache.org/xml-soap" <complexType name="Vector"> <sequence> <element maxOccurs="unbounded" minOccurs="0" name="item" type="xsd:anyType"/> </sequence> </complexType> |
java.util.types Where types can be Arrays, SortedMap, AbstractMap, Bitset, Dictionary, IdentityHashmap, LinkedHashMap, TreeMap This is not an exhaustive list of java.util types that could generate WSDL type xsd:anytype. |
xsd:anytype |
Object[] - array of Objects | <complexType name="ArrayOfXSDAnyType"> <sequence> <element maxOccurs="unbounded" minOccurs="0" name="anyType" nillable="true" type="xsd:anyType"/> </sequence> </complexType> |