File APIs for Java Developers
Manipulate DOC, XLS, PPT, PDF and many others from your application.
The moose likes Web Services and the fly likes Document datatype in wsdl Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login

Win a copy of REST with Spring (video course) this week in the Spring forum!
JavaRanch » Java Forums » Java » Web Services
Bookmark "Document datatype in wsdl" Watch "Document datatype in wsdl" New topic

Document datatype in wsdl

Lilly Wiesie

Joined: Jan 20, 2005
Posts: 26
Please forgive me if this question sounds dumb (I am new to web services. I guess I am allowed to ask some dumb questions ):

(1) If the style is document/literal, does that mean the return type of a method (in the service) is Document(an xml document)?

(2) I have a method returning an XML Doucment (public Document getThemes( ) ), how do I list the Document types in wsdl? Here is part of the wsdl Axis genetared:

<schema elementFormDefault="qualified" targetNamespace="http://localhost:8080/axis/services/ThemeServices" xmlns="">
<import namespace="" />
<element name="getThemesReturn" type="apachesoap ocument" />


When I tried to create a proxy in .Net, .Net complains as the following:

Error: Unable to import binding 'ThemeServicesSoapBinding' from namespace 'http://localhost:8080/axis/services/ThemeServices'.
- Unable to import operation 'getThemes'.
- The datatype ' ocument' is missing.

Evidentially "Document" is not a datatype that can be recognized by .Net.

I know I need to provide datatype for "Document", my question is how to define a "Document" datatype in wsdl?

Please help. Thanks.

Lilly Wiesie

Joined: Jan 20, 2005
Posts: 26
I didn't put in the big smily faces in the above post, they just showed up! Sorry!

Actually I have a more general question: how can we list the <types> for generic Java datatype such as Hashtable, ArrayList, etc in wsdl? Those datatatypes may not be recognized by other platform such as .Net. If I have a return from a method is Hashtable, how can I list it in wsdl?


Rr Kumaran
Ranch Hand

Joined: Sep 17, 2001
Posts: 548
doc/lit style web services include either the schema location in their wsdl or the schemas themselves and all ur custom types are converted into schemas and you should no how to write one.

RR Kumaran
SCJP 1.4
I agree. Here's the link:
subject: Document datatype in wsdl
It's not a secret anymore!