Solved

Java Implement WSDL operation with input/output complex type parameter

Posted on 2009-03-29
2
701 Views
Last Modified: 2013-11-19
Hi all, I have this WSDL:

<s:complexType name="Employee">
   <s:sequence>
      <s:element minOccurs="1" maxOccurs="1" name="fname" type="s:string" />
      <s:element minOccurs="1" maxOccurs="1" name="lname" type="s:string" />
      <s:element minOccurs="1" maxOccurs="1" name="active" type="s:boolean" />
      <s:element minOccurs="1" maxOccurs="1" name="age" type="s:int" />
      <s:element minOccurs="1" maxOccurs="1" name="hiredate" type="s:dateTime" />
      <s:element minOccurs="1" maxOccurs="1" name="number" type="s:double" />
   </s:sequence>
</s:complexType>


<s:complexType name="ResultEmployee">
   <s:sequence>
      <s:element minOccurs="1" maxOccurs="1" name="fEmplyeeId" type="s:boolean" />
      <s:element minOccurs="1" maxOccurs="1" name="lCount" type="s:int" />
   </s:sequence>
</s:complexType>


The Employee data type definition includes six elements, the data type of each element, and the name of each element.

Another excerpt from the WSDL file shows a message definition using the Employee data type. This message defines an input parameter, as the following code shows:

<message name="updateEmployeeInfoSoapIn">
   <part name="thestruct" type="s0:Employee" />
</message>

<message name="updateEmployeeInfoSoapOut">
   <part name="thestruct" type="s0:ResultEmployee" />
</message>

A third excerpt from the WSDL file shows the definition of an operation, named updateEmployeeInfo, possibly one that updates the employee database with the employee information. This operation takes as input a parameter of type Employee, as the following code shows:

<operation name="updateEmployeeInfo">
   <input message="s0:updateEmployeeInfoSoapIn" />
   <output message="s0:updateEmployeeInfoSoapOut" />
</operation>

How Can I implement the "updateEmployeeInfo" operation with Java?
Thanks!!!
0
Comment
Question by:jorgeani
2 Comments
 
LVL 1

Accepted Solution

by:
yogeshpmangrulkar earned 250 total points
Comment Utility
0
 
LVL 23

Assisted Solution

by:Siva Prasanna Kumar
Siva Prasanna Kumar earned 250 total points
Comment Utility
use WSDL2Java plugin provided by axis, axis2 or Eclipse it self for creating Java objects from WSDL, you will get all the in/out messages as Classes of thier own (POJO/Beans)
0

Featured Post

How to run any project with ease

Manage projects of all sizes how you want. Great for personal to-do lists, project milestones, team priorities and launch plans.
- Combine task lists, docs, spreadsheets, and chat in one
- View and edit from mobile/offline
- Cut down on emails

Join & Write a Comment

Browsers only know CSS so your awesome SASS code needs to be translated into normal CSS. Here I'll try to explain what you should aim for in order to take full advantage of SASS.
JavaScript has plenty of pieces of code people often just copy/paste from somewhere but never quite fully understand. Self-Executing functions are just one good example that I'll try to demystify here.
The viewer will learn how to create and use a small PHP class to apply a watermark to an image. This video shows the viewer the setup for the PHP watermark as well as important coding language. Continue to Part 2 to learn the core code used in creat…
The viewer will the learn the benefit of plain text editors and code an HTML5 based template for use in further tutorials.

728 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

13 Experts available now in Live!

Get 1:1 Help Now