uCosminexus Application Server, Web Service Development Guide

[Contents][Glossary][Index][Back][Next]

31.1 Configuration of the development example (starting from SEI or the attachments in the MTOM/XOP specification format)

This chapter describes an example of developing a Web Service starting from SEI. The Web Service to be developed uses the attachments in the MTOM/XOP specification format.

This section gives an overview of the Web Service to be developed and the information used.

Overview of the development example
This example describes how to develop a new Web Service that will manage the user information such as employee identification number, photograph, employee name, and affiliation, and return the processing results for the input from the Web Service client.
The following tables describe the information requested from the Web Service client and the server response.

Table 31-1 Request information from the Web Service client

Information Java data type
Employee identification number java.lang.String
Facial Photograph javax.activation.DataHandler

Table 31-2 Response from the server

Information Java data type
Registration confirmation message java.lang.String
Employee name java.lang.String
Affiliation java.lang.String

The response information from the server is stored in the user-defined Userdata class.

The following is the configuration of the current directory of the Web Service to be developed.

Table 31-3 Configuration of the current directory (starting from SEI and attachments)

Directory Explanation
c:\temp\jaxws\works\mtom\ This is the current directory.
 
server\ Used for developing the Web Services.
 
 
 
 
 
META-INF\ Corresponds to the META-INF directory of the EAR files.
 
application.xml Created in 31.3.4 Creating application.xml.
src\ Stores the source file (*.java) for the Web Service. Used in 31.3.1 Creating Web Services Implementation Classand 31.3.2 Compiling Web Services Implementation Classes.
WEB-INF\ Corresponds to the WEB-INF directory of the WAR files.
 
web.xml Created in 31.3.3 Creating web.xml.
 
classes\ Stores the compiled class file (*.class). Used in 31.3.2 Compiling Web Services Implementation Classes.
mtom_dynamic_generate.ear Created in 31.3.5 Creating EAR files.
mtom_dynamic_generate.war
 
client\ Used for developing the Web Service client.
 
 
 
 
 
src\ Stores the source file (*.java) of the Web Service client. Used in 31.5.1 Generating a service classand 31.5.2 Creating Implementation Class for the Web Services client.
classes\ Stores the compiled class file (*.class). Used in 27.5.3 Compiling an implementation class for the Web Service client.
portrait.png Used in the PNG file that is used in the Web Service client.
usrconf.cfg Created in 31.6.1 Creating an option definition file for Java applications.
usrconf.properties Created in 31.6.2 Creating a user property file for Java applications.

Change the current directory path according to the development environment.

Note that the description below uses the directory and files names mentioned in the above table. The values in bold used in the command execution examples or Java source are the values that are specified or generated in this example. Use appropriate values according to the environment you build.

Furthermore, in the development example described in this chapter, the Web Service and the Web Service client are developed in the same environment; however, they can be developed on different environments as well. To develop the Web Service and the Web Service client in separate environments, you must change the current directory path according to the respective environment.