axis-java-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From cha...@apache.org
Subject svn commit: r488606 [1/3] - in /webservices/axis2/trunk/java/xdocs/1_1: ./ images/
Date Tue, 19 Dec 2006 09:53:50 GMT
Author: chatra
Date: Tue Dec 19 01:53:49 2006
New Revision: 488606

URL: http://svn.apache.org/viewvc?view=rev&rev=488606
Log:
adding new user's guide

Added:
    webservices/axis2/trunk/java/xdocs/1_1/images/fig01.jpg   (with props)
    webservices/axis2/trunk/java/xdocs/1_1/images/fig02.jpg   (with props)
    webservices/axis2/trunk/java/xdocs/1_1/images/fig03.jpg   (with props)
    webservices/axis2/trunk/java/xdocs/1_1/images/fig04.jpg   (with props)
    webservices/axis2/trunk/java/xdocs/1_1/images/fig05.jpg   (with props)
    webservices/axis2/trunk/java/xdocs/1_1/images/fig06.jpg   (with props)
    webservices/axis2/trunk/java/xdocs/1_1/userguide-buildingservices.html
    webservices/axis2/trunk/java/xdocs/1_1/userguide-codelisting5.html
    webservices/axis2/trunk/java/xdocs/1_1/userguide-codelisting7.html
    webservices/axis2/trunk/java/xdocs/1_1/userguide-creatingclients-jibx.html
    webservices/axis2/trunk/java/xdocs/1_1/userguide-creatingclients-xmlbeans.html
    webservices/axis2/trunk/java/xdocs/1_1/userguide-creatingclients.html
    webservices/axis2/trunk/java/xdocs/1_1/userguide-forfurtherstudy.html
    webservices/axis2/trunk/java/xdocs/1_1/userguide-installingtesting.html
    webservices/axis2/trunk/java/xdocs/1_1/userguide-introtoservices.html
    webservices/axis2/trunk/java/xdocs/1_1/userguide-samples.html
    webservices/axis2/trunk/java/xdocs/1_1/userguide.html
Modified:
    webservices/axis2/trunk/java/xdocs/1_1/adv-userguide.html

Modified: webservices/axis2/trunk/java/xdocs/1_1/adv-userguide.html
URL: http://svn.apache.org/viewvc/webservices/axis2/trunk/java/xdocs/1_1/adv-userguide.html?view=diff&rev=488606&r1=488605&r2=488606
==============================================================================
--- webservices/axis2/trunk/java/xdocs/1_1/adv-userguide.html (original)
+++ webservices/axis2/trunk/java/xdocs/1_1/adv-userguide.html Tue Dec 19 01:53:49 2006
@@ -1,534 +1,534 @@
-<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">
-<html>
-<head>
-  <title>Axis2 User's Guide</title>
-  <link href="../css/axis-docs.css" rel="stylesheet" type="text/css" media="all" />
-</head>
-
-<body dir="ltr" lang="en-US">
-<a name="_Toc96697849" id="_Toc96697849"></a>
-<h1 align="center"> Apache Axis2 User's Guide</h1>
-
-<p>This guide will help you get started with Axis2, the next generation of
-Apache Axis! It describes in detail how to write Web services and Web
-service clients using Axis2; how to write custom modules and how to use them
-with a Web service. Advanced Topics and Samples which are shipped with the
-binary distribution of Axis2, are also discussed.</p>
-
-<a name="Introduction"></a>
-<h2>Introduction</h2>
-
-<p>This User's Guide is written based on <a
-href="../download/1_1/download.html/#std-bin">Axis2 Standard Binary
-Distribution</a>. The Standard Binary Distribution can be directly <a
-href="../download/1_1/download.html/#std-bin">downloaded</a> or
-built using the <a href="../download/1_1/download.html#src">Source
-Distribution</a>. If you choose to go for the latter, then <a
-href="installationguide.html">Installation Guide</a> will instruct you on how
-to build Axis2 Standard Binary Distribution using the Source.</p>
-
-<p>We hope you enjoy using Axis2. Please note that this is an open-source
-effort. If you feel the code could use some new features or fixes, please get
-involved and lend us a hand! The Axis developer community welcomes your
-participation.</p>
-
-<p>Let us know what you think! Send your feedback on Axis2 to "<a
-href="mailto:axis-user@ws.apache.org">axis-user@ws.apache.org</a>". Make sure
-to prefix the subject of the mail with [Axis2].</p>
-
-<h2>Getting Started</h2>
-
-<p>First two sections of the user guide will walk you through writing and
-deploying a new Web Service using Axis2, and writing a Web Service client
-using Axis2. Next section - <a href="#config"> Configuring Axis2</a> -
-provides a introduction to important configuration options in Axis2. Final
-section - <a href="#advanced">Advanced Topics</a> - provides references for
-other features</p>
-
-<p>In this section, we will learn how to write and deploy Web services using
-Axis2. All the samples mentioned in this guide are located in the
-<b>"samples/userguide/src"</b> directory of <a
-href="../download/1_1/download.html/#std-bin">Axis2 standard binary
-distribution</a>.</p>
-
-<p>Please deploy axis2.war in your servlet container and ensure that it works
-fine. <a href="installationguide.html" target="_blank">Installation Guide</a>
-gives you step by step instructions on just how to build axis2.war and deploy
-it in your servlet container.</p>
-<a name="ws_codegen"></a><a name="Web_Services_Using_Axis2"></a>
-<h2>Creating a New Web Service</h2>
-
-<p>If you are looking for "How to Write a Web Service Client using Axis2?"
-please go to the <a href="#client">next section</a>. Axis2 provides two ways
-to create new Web Services, using <strong>code generation</strong> and using XML based primary
-APIs. The following section explains how to start from a WSDL, and create a new
-Service with code generation. For the XML based primary API please refer to
-the section <a href="xmlbased-server.html">Writing Web Services Using Axis2's
-Primary APIs</a> for more information. However if you are a new user it is
-better to follow the code generation approach first (given below)</p>
-
-<h3>Starting with WSDL, Create and Deploy a Service</h3>
-
-<p>We start with a WSDL, however if you do not have a WSDL and need to create
-a WSDL from a java class please try <a
-href="reference.html#wsdl2java">Java2WSDL tool</a> and create a WSDL. As you
-might already know, a WSDL description of a Service provides precise
-definition of a Web Service. Axis2 could process the WSDL and generate java
-code that does most of work for you. At the server side we call them
-Skeletons and at the client side Stubs.</p>
-This method of writing a Web service with Axis2 involves four steps:
-<ol>
-  <li>Generate the skeleton code</li>
-  <li>Add business logic</li>
-  <li>Create a *.aar archive (Axis Archive) for the Web service</li>
-  <li>Deploy the Web service</li>
-</ol>
-
-<a name="Step1_:Generate_skeleton"></a>
-<h3>Step1: Generate Skeleton Code</h3>
-
-<p>To generate the skeleton and required classes, you can use the WSDL2Java
-tool provided in Axis2. This tool is located in the bin directory of the
-distribution and can be executed using the provided scripts (.bat or .sh).
-The tool's parameter list can be found from <a
-href="reference.html#wsdl2code">Axis2 Reference Document</a>.</p>
-
-<p>The parameters for wsdl2java tool in our example are as follows. Please
-note that we use xmlbeans as the data binding framework and generated code
-will be sent to samples directory. Other data binding tools you could use are
-adb (Axis data binding) and jaxme (<a
-href="http://ws.apache.org/jaxme/">JaxMe data binding</a>)</p>
-<pre>
-WSDL2Java.sh -uri ../samples/wsdl/Axis2SampleDocLit.wsdl -ss -sd -d xmlbeans 
--o ../samples -p org.apache.axis2.userguide
-</pre>
-
-<p>This will generate the required classes in the <b>"sample/src"</b>
-directory, and the schema classes in
-<strong>"samples/resources/schemaorg_apache_xmlbeans"</strong>
-directory<strong></strong>. Note that these are not source files and should
-be available in the class path in order to compile the generated classes.</p>
-
-<a name="Step2_Implement_Business_Logic"></a>
-<h3>Step 2: Implement Business
-Logic</h3>
-
-<p>Now you should fill the business logic in the skeleton class. You can
-find the skeleton class -Axis2SampleDocLitServiceSkeleton.java- among the
-generated classes in the
-<strong>"samples/src/org/apache/axis2/userguide</strong> directory. Let's
-fill the <code>echoString(..)</code> method in the skeleton as shown below. Our sample
-WSDL-Axis2SampleDocLit.wsdl in <strong>"samples/wsdl"</strong> directory has
-three operations: echoString, echoStringArray, echoStruct. To see how others
-will look when they are filled up see <a
-href="src/Axis2SampleDocLitServiceCode.html">Code Listing For
-Axis2SampleDocLitService Service</a></p>
-<source>
-<pre>
-public org.apache.axis2.userguide.xsd.EchoStringReturnDocument 
-    echoString(org.apache.axis2.userguide.xsd.EchoStringParamDocument param4) throws Exception {
-    //Use the factory to create the output document.
-    org.apache.axis2.userguide.xsd.EchoStringReturnDocument retDoc = 
-           org.apache.axis2.userguide.xsd.EchoStringReturnDocument.Factory.newInstance();
-    //send the string back.
-    retDoc.setEchoStringReturn(param4.getEchoStringParam());
-   return retDoc;<br>
-</pre></source>
-
-<a name="Step4_Create_archive"></a>
-<h3>Step 3: Create Archive File</h3>
-
-<p>An Axis2 service must be bundled as a service archive. The next step is to
-package the classes in an .aar (axis2 archive) and deploy it in Axis2. There
-is an ant file generated with the code, this will generate the Axis2 service
-archive for you. However if you do not want to use ant, you could create
-archive with following steps :</p>
-<ol>
-  <li>Compile the generated code</li>
-  <li>Copy <strong>"resources/schemaorg_apache_xmlbeans</strong>" xmlbeans
-    classes to your class folder</li>
-  <li>Among the generated files, there will be services.xml file, which is the
-    deployment descriptor for Axis2 service.[<a
-    href="reference.html#servicedd">learn more about it</a>]. Copy the
-    resources/service.xml to META-INF/services.xml</li>
-  <p>(To write your own service.xml file see sub section in <a href="xmlbased-server.html#Step2_:Write_the_services_xml_file">Writing Web Services Using Axis2's Primary APIs</a> section.)</p>
-  <li>Create the archive using content of the class folder. Change directory
-    to class folder and run <code>jar -cf &lt;service-name&gt;.aar</code> to
-    create the archive</li>
-</ol>
-
-<p>Once the archive is created, the content of the jar should look like
-this</p>
-
-<p><img src="images/userguide/DirectoryStructure.jpg" align="bottom"
-border="0"></p>
-
-<a name="Step5_Deploy_web_service"></a>
-<h3>Step 4: Deploy Web Service</h3>
-
-<p>The service can be deployed by simply dropping the ".aar" file into
-"services" directory in "/webapps/axis2/WEB-INF" of your servlet container.
-We recommend using <a href="http://tomcat.apache.org/">Apache Tomcat</a> as
-servlet container. <strong>Please Note that the services directory is
-available only after axis2.war is exploded by Tomcat. However, the easiest way
-to do it is to start Tomcat after axis2.war is copied to the webapps
-directory</strong> (if you have not already started). Check the link
-"Services" on the <a href="http://localhost:8080/axis2/" target="_blank">Home
-Page of Axis2 Web Application</a> (http://localhost:8080/axis2) and see
-whether the Axis2SampleDocLitService is shown under the deployed services.</p>
-
-<p>We recommend using the exploded configuration to deploy Axis2 WAR in
-<strong>WebLogic and WebSphere</strong> application servers to support the
-hotupdate/ hotdeployment features in Axis2. See <a href="app_server.html#weblogic_websphere">Application Server Specific
-Configuration Guide</a> for details.</p>
-
-<p>Note: Axis2 provides an easy way to deploy Web Services using the "Upload
-Service" tool on Axis2 Web Application's Administration module. (See the <a
-href="webadminguide.html" target="_blank">Web Administration Guide</a> for
-more information on this)</p>
-
-<a name="client"></a>
-<h2>Writing a Web Service Client</h2>
-
-<p>Axis2 also provides a more complex, yet powerful XML based client
-API which is intended for advanced users. Read <a
-href="dii.html">Writing Web Service Clients Using Axis2's Primary APIs</a> to
-learn more about it. However, if you are a new user we recommend using the <strong>code
-generation</strong> approach presented below.</p>
-
-<h3>Generate Stubs</h3>
-
-<p>Let's see how we could generate java code (Stub) to handle the client side
-Web Service invocation for you. That can be done by running the WSDL2Java
-tool using following arguments</p>
-<source>
-<pre>WSDL2Java.sh -uri ../samples/wsdl/Axis2SampleDocLit.wsdl -d xmlbeans 
-     -o ../samples/src -p org.apache.axis2.userguide
-</pre></source>
-
-
-<p>This will generate client side stubs and xmlbeans types for your types.
-The Stub class that you need to use will be of the form
-<strong>&lt;service-name&gt;Stub</strong>. For our example it will be called
-"Axis2SampleDocLitServiceStub.java"</p>
-
-<p>Axis2 clients can invoke Web Services both in blocking and non-blocking
-manner. In a blocking invocation, the client waits till the service performs
-its task without proceeding to the next step. Normally the client waits till
-the response to the particular request arrives. In a non-blocking invocation,
-the client proceeds to the next step immediately and any responses (if any)
-are handled using a Callback mechanism. Please note that some explanations
-use the terms Synchronous and Asynchronous to describe the similar invocation
-strategies.</p>
-
-<h3>Do a Blocking Invocation</h3>
-
-<p>The following code fragment shows the necessary code calling
-<code>echoString</code> operation of the
-<code>Axis2SampleDocLitService</code> that we have already deployed. The code
-is extremely simple to understand and the explanations are in the form of
-comments.</p>
-<source>
-<pre>     try {
-               org.apache.axis2.userguide.Axis2SampleDocLitServiceStub stub 
-                  = new org.apache.axis2.userguide.Axis2SampleDocLitServiceStub(null,
-                    "http://localhost:8080/axis2/services/Axis2SampleDocLitService");
-                //Create the request document to be sent.
-                org.apache.axis2.userguide.xsd.EchoStringParamDocument reqDoc =
-                org.apache.axis2.userguide.xsd.EchoStringParamDocument.Factory.newInstance();
-                reqDoc.setEchoStringParam("Axis2 Echo");
-                //invokes the Web service.
-                org.apache.axis2.userguide.xsd.EchoStringReturnDocument resDoc = 
-                stub.echoString(reqDoc);
-                System.out.println(resDoc.getEchoStringReturn());
-               } catch (java.rmi.RemoteException e) {
-                  e.printStackTrace();
-              }
-</pre></source>
-
-<p>First argument of <code>Axis2SampleDocLitPortTypeStub</code> should be the
-Axis2 repository for the client. Here we use null to make the stub use
-default configurations. However you could make Axis2 use your own repository
-by providing it here. You could find more information about this from <a
-href="#config">Axis2 Configuration section</a>. You can find code to invoke
-other operations from <a href="src/Axis2SampleDocLitServiceCode.html">Code
-Listing For Axis2SampleDocLitService Service</a></p>
-
-<h3>Do a Non-Blocking Invocation</h3>
-
-<p>The stubs also include a method that allows you to do a non-blocking
-innovation, for each method in the Service there will be a method
-<strong>start&lt;method-name&gt;</strong>. These methods accept a callback
-object which would be called when the response is received. Sample code that
-does an asynchronous interaction is given below.</p>
-<source>
-<pre>try {
-         org.apache.axis2.userguide.Axis2SampleDocLitServiceStub stub
-           = new org.apache.axis2.userguide.Axis2SampleDocLitServiceStub(null,
-             "http://localhost:8080/axis2/services/Axis2SampleDocLitService");
-             //implementing the callback online
-            org.apache.axis2.userguide.Axis2SampleDocLitServiceCallbackHandler callback =
-            new org.apache.axis2.userguide.Axis2SampleDocLitServiceCallbackHandler() {
-                    public void receiveResultechoString(
-                      org.apache.axis2.userguide.xsd.EchoStringReturnDocument resDoc) {
-                       System.out.println(resDoc.getEchoStringReturn());
-                       }
-            };
-        org.apache.axis2.userguide.xsd.EchoStringParamDocument reqDoc = 
-          org.apache.axis2.userguide.xsd.EchoStringParamDocument.Factory.newInstance();
-           reqDoc.setEchoStringParam("Axis2 Echo");
-           stub.startechoString(reqDoc, callback);
-        } catch (java.rmi.RemoteException e) {
-          e.printStackTrace();
-       }
-</pre>
-</source>
-
-
-<p>Even though the above code does a non-blocking invocation at the client
-API, the transport connection may still operate in blocking fashion. For
-example, a single HTTP connection can be used to make the Web Service request
-and to get the response where a blocking invocation happens at the transport
-level. To perform a "true" Non-Blocking invocation in which two separate
-transport connections are used for the request and the response please add
-the following code segment after creating the stub. These will force Axis2 to
-use two transport connections for the request and the response while the
-client uses a Callback to process the response.</p>
-<source>
-<pre>
-stub._getServiceClient().engageModule(new QName("addressing"));
-stub._getServiceClient().getOptions().setUseSeparateListener(true);
-</pre>
-</source>
-
-
-<p>Once those options are set, Axis2 client does the following:</p>
-<ol>
-  <li>Start a new Transport Listener(Server) at the client side</li>
-  <li>Set the address of the Transport Listener, as the ReplyTo WS-Addressing
-    Header of the request Message</li>
-  <li>According to the WS-Addressing rules, Server will process the request
-    message and send the response back to the ReplyTo address</li>
-  <li>Client accepts the response, processes it and invokes the callback with
-    the response parameters</li>
-</ol>
-
-<h3>Using Your Own Repository</h3>
-
-<p>You could use your own repository with Axis2 Client, code below shows
-how to do this.</p>
-<source>
-<pre>
-String axis2Repo = ...
-String axis2xml = ...
-ConfigurationContext configContext =
-ConfigurationContextFactory.createConfigurationContextFromFileSystem(axis2Repo, axis2xml);
-Service1Stub stub1 = new Service1Stub(configContext,...);
-//invoke Service1
-Service2Stub stub2 = new Service2Stub(configContext,...);
-//invoke Service2
-</pre>
-</source>
-
-
-<p>Note by creating the <code>ConfigurationContext</code> outside and
-passing it to the stubs, you could make number of stubs to use same
-repository, thus saving the configuration loading overhead from each
-request.</p>
-
-<a name="config"></a>
-<h2>Configuring Axis2</h2>
-
-<h3>Axis2 Repository</h3>
-
-<p>Axis2 configuration is based on a repository and standard archives
-formats. A repository is a directory in the file system and it should have
-the following:</p>
-<ol>
-  <li><strong>axis2.xml</strong>, the Axis2 global deployment descriptor in
-    conf/axis2.xml file</li>
-  <li><strong>services</strong> directory, which will have service
-  archives</li>
-  <li>optional <strong>modules</strong> directory, which will have module
-    archives</li>
-</ol>
-
-<p>Both services and modules will be identified and deployed once their
-archives are copied to the corresponding directories. At the server side
-users should specify the repository folder at the time of starting a Axis2
-Server (e.g. HTTP or TCP). In Tomcat, <code>webapps/axis2/WEB-INF</code>
-folder acts as the repository. At the client side binary distribution can
-itself be a repository. You can copy the conf directory which includes the
-axis2.xml file from the exploded axis2.war and edit it to change global
-configurations repository.</p>
-
-<h3>Global Configurations</h3>
-
-<p>The Global configuration can be changed by editing the axis2.xml file,
-look at the <a href="axis2config.html#Global_Configuration">Axis2
-Configuration Guide</a> for more information</p>
-
-<h3>Add new Services</h3>
-
-<p>New Services can be written either using WSDL based code generation as we
-did, or from the scratch as explained <a
-href="xmlbased-server.html">here</a>. Read <a
-href="xmlbased-server.html">Creating a Service from Scratch</a> for more
-information. Also refer to <a
-href="axis2config.html#Service_Configuration">Axis2 Configuration Guide</a>
-for a reference on <strong>services.xml</strong> file.</p>
-
-<h3 name="module_engage">Engaging Modules</h3>
-
-<p>Each module(.mar file) provides extensions to Axis2. A module can be
-deployed by copying it in to the modules directory in the repository. Then it
-becomes available and can be engaged at global, service or operation scopes.
-Once engaged it becomes active (add handlers to the execution flow) at the
-respective scope. Please refer to <a href="Axis2ArchitectureGuide.html">Axis2
-architecture guide</a> for detailed explanation. The following table explains the
-semantics of scope and how to engage modules in those scopes.</p>
-
-<table border="1">
-  <tbody>
-    <tr>
-      <th>Scope</th>
-      <th>Semantics</th>
-      <th>how to engage</th>
-    </tr>
-    <tr>
-      <td>Global</td>
-      <td>Add handlers in the module to all the services. Addressing Handler
-        can be only engaged as global</td>
-      <td>By adding a &lt;module ref="addressing"/&gt; to Axis2 xml file or
-        calling
-        <pre>stub._getServiceClient().engageModule(moduleName)</pre>
-        at client side</td>
-    </tr>
-    <tr>
-      <td>Service</td>
-      <td>Add handlers in the module to a specific service</td>
-      <td>By adding a &lt;module ref="addressing"/&gt; to service.xml file in
-        service archive</td>
-    </tr>
-    <tr>
-      <td>Operation</td>
-      <td>Add handlers in the module to a specific operation</td>
-      <td>By adding a &lt;module ref="addressing"/&gt; to inside a operation
-        tag of service.xml file in service archive</td>
-    </tr>
-  </tbody>
-</table>
-
-<p>* If a handler is added to a service or an operation, it will be invoked
-for every request received by that service or operation</p>
-
-<p>Axis2 provides a number of built in Modules such as (<a
-href="">addressing</a>,<a href="">Security</a>, <a href="">WS-Reliable
-Messaging</a> ...), and they can be engaged as shown above. Please refer to
-each module for how to use and configure them. You can also <a
-href="modules.html">create your own modules with Axis2</a>. Also refer to <a
-href="axis2config.html#Global_Configuration">Axis2 Configuration Guide</a>
-for a reference on module.xml file.</p>
-
-<h3>WS-Addressing Support</h3>
-
-<p>WS-Addressing support for Axis2 is implemented by the addressing module.
-To enable addressing you need to engage the addressing module in both server
-and client sides. In order to do this:</p>
-<ol>
-  <li>To <strong>enable</strong> addressing at the server side you need to
-    copy addressing.mar file to modules directory of server's axis2
-    repository. To engage the module, add a &lt;module ref="addressing"/&gt; to
-    axis2.xml. <strong>Addressing module can be engaged only at global
-    level</strong></li>
-  <li>To <strong>enable</strong> addressing at the client side you should add
-    it to the repository and provide the repository as argument to the <a
-    href="dii.html">ServiceClient</a> or <a href="#client">generated stub</a>
-    or have it in your classpath</li>
-  <li>To <strong>engage</strong> addressing module you should either add
-    &lt;module ref="addressing"/&gt; to axis2.xml file at the client side or
-    call
-    <pre>stub._getServiceClient().engageModule(moduleName)</pre>
-  </li>
-</ol>
-
-<a name="advanced"></a>
-<h2>Advanced Topics</h2>
-
-<h3>Transports</h3>
-
-<p>Axis2 is by default configured to use HTTP as the transport. However Axis2
-supports HTTP, SMTP, TCP and JMS transports. You can also write your own
-transports, and deploy them by adding new transportReceiver or
-transportSender tags to axis2.xml. To learn how to configure and use
-different transports please refer the following documents.</p>
-<ol>
-  <li><a href="tcp-transport.html" target="_blank">TCP Transport</a></li>
-  <li><a href="mail-transport.html" target="_blank">Mail Transport</a></li>
-  <li><a href="http-transport.html" target="_blank">HTTP Transports</a></li>
-  <li><a href="jms-transport.html" target="_blank">JMS Transports</a></li>
-</ol>
-
-<h3>Attachments</h3>
-
-<p>Axis2 provides attachment support using <a
-href="http://www.w3.org/TR/soap12-mtom/">MTOM</a>. Please refer to <a
-href="mtom-guide.html" target="_blank">MTOM with Axis2</a> for more
-information.</p>
-
-<h3>Security</h3>
-
-<p>Axis2 provides Security support using the <a
-href="http://ws.apache.org/axis2/modules/rampart/1_0/security-module.html">Apache
-Rampart</a>. Please refer to <a
-href="../modules/wss4j/1_0/security-module.html" target="_blank">Securing
-SOAP Messages with Apache Rampart</a> for more information</p>
-
-<h3>REST Web Service</h3>
-
-<p>Please refer to <a href="rest-ws.html" target="_blank">RESTful Web
-Services</a> for more information</p>
-
-<h3>Pluggable Data Binding</h3>
-
-<p>Axis2 ships with Axis Data Binding(ADB) as the default data binding
-framework, however the data binding frameworks are pluggable to Axis2, and
-you could use other data binding frameworks with Axis2. Please refer the
-following documents for more information.</p>
-
-<h4>Axis2 Data Binding(ADB)</h4>
-<ol>
-  <li><a href="adb/adb-howto.html" target="_blank">Axis2 Databinding
-    Framework</a></li>
-  <li><a href="adb/adb-codegen-integration.html" target="_blank">ADB
-    Integration With Axis2</a></li>
-  <li><a href="adb/adb-advanced.html">Advanced Axis2 Databinding Framework
-    Features</a></li>
-  <li><a href="adb/adb-tweaking.html">ADB Tweaking Guide</a></li>
-</ol>
-
-<h4>JiBX</h4>
-<a href="jibx/jibx-codegen-integration.html">JiBX Integration With Axis2</a>
-
-<h3>Other Topics</h3>
-<ol>
-  <li><a href="spring.html" target="_blank">Axis2 Integration With The Spring
-    Framework</a></li>
-  <li><a href="WS_policy.html" target="_blank">Web Services Policy Support In
-    Axis2</a></li>
-  <li><a href="axis2config.html#Global_Configuration">Axis2 Configuration
-    Guide</a></li>
-  <li><a href="Axis2-rpc-support.html">Axis2 RPC Support</a></li>
-  <li><a href="migration.html">Migrating from Apache Axis 1.x to Axis
-  2</a></li>
-  <li><a href="modules.html">Writing your Own Axis2 Module</a></li>
-  <li><a href="soapmonitor-module.html">Using the SOAP Monitor</a></li>
-  <li><a href="xmlbased-server.html">Writing Web Services Using Axis2's
-    Primary APIs</a></li>
-  <li><a href="dii.html">Writing Web Service Clients Using Axis2's Primary
-    APIs</a></li>
-  <li><a href="app_server.html">Application Server Specific Configuration
-    Guide</a></li>
-</ol>
-</body>
-</html>
+<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">
+<html>
+<head>
+  <title>Axis2 Advance User's Guide</title>
+  <link href="../css/axis-docs.css" rel="stylesheet" type="text/css" media="all" />
+</head>
+
+<body dir="ltr" lang="en-US">
+<a name="_Toc96697849" id="_Toc96697849"></a>
+<h1 align="center"> Apache Axis2 Advance User's Guide</h1>
+
+<p>This guide will help you get started with Axis2, the next generation of
+Apache Axis! It describes in detail how to write Web services and Web
+service clients using Axis2; how to write custom modules and how to use them
+with a Web service. Advanced Topics and Samples which are shipped with the
+binary distribution of Axis2, are also discussed.</p>
+
+<a name="Introduction"></a>
+<h2>Introduction</h2>
+
+<p>This User's Guide is written based on <a
+href="../download/1_1/download.html/#std-bin">Axis2 Standard Binary
+Distribution</a>. The Standard Binary Distribution can be directly <a
+href="../download/1_1/download.html/#std-bin">downloaded</a> or
+built using the <a href="../download/1_1/download.html#src">Source
+Distribution</a>. If you choose to go for the latter, then <a
+href="installationguide.html">Installation Guide</a> will instruct you on how
+to build Axis2 Standard Binary Distribution using the Source.</p>
+
+<p>We hope you enjoy using Axis2. Please note that this is an open-source
+effort. If you feel the code could use some new features or fixes, please get
+involved and lend us a hand! The Axis developer community welcomes your
+participation.</p>
+
+<p>Let us know what you think! Send your feedback on Axis2 to "<a
+href="mailto:axis-user@ws.apache.org">axis-user@ws.apache.org</a>". Make sure
+to prefix the subject of the mail with [Axis2].</p>
+
+<h2>Getting Started</h2>
+
+<p>First two sections of the user guide will walk you through writing and
+deploying a new Web Service using Axis2, and writing a Web Service client
+using Axis2. Next section - <a href="#config"> Configuring Axis2</a> -
+provides a introduction to important configuration options in Axis2. Final
+section - <a href="#advanced">Advanced Topics</a> - provides references for
+other features</p>
+
+<p>In this section, we will learn how to write and deploy Web services using
+Axis2. All the samples mentioned in this guide are located in the
+<b>"samples/userguide/src"</b> directory of <a
+href="../download/1_1/download.html/#std-bin">Axis2 standard binary
+distribution</a>.</p>
+
+<p>Please deploy axis2.war in your servlet container and ensure that it works
+fine. <a href="installationguide.html" target="_blank">Installation Guide</a>
+gives you step by step instructions on just how to build axis2.war and deploy
+it in your servlet container.</p>
+<a name="ws_codegen"></a><a name="Web_Services_Using_Axis2"></a>
+<h2>Creating a New Web Service</h2>
+
+<p>If you are looking for "How to Write a Web Service Client using Axis2?"
+please go to the <a href="#client">next section</a>. Axis2 provides two ways
+to create new Web Services, using <strong>code generation</strong> and using XML based primary
+APIs. The following section explains how to start from a WSDL, and create a new
+Service with code generation. For the XML based primary API please refer to
+the section <a href="xmlbased-server.html">Writing Web Services Using Axis2's
+Primary APIs</a> for more information. However if you are a new user it is
+better to follow the code generation approach first (given below)</p>
+
+<h3>Starting with WSDL, Create and Deploy a Service</h3>
+
+<p>We start with a WSDL, however if you do not have a WSDL and need to create
+a WSDL from a java class please try <a
+href="reference.html#wsdl2java">Java2WSDL tool</a> and create a WSDL. As you
+might already know, a WSDL description of a Service provides precise
+definition of a Web Service. Axis2 could process the WSDL and generate java
+code that does most of work for you. At the server side we call them
+Skeletons and at the client side Stubs.</p>
+This method of writing a Web service with Axis2 involves four steps:
+<ol>
+  <li>Generate the skeleton code</li>
+  <li>Add business logic</li>
+  <li>Create a *.aar archive (Axis Archive) for the Web service</li>
+  <li>Deploy the Web service</li>
+</ol>
+
+<a name="Step1_:Generate_skeleton"></a>
+<h3>Step1: Generate Skeleton Code</h3>
+
+<p>To generate the skeleton and required classes, you can use the WSDL2Java
+tool provided in Axis2. This tool is located in the bin directory of the
+distribution and can be executed using the provided scripts (.bat or .sh).
+The tool's parameter list can be found from <a
+href="reference.html#wsdl2code">Axis2 Reference Document</a>.</p>
+
+<p>The parameters for wsdl2java tool in our example are as follows. Please
+note that we use xmlbeans as the data binding framework and generated code
+will be sent to samples directory. Other data binding tools you could use are
+adb (Axis data binding) and jaxme (<a
+href="http://ws.apache.org/jaxme/">JaxMe data binding</a>)</p>
+<pre>
+WSDL2Java.sh -uri ../samples/wsdl/Axis2SampleDocLit.wsdl -ss -sd -d xmlbeans 
+-o ../samples -p org.apache.axis2.userguide
+</pre>
+
+<p>This will generate the required classes in the <b>"sample/src"</b>
+directory, and the schema classes in
+<strong>"samples/resources/schemaorg_apache_xmlbeans"</strong>
+directory<strong></strong>. Note that these are not source files and should
+be available in the class path in order to compile the generated classes.</p>
+
+<a name="Step2_Implement_Business_Logic"></a>
+<h3>Step 2: Implement Business
+Logic</h3>
+
+<p>Now you should fill the business logic in the skeleton class. You can
+find the skeleton class -Axis2SampleDocLitServiceSkeleton.java- among the
+generated classes in the
+<strong>"samples/src/org/apache/axis2/userguide</strong> directory. Let's
+fill the <code>echoString(..)</code> method in the skeleton as shown below. Our sample
+WSDL-Axis2SampleDocLit.wsdl in <strong>"samples/wsdl"</strong> directory has
+three operations: echoString, echoStringArray, echoStruct. To see how others
+will look when they are filled up see <a
+href="src/Axis2SampleDocLitServiceCode.html">Code Listing For
+Axis2SampleDocLitService Service</a></p>
+<source>
+<pre>
+public org.apache.axis2.userguide.xsd.EchoStringReturnDocument 
+    echoString(org.apache.axis2.userguide.xsd.EchoStringParamDocument param4) throws Exception {
+    //Use the factory to create the output document.
+    org.apache.axis2.userguide.xsd.EchoStringReturnDocument retDoc = 
+           org.apache.axis2.userguide.xsd.EchoStringReturnDocument.Factory.newInstance();
+    //send the string back.
+    retDoc.setEchoStringReturn(param4.getEchoStringParam());
+   return retDoc;<br>
+</pre></source>
+
+<a name="Step4_Create_archive"></a>
+<h3>Step 3: Create Archive File</h3>
+
+<p>An Axis2 service must be bundled as a service archive. The next step is to
+package the classes in an .aar (axis2 archive) and deploy it in Axis2. There
+is an ant file generated with the code, this will generate the Axis2 service
+archive for you. However if you do not want to use ant, you could create
+archive with following steps :</p>
+<ol>
+  <li>Compile the generated code</li>
+  <li>Copy <strong>"resources/schemaorg_apache_xmlbeans</strong>" xmlbeans
+    classes to your class folder</li>
+  <li>Among the generated files, there will be services.xml file, which is the
+    deployment descriptor for Axis2 service.[<a
+    href="reference.html#servicedd">learn more about it</a>]. Copy the
+    resources/service.xml to META-INF/services.xml</li>
+  <p>(To write your own service.xml file see sub section in <a href="xmlbased-server.html#Step2_:Write_the_services_xml_file">Writing Web Services Using Axis2's Primary APIs</a> section.)</p>
+  <li>Create the archive using content of the class folder. Change directory
+    to class folder and run <code>jar -cf &lt;service-name&gt;.aar</code> to
+    create the archive</li>
+</ol>
+
+<p>Once the archive is created, the content of the jar should look like
+this</p>
+
+<p><img src="images/userguide/DirectoryStructure.jpg" align="bottom"
+border="0"></p>
+
+<a name="Step5_Deploy_web_service"></a>
+<h3>Step 4: Deploy Web Service</h3>
+
+<p>The service can be deployed by simply dropping the ".aar" file into
+"services" directory in "/webapps/axis2/WEB-INF" of your servlet container.
+We recommend using <a href="http://tomcat.apache.org/">Apache Tomcat</a> as
+servlet container. <strong>Please Note that the services directory is
+available only after axis2.war is exploded by Tomcat. However, the easiest way
+to do it is to start Tomcat after axis2.war is copied to the webapps
+directory</strong> (if you have not already started). Check the link
+"Services" on the <a href="http://localhost:8080/axis2/" target="_blank">Home
+Page of Axis2 Web Application</a> (http://localhost:8080/axis2) and see
+whether the Axis2SampleDocLitService is shown under the deployed services.</p>
+
+<p>We recommend using the exploded configuration to deploy Axis2 WAR in
+<strong>WebLogic and WebSphere</strong> application servers to support the
+hotupdate/ hotdeployment features in Axis2. See <a href="app_server.html#weblogic_websphere">Application Server Specific
+Configuration Guide</a> for details.</p>
+
+<p>Note: Axis2 provides an easy way to deploy Web Services using the "Upload
+Service" tool on Axis2 Web Application's Administration module. (See the <a
+href="webadminguide.html" target="_blank">Web Administration Guide</a> for
+more information on this)</p>
+
+<a name="client"></a>
+<h2>Writing a Web Service Client</h2>
+
+<p>Axis2 also provides a more complex, yet powerful XML based client
+API which is intended for advanced users. Read <a
+href="dii.html">Writing Web Service Clients Using Axis2's Primary APIs</a> to
+learn more about it. However, if you are a new user we recommend using the <strong>code
+generation</strong> approach presented below.</p>
+
+<h3>Generate Stubs</h3>
+
+<p>Let's see how we could generate java code (Stub) to handle the client side
+Web Service invocation for you. That can be done by running the WSDL2Java
+tool using following arguments</p>
+<source>
+<pre>WSDL2Java.sh -uri ../samples/wsdl/Axis2SampleDocLit.wsdl -d xmlbeans 
+     -o ../samples/src -p org.apache.axis2.userguide
+</pre></source>
+
+
+<p>This will generate client side stubs and xmlbeans types for your types.
+The Stub class that you need to use will be of the form
+<strong>&lt;service-name&gt;Stub</strong>. For our example it will be called
+"Axis2SampleDocLitServiceStub.java"</p>
+
+<p>Axis2 clients can invoke Web Services both in blocking and non-blocking
+manner. In a blocking invocation, the client waits till the service performs
+its task without proceeding to the next step. Normally the client waits till
+the response to the particular request arrives. In a non-blocking invocation,
+the client proceeds to the next step immediately and any responses (if any)
+are handled using a Callback mechanism. Please note that some explanations
+use the terms Synchronous and Asynchronous to describe the similar invocation
+strategies.</p>
+
+<h3>Do a Blocking Invocation</h3>
+
+<p>The following code fragment shows the necessary code calling
+<code>echoString</code> operation of the
+<code>Axis2SampleDocLitService</code> that we have already deployed. The code
+is extremely simple to understand and the explanations are in the form of
+comments.</p>
+<source>
+<pre>     try {
+               org.apache.axis2.userguide.Axis2SampleDocLitServiceStub stub 
+                  = new org.apache.axis2.userguide.Axis2SampleDocLitServiceStub(null,
+                    "http://localhost:8080/axis2/services/Axis2SampleDocLitService");
+                //Create the request document to be sent.
+                org.apache.axis2.userguide.xsd.EchoStringParamDocument reqDoc =
+                org.apache.axis2.userguide.xsd.EchoStringParamDocument.Factory.newInstance();
+                reqDoc.setEchoStringParam("Axis2 Echo");
+                //invokes the Web service.
+                org.apache.axis2.userguide.xsd.EchoStringReturnDocument resDoc = 
+                stub.echoString(reqDoc);
+                System.out.println(resDoc.getEchoStringReturn());
+               } catch (java.rmi.RemoteException e) {
+                  e.printStackTrace();
+              }
+</pre></source>
+
+<p>First argument of <code>Axis2SampleDocLitPortTypeStub</code> should be the
+Axis2 repository for the client. Here we use null to make the stub use
+default configurations. However you could make Axis2 use your own repository
+by providing it here. You could find more information about this from <a
+href="#config">Axis2 Configuration section</a>. You can find code to invoke
+other operations from <a href="src/Axis2SampleDocLitServiceCode.html">Code
+Listing For Axis2SampleDocLitService Service</a></p>
+
+<h3>Do a Non-Blocking Invocation</h3>
+
+<p>The stubs also include a method that allows you to do a non-blocking
+innovation, for each method in the Service there will be a method
+<strong>start&lt;method-name&gt;</strong>. These methods accept a callback
+object which would be called when the response is received. Sample code that
+does an asynchronous interaction is given below.</p>
+<source>
+<pre>try {
+         org.apache.axis2.userguide.Axis2SampleDocLitServiceStub stub
+           = new org.apache.axis2.userguide.Axis2SampleDocLitServiceStub(null,
+             "http://localhost:8080/axis2/services/Axis2SampleDocLitService");
+             //implementing the callback online
+            org.apache.axis2.userguide.Axis2SampleDocLitServiceCallbackHandler callback =
+            new org.apache.axis2.userguide.Axis2SampleDocLitServiceCallbackHandler() {
+                    public void receiveResultechoString(
+                      org.apache.axis2.userguide.xsd.EchoStringReturnDocument resDoc) {
+                       System.out.println(resDoc.getEchoStringReturn());
+                       }
+            };
+        org.apache.axis2.userguide.xsd.EchoStringParamDocument reqDoc = 
+          org.apache.axis2.userguide.xsd.EchoStringParamDocument.Factory.newInstance();
+           reqDoc.setEchoStringParam("Axis2 Echo");
+           stub.startechoString(reqDoc, callback);
+        } catch (java.rmi.RemoteException e) {
+          e.printStackTrace();
+       }
+</pre>
+</source>
+
+
+<p>Even though the above code does a non-blocking invocation at the client
+API, the transport connection may still operate in blocking fashion. For
+example, a single HTTP connection can be used to make the Web Service request
+and to get the response where a blocking invocation happens at the transport
+level. To perform a "true" Non-Blocking invocation in which two separate
+transport connections are used for the request and the response please add
+the following code segment after creating the stub. These will force Axis2 to
+use two transport connections for the request and the response while the
+client uses a Callback to process the response.</p>
+<source>
+<pre>
+stub._getServiceClient().engageModule(new QName("addressing"));
+stub._getServiceClient().getOptions().setUseSeparateListener(true);
+</pre>
+</source>
+
+
+<p>Once those options are set, Axis2 client does the following:</p>
+<ol>
+  <li>Start a new Transport Listener(Server) at the client side</li>
+  <li>Set the address of the Transport Listener, as the ReplyTo WS-Addressing
+    Header of the request Message</li>
+  <li>According to the WS-Addressing rules, Server will process the request
+    message and send the response back to the ReplyTo address</li>
+  <li>Client accepts the response, processes it and invokes the callback with
+    the response parameters</li>
+</ol>
+
+<h3>Using Your Own Repository</h3>
+
+<p>You could use your own repository with Axis2 Client, code below shows
+how to do this.</p>
+<source>
+<pre>
+String axis2Repo = ...
+String axis2xml = ...
+ConfigurationContext configContext =
+ConfigurationContextFactory.createConfigurationContextFromFileSystem(axis2Repo, axis2xml);
+Service1Stub stub1 = new Service1Stub(configContext,...);
+//invoke Service1
+Service2Stub stub2 = new Service2Stub(configContext,...);
+//invoke Service2
+</pre>
+</source>
+
+
+<p>Note by creating the <code>ConfigurationContext</code> outside and
+passing it to the stubs, you could make number of stubs to use same
+repository, thus saving the configuration loading overhead from each
+request.</p>
+
+<a name="config"></a>
+<h2>Configuring Axis2</h2>
+
+<h3>Axis2 Repository</h3>
+
+<p>Axis2 configuration is based on a repository and standard archives
+formats. A repository is a directory in the file system and it should have
+the following:</p>
+<ol>
+  <li><strong>axis2.xml</strong>, the Axis2 global deployment descriptor in
+    conf/axis2.xml file</li>
+  <li><strong>services</strong> directory, which will have service
+  archives</li>
+  <li>optional <strong>modules</strong> directory, which will have module
+    archives</li>
+</ol>
+
+<p>Both services and modules will be identified and deployed once their
+archives are copied to the corresponding directories. At the server side
+users should specify the repository folder at the time of starting a Axis2
+Server (e.g. HTTP or TCP). In Tomcat, <code>webapps/axis2/WEB-INF</code>
+folder acts as the repository. At the client side binary distribution can
+itself be a repository. You can copy the conf directory which includes the
+axis2.xml file from the exploded axis2.war and edit it to change global
+configurations repository.</p>
+
+<h3>Global Configurations</h3>
+
+<p>The Global configuration can be changed by editing the axis2.xml file,
+look at the <a href="axis2config.html#Global_Configuration">Axis2
+Configuration Guide</a> for more information</p>
+
+<h3>Add new Services</h3>
+
+<p>New Services can be written either using WSDL based code generation as we
+did, or from the scratch as explained <a
+href="xmlbased-server.html">here</a>. Read <a
+href="xmlbased-server.html">Creating a Service from Scratch</a> for more
+information. Also refer to <a
+href="axis2config.html#Service_Configuration">Axis2 Configuration Guide</a>
+for a reference on <strong>services.xml</strong> file.</p>
+
+<h3 name="module_engage">Engaging Modules</h3>
+
+<p>Each module(.mar file) provides extensions to Axis2. A module can be
+deployed by copying it in to the modules directory in the repository. Then it
+becomes available and can be engaged at global, service or operation scopes.
+Once engaged it becomes active (add handlers to the execution flow) at the
+respective scope. Please refer to <a href="Axis2ArchitectureGuide.html">Axis2
+architecture guide</a> for detailed explanation. The following table explains the
+semantics of scope and how to engage modules in those scopes.</p>
+
+<table border="1">
+  <tbody>
+    <tr>
+      <th>Scope</th>
+      <th>Semantics</th>
+      <th>how to engage</th>
+    </tr>
+    <tr>
+      <td>Global</td>
+      <td>Add handlers in the module to all the services. Addressing Handler
+        can be only engaged as global</td>
+      <td>By adding a &lt;module ref="addressing"/&gt; to Axis2 xml file or
+        calling
+        <pre>stub._getServiceClient().engageModule(moduleName)</pre>
+        at client side</td>
+    </tr>
+    <tr>
+      <td>Service</td>
+      <td>Add handlers in the module to a specific service</td>
+      <td>By adding a &lt;module ref="addressing"/&gt; to service.xml file in
+        service archive</td>
+    </tr>
+    <tr>
+      <td>Operation</td>
+      <td>Add handlers in the module to a specific operation</td>
+      <td>By adding a &lt;module ref="addressing"/&gt; to inside a operation
+        tag of service.xml file in service archive</td>
+    </tr>
+  </tbody>
+</table>
+
+<p>* If a handler is added to a service or an operation, it will be invoked
+for every request received by that service or operation</p>
+
+<p>Axis2 provides a number of built in Modules such as (<a
+href="">addressing</a>,<a href="">Security</a>, <a href="">WS-Reliable
+Messaging</a> ...), and they can be engaged as shown above. Please refer to
+each module for how to use and configure them. You can also <a
+href="modules.html">create your own modules with Axis2</a>. Also refer to <a
+href="axis2config.html#Global_Configuration">Axis2 Configuration Guide</a>
+for a reference on module.xml file.</p>
+
+<h3>WS-Addressing Support</h3>
+
+<p>WS-Addressing support for Axis2 is implemented by the addressing module.
+To enable addressing you need to engage the addressing module in both server
+and client sides. In order to do this:</p>
+<ol>
+  <li>To <strong>enable</strong> addressing at the server side you need to
+    copy addressing.mar file to modules directory of server's axis2
+    repository. To engage the module, add a &lt;module ref="addressing"/&gt; to
+    axis2.xml. <strong>Addressing module can be engaged only at global
+    level</strong></li>
+  <li>To <strong>enable</strong> addressing at the client side you should add
+    it to the repository and provide the repository as argument to the <a
+    href="dii.html">ServiceClient</a> or <a href="#client">generated stub</a>
+    or have it in your classpath</li>
+  <li>To <strong>engage</strong> addressing module you should either add
+    &lt;module ref="addressing"/&gt; to axis2.xml file at the client side or
+    call
+    <pre>stub._getServiceClient().engageModule(moduleName)</pre>
+  </li>
+</ol>
+
+<a name="advanced"></a>
+<h2>Advanced Topics</h2>
+
+<h3>Transports</h3>
+
+<p>Axis2 is by default configured to use HTTP as the transport. However Axis2
+supports HTTP, SMTP, TCP and JMS transports. You can also write your own
+transports, and deploy them by adding new transportReceiver or
+transportSender tags to axis2.xml. To learn how to configure and use
+different transports please refer the following documents.</p>
+<ol>
+  <li><a href="tcp-transport.html" target="_blank">TCP Transport</a></li>
+  <li><a href="mail-transport.html" target="_blank">Mail Transport</a></li>
+  <li><a href="http-transport.html" target="_blank">HTTP Transports</a></li>
+  <li><a href="jms-transport.html" target="_blank">JMS Transports</a></li>
+</ol>
+
+<h3>Attachments</h3>
+
+<p>Axis2 provides attachment support using <a
+href="http://www.w3.org/TR/soap12-mtom/">MTOM</a>. Please refer to <a
+href="mtom-guide.html" target="_blank">MTOM with Axis2</a> for more
+information.</p>
+
+<h3>Security</h3>
+
+<p>Axis2 provides Security support using the <a
+href="http://ws.apache.org/axis2/modules/rampart/1_0/security-module.html">Apache
+Rampart</a>. Please refer to <a
+href="../modules/wss4j/1_0/security-module.html" target="_blank">Securing
+SOAP Messages with Apache Rampart</a> for more information</p>
+
+<h3>REST Web Service</h3>
+
+<p>Please refer to <a href="rest-ws.html" target="_blank">RESTful Web
+Services</a> for more information</p>
+
+<h3>Pluggable Data Binding</h3>
+
+<p>Axis2 ships with Axis Data Binding(ADB) as the default data binding
+framework, however the data binding frameworks are pluggable to Axis2, and
+you could use other data binding frameworks with Axis2. Please refer the
+following documents for more information.</p>
+
+<h4>Axis2 Data Binding(ADB)</h4>
+<ol>
+  <li><a href="adb/adb-howto.html" target="_blank">Axis2 Databinding
+    Framework</a></li>
+  <li><a href="adb/adb-codegen-integration.html" target="_blank">ADB
+    Integration With Axis2</a></li>
+  <li><a href="adb/adb-advanced.html">Advanced Axis2 Databinding Framework
+    Features</a></li>
+  <li><a href="adb/adb-tweaking.html">ADB Tweaking Guide</a></li>
+</ol>
+
+<h4>JiBX</h4>
+<a href="jibx/jibx-codegen-integration.html">JiBX Integration With Axis2</a>
+
+<h3>Other Topics</h3>
+<ol>
+  <li><a href="spring.html" target="_blank">Axis2 Integration With The Spring
+    Framework</a></li>
+  <li><a href="WS_policy.html" target="_blank">Web Services Policy Support In
+    Axis2</a></li>
+  <li><a href="axis2config.html#Global_Configuration">Axis2 Configuration
+    Guide</a></li>
+  <li><a href="Axis2-rpc-support.html">Axis2 RPC Support</a></li>
+  <li><a href="migration.html">Migrating from Apache Axis 1.x to Axis
+  2</a></li>
+  <li><a href="modules.html">Writing your Own Axis2 Module</a></li>
+  <li><a href="soapmonitor-module.html">Using the SOAP Monitor</a></li>
+  <li><a href="xmlbased-server.html">Writing Web Services Using Axis2's
+    Primary APIs</a></li>
+  <li><a href="dii.html">Writing Web Service Clients Using Axis2's Primary
+    APIs</a></li>
+  <li><a href="app_server.html">Application Server Specific Configuration
+    Guide</a></li>
+</ol>
+</body>
+</html>

Added: webservices/axis2/trunk/java/xdocs/1_1/images/fig01.jpg
URL: http://svn.apache.org/viewvc/webservices/axis2/trunk/java/xdocs/1_1/images/fig01.jpg?view=auto&rev=488606
==============================================================================
Binary file - no diff available.

Propchange: webservices/axis2/trunk/java/xdocs/1_1/images/fig01.jpg
------------------------------------------------------------------------------
    svn:mime-type = application/octet-stream

Added: webservices/axis2/trunk/java/xdocs/1_1/images/fig02.jpg
URL: http://svn.apache.org/viewvc/webservices/axis2/trunk/java/xdocs/1_1/images/fig02.jpg?view=auto&rev=488606
==============================================================================
Binary file - no diff available.

Propchange: webservices/axis2/trunk/java/xdocs/1_1/images/fig02.jpg
------------------------------------------------------------------------------
    svn:mime-type = application/octet-stream

Added: webservices/axis2/trunk/java/xdocs/1_1/images/fig03.jpg
URL: http://svn.apache.org/viewvc/webservices/axis2/trunk/java/xdocs/1_1/images/fig03.jpg?view=auto&rev=488606
==============================================================================
Binary file - no diff available.

Propchange: webservices/axis2/trunk/java/xdocs/1_1/images/fig03.jpg
------------------------------------------------------------------------------
    svn:mime-type = application/octet-stream

Added: webservices/axis2/trunk/java/xdocs/1_1/images/fig04.jpg
URL: http://svn.apache.org/viewvc/webservices/axis2/trunk/java/xdocs/1_1/images/fig04.jpg?view=auto&rev=488606
==============================================================================
Binary file - no diff available.

Propchange: webservices/axis2/trunk/java/xdocs/1_1/images/fig04.jpg
------------------------------------------------------------------------------
    svn:mime-type = application/octet-stream

Added: webservices/axis2/trunk/java/xdocs/1_1/images/fig05.jpg
URL: http://svn.apache.org/viewvc/webservices/axis2/trunk/java/xdocs/1_1/images/fig05.jpg?view=auto&rev=488606
==============================================================================
Binary file - no diff available.

Propchange: webservices/axis2/trunk/java/xdocs/1_1/images/fig05.jpg
------------------------------------------------------------------------------
    svn:mime-type = application/octet-stream

Added: webservices/axis2/trunk/java/xdocs/1_1/images/fig06.jpg
URL: http://svn.apache.org/viewvc/webservices/axis2/trunk/java/xdocs/1_1/images/fig06.jpg?view=auto&rev=488606
==============================================================================
Binary file - no diff available.

Propchange: webservices/axis2/trunk/java/xdocs/1_1/images/fig06.jpg
------------------------------------------------------------------------------
    svn:mime-type = application/octet-stream

Added: webservices/axis2/trunk/java/xdocs/1_1/userguide-buildingservices.html
URL: http://svn.apache.org/viewvc/webservices/axis2/trunk/java/xdocs/1_1/userguide-buildingservices.html?view=auto&rev=488606
==============================================================================
--- webservices/axis2/trunk/java/xdocs/1_1/userguide-buildingservices.html (added)
+++ webservices/axis2/trunk/java/xdocs/1_1/userguide-buildingservices.html Tue Dec 19 01:53:49 2006
@@ -0,0 +1,573 @@
+<?xml version="1.0" encoding=""?>
+<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en">
+<head>
+  <meta http-equiv="content-type" content="" />
+  <title>Introducing Axis2</title>
+</head>
+
+<body>
+<a name="buildservices"></a>
+
+<h1>Apache Axis2 User's Guide</h1>
+
+<h1>-Building Services</h1>
+
+<p>Now that you know how to use Axis2 to generate clients from WSDL, this
+section digs a little deeper, showing you how to create services, and how to
+create both services and clients "from scratch", so to speak.</p>
+<ul>
+  <li><a href="userguide.html#intro">Introducing Axis2</a><br />
+
+    <ul>
+      <li><a href="userguide.html#whatis">What is Axis2</a></li>
+      <li><a href="userguide.html#underhood">What's under the
+      hood?</a></li>
+      <li><a href="userguide.html#handlessoap">How Axis2 handles SOAP
+        messages</a></li>
+      <li><a href="userguide.html#distributions">Axis2
+      distributions</a></li>
+      <li><a href="userguide.html#sbd">The Axis2 Standard Binary
+        Distribution</a></li>
+      <li><a href="userguide.html#hierarchy">Axis2.war Directory
+        hierarchy</a></li>
+      <li><a href="userguide.html#docs">Axis2 Documents
+      Distribution</a></li>
+      <li><a href="userguide.html#clients">Axis2 and clients</a></li>
+    </ul>
+  </li>
+  <li><a href="userguide-installingtesting.html#installingtesting">Installing
+    and testing client code</a></li>
+  <li><a href="userguide-introtoservices.html#introservices">Introduction to
+    Services</a><br />
+
+    <ul>
+      <li><a href="userguide-introtoservices.html#messageexchange">Message
+        Exchange Patterns</a></li>
+    </ul>
+  </li>
+  <li><a href="userguide-creatingclients.html#createclients">Creating
+    Clients</a><br />
+
+    <ul>
+      <li><a href="userguide-creatingclients.html#choosingclient">Choosing a
+        Client Generation Method</a></li>
+      <li><a href="userguide-creatingclients.html#generating">Generating
+        Clients</a></li>
+      <li><a href="userguide-creatingclients.html#adb">Axis Data Binding
+        (ADB)</a></li>
+    </ul>
+  </li>
+  <li><a
+    href="userguide-buildingservices.html#buildservices"><strong>Building
+    Services</strong></a><br />
+
+    <ul>
+      <li><a
+        href="userguide-buildingservices.html#getcomfortable"><strong>Getting
+        Comfortable with Available Options</strong></a></li>
+      <li><a
+        href="userguide-buildingservices.html#createscratch"><strong>Creating
+        a service from scratch</strong></a></li>
+      <li><a
+        href="userguide-buildingservices.html#deploypojo"><strong>Deploying
+        Plain Old Java Objects</strong></a></li>
+      <li><a
+        href="userguide-buildingservices.html#deployrun"><strong>Deploying
+        and running an Axis2 service created from WSDL</strong></a></li>
+    </ul>
+  </li>
+  <li><a href="userguide-samples.html">Samples</a></li>
+  <li><a href="userguide-forfurtherstudy.html">For Further Study</a></li>
+</ul>
+
+<p><a name="getcomfortable"></a></p>
+
+<h2>Getting Comfortable with Available Options</h2>
+
+<p>Axis2 provides a number of ways to create a service, such as:</p>
+<ul>
+  <li>Create a service and build it from scratch: In this case, you build
+    your service class to specifically access AXIOM OMElement objects, then
+    create the services.xml file and package it up for deployment.</li>
+  <li>Deploy Plain Old Java Objects (POJOs) as a service.</li>
+  <li>Generate the service from WSDL: Just as you can generate clients with
+    WSDL, you can generate the skeleton of a service.</li>
+</ul>
+
+<p>Let's look at these three options.</p>
+<a name="createscratch"></a>
+
+<h2>Creating a Service From Scratch</h2>
+
+<p>Creating a service from scratch is not the most convenient way to do it,
+but it does give you the most control. The process involves several steps.</p>
+
+<p><b>The short story:</b></p>
+<ol>
+  <li>Create the service class, with each operation represented by a method
+    that takes as its argument a org.apache.axiom.om.OMElement object. (An
+    OMElement is how the AXIs2 Object Model (AXIOM) represents an XML
+    element.)</li>
+  <li>Create the service descriptor, services.xml, which defines the class to
+    be used by the service and the appropriate message receivers.</li>
+  <li>Create the .aar file, with the classes in their proper locations based
+    on package and the services.xml file in the META-INF directory.</li>
+  <li>Deploy the .aar file by using the <a href="webadminguide.html">Web
+    Administration application</a> or by copying it to the Axis2 services
+    directory.</li>
+</ol>
+
+<p><b>The long story:</b></p>
+
+<p>Start by creating the service class, a plain Java class that uses classes
+from the Axis2 libraries (see Code Listing 8).</p>
+
+<h3>Code Listing 8-Creating the Service Class</h3>
+<pre>package org.apache.axis2.axis2userguide;
+
+import javax.xml.stream.XMLStreamException;
+import org.apache.axiom.om.OMAbstractFactory;
+import org.apache.axiom.om.OMElement;
+import org.apache.axiom.om.OMFactory;
+import org.apache.axiom.om.OMNamespace;
+
+public class SampleService {
+
+    public OMElement sayHello(OMElement element) 
+                             throws XMLStreamException {
+            element.build();
+            element.detach();
+
+            String rootName = element.getLocalName();
+            System.out.println("Reading "+rootName+" element");
+            
+            OMElement childElement = element.getFirstElement();
+            String personToGreet = childElement.getText();
+
+            OMFactory fac = OMAbstractFactory.getOMFactory();
+            OMNamespace omNs = fac.createOMNamespace(
+                    "http://example1.org/example1", "example1");
+            OMElement method = fac.createOMElement("sayHelloResponse", 
+omNs);
+            OMElement value = fac.createOMElement("greeting", omNs);
+            value.addChild(fac.createOMText(value, "Hello, 
+"+personToGreet));
+            method.addChild(value);
+
+            return method;
+        }
+
+     private void ping(){
+     }
+    
+}</pre>
+
+<p>Make sure to include Axis2 libraries in your class path when compiling the
+source.</p>
+
+<p>Axis2 uses AXIOM, or the AXIs Object Model, a DOM (Document Object Model)
+-like structure that is based on the StAX API ( Streaming API for XML).
+Methods that act as services must take as their argument an OMElement, which
+represents the payload of the incoming SOAP message. (An OMElement is just
+AXIOM's way of representing an XML element, like a DOM Element object.) In
+this case, you're extracting the contents of the first child of the payload
+element, adding text to it, and using it as content for the return OMElement.
+Unless this is an "in only" service, these methods must return an OMElement,
+because that becomes the payload of the return SOAP message.</p>
+
+<p>To turn this class into a service, create the service description file,
+services.xml, as in Code Listing 9.</p>
+
+<h3>Code Listing 9 - Create the Service Description</h3>
+<pre>&lt;service name="UserGuideSampleService"&gt;
+    &lt;description&gt;
+        This is a sample service created in the Axis2 User's Guide
+    &lt;/description&gt;
+
+    &lt;parameter name="ServiceClass" 
+locked="false"&gt;org.apache.axis2.axis2userguide.SampleService
+&lt;/parameter&gt;
+
+    &lt;operation name="sayHello"&gt;
+        &lt;messageReceiver 
+class="org.apache.axis2.receivers.RawXMLINOutMessageReceiver"/&gt;
+    &lt;/operation&gt;
+    &lt;operation name="ping"&gt;
+        &lt;messageReceiver 
+class="org.apache.axis2.receivers.RawXMLINOnlyMessageReceiver"/&gt;
+    &lt;/operation&gt;
+&lt;/service&gt;</pre>
+
+<p>This document defines the service, what it's called by the <a
+href="webadminguide.html">Web Administration Application</a>, and the class
+used to serve requests. For each operation, it defines the appropriate
+message receiver class.</p>
+
+<p>Create a new directory, META-INF, in the main directory for the class. (In
+this case, that's the same directory that contains the org directory) and
+place the services.xml file in it.</p>
+
+<p>Create the .aar file by typing: jar cvf SampleService.aar ./*</p>
+
+<p>Now you can create a client class that accesses the service directly (see
+Code Listing 10).</p>
+
+<h3>Code Listing 10 - Create a Client Class that Accesses the Service
+Directly</h3>
+<pre>package org.apache.axis2.axis2userguide;
+
+import javax.xml.stream.XMLStreamException;
+import org.apache.axiom.om.OMAbstractFactory;
+import org.apache.axiom.om.OMElement;
+import org.apache.axiom.om.OMFactory;
+import org.apache.axiom.om.OMNamespace;
+import org.apache.axis2.addressing.EndpointReference;
+import org.apache.axis2.client.Options;
+import org.apache.axis2.Constants;
+import org.apache.axis2.client.ServiceClient;
+
+public class SampleClient {
+
+       private static EndpointReference targetEPR = 
+             new EndpointReference(
+               "http://localhost:8080/axis2/services/SampleService");
+
+        public static OMElement greetUserPayload(String personToGreet) {
+            OMFactory fac = OMAbstractFactory.getOMFactory();
+            OMNamespace omNs = fac.createOMNamespace(
+                    "http://example1.org/example1", "example1");
+            OMElement method = fac.createOMElement("sayHello", omNs);
+            OMElement value = fac.createOMElement("personToGreet", 
+omNs);
+            value.addChild(fac.createOMText(value, personToGreet));
+            method.addChild(value);
+            return method;
+        }
+
+        public static void main(String[] args) {
+            try {
+                OMElement payload = 
+SampleClient.greetUserPayload("John");
+                Options options = new Options();
+                options.setTo(targetEPR);
+                
+options.setTransportInProtocol(Constants.TRANSPORT_HTTP);
+
+                ServiceClient sender = new ServiceClient();
+                sender.setOptions(options);
+                OMElement result = sender.sendReceive(payload);
+
+                String response = result.getFirstElement().getText();
+                System.out.println(response);
+
+            } catch (Exception e) { //(XMLStreamException e) {
+                System.out.println(e.toString());
+            }
+        }
+    
+}</pre>
+
+<p>This class uses the same technique of sending and receiving OMElements,
+but it's also important to note the use of the Options class. This class
+enables you to determine properties such as the transport used for the return
+message -- the transport used for the outgoing message can be inferred from
+the URL of the destination -- and the SOAP version to use. In addition to
+providing setter and getter methods of specific properties that affect how
+the client interacts with the service, the Options class enables you to
+create inheritance relationships between Options objects, so that if a
+property is not found in the current Options object used, the client can
+check the parent Options object of the current Options object.</p>
+<a name="deploypojo"></a>
+
+<h2>Deploying Plain Old Java Objects (POJOs)</h2>
+
+<p>One very easy way to create a Web service is simply to deploy the Java
+objects that represent the service. Start with the class, shown in Code
+Listing 11.</p>
+
+<h3><b>Code Listing 11 - Creating the Class SampleService</b></h3>
+<pre>package org.apache.axis2.axis2userguide;
+
+public class SampleService {
+
+    public void doInOnly(){
+      //Process here
+    } 
+     
+    public String noParameters(){
+      //Process here
+    } 
+    
+    public String twoWayOneParameterEcho(String toEcho){
+      //Process here
+    } 
+    
+    public boolean multipleParametersAdd(float price, int itemId, 
+                             String description, String itemName){
+      //Process here
+    } 
+ 
+}</pre>
+
+<p>Next, you'll need to tell Axis2 what class corresponds to what Web service
+calls. Do this by creating a file called services.xml and adding the
+following shown in Code Listing 12.</p>
+
+<h3><b>Code Listing 12 - Creating services.xml</b></h3>
+<pre>&lt;service name="SampleService" scope="application"&gt;
+    &lt;description&gt;
+        Sample Service
+    &lt;/description&gt;
+    &lt;messageReceivers&gt;
+        &lt;messageReceiver 
+            mep="http://www.w3.org/2004/08/wsdl/in-only"
+    class="org.apache.axis2.rpc.receivers.RPCInOnlyMessageReceiver"/&gt;
+        &lt;messageReceiver
+            mep="http://www.w3.org/2004/08/wsdl/in-out"
+    class="org.apache.axis2.rpc.receivers.RPCMessageReceiver"/&gt;
+    &lt;/messageReceivers&gt;
+    &lt;parameter name="ServiceClass"&gt;
+        org.apache.axis2.axis2userguide.SampleService
+    &lt;/parameter&gt;
+&lt;/service&gt;</pre>
+
+<p>This file makes the InOnly and InOut MEPs available to the service and
+tells Axis2 which class to call; operations must match method names. In other
+words, Axis2 automatically sents a call to the multipleParametersAdd
+operation to the
+org.apache.axis2.axis2userguide.SampleService.multipleParametersAdd()
+method.</p>
+
+<p>Now it's time to create the distribution. Arrange your files in the
+following directory structure (see Code Listing 13).</p>
+
+<h3><b>Code Listing 13- Create the Directory Structure for the
+Distribution</b></h3>
+<pre> - SampleService
+   - META-INF
+     - services.xml
+   - org
+     - apache
+       - axis2
+         - axis2userguide
+           - SampleService.class</pre>
+
+<p>Finally, deploy the service by copying the SampleService directory to the
+webapps/axis2/services directory on the servlet engine. You can check to make
+sure that it's been properly deployed by checking <a
+href="http://&lt;host&gt;:&lt;port&gt;/axis2/services/listServices">http://&lt;host&gt;:&lt;port&gt;/axis2/services/listServices</a>.</p>
+<a name="deployrun"></a>
+
+<h2>Deploying and Running an Axis2 Service Created from WSDL</h2>
+
+<p>If you have a WSDL file, you can easily create and deploy a service based
+on that description. For example, to create a service based on the same WSDL
+file used in the <a href="userguide-creatingclients.html">clients section</a>
+of this document, you'd employ the following steps.</p>
+
+<p><b>The short story:</b></p>
+<ol>
+  <li>If you haven't already, <a
+    href="http://ws.apache.org/axis2/download/1_1/download.cgi#std-bin">download</a>
+    the Axis2 standard distribution.</li>
+  <li>Generate the skeleton using the WSDL2Java utility, as in: <br />
+
+    <pre>java org.apache.axis2.wsdl.WSDL2Java -uri file:///C:/apps/axis2/samples/zSample/Axis2UserGuide.wsdl -p org.apache.axis2.axis2userguide -d adb -s -wv 1.1 -ss -sd -ssi</pre>
+  </li>
+  <li>Open the *Skeleton.java file and add the functionality of your service
+    to the generated methods.</li>
+  <li>Build a service using Ant by typing ant jar.server</li>
+  <li>Deploy the service by copying the build/lib/*.aar file to
+    &lt;J2EE_HOME&gt;/webapps/axis2/WEB-INF/services</li>
+  <li>Check http://&lt;server&gt;:&lt;port&gt;/axis2/services/listServices to
+    make sure the service has been properly deployed</li>
+</ol>
+
+<p><b>The long story:</b></p>
+
+<p>As was the case in generating clients, you will need the <a
+href="http://ws.apache.org/axis2/download/1_1/download.cgi#std-bin">Axis2
+Standard Distribution</a>, because the <a
+href="http://ws.apache.org/axis2/download/1_1/download.cgi#war">Axis2 War
+Distribution</a> does not include the WSDL2Java utility. Once you've got it
+downloaded and unpacked, make sure that you set the AXIS2_HOME variable to
+point to the location in which you've unpacked it.</p>
+
+<p>Now you are ready to generate the actual service. To keep things neat,
+create a new directory and change to it. The WSDL file is the same one
+referenced in <a href="userguide-creatingclients#generating.xhtml">Generating
+Clients</a> and includes four operations: NoParameters,
+TwoWayOneParameterEcho, MultipleParametersAddItem, and DoInOnly. To generate
+the service, use the WSDL2Java utility, as in Code Listing 14.</p>
+
+<h3>Code Listing 14 - Using the WSDL2Java Utility to Generate the Service</h3>
+<pre>java org.apache.axis2.wsdl.WSDL2Java -uri 
+file:///C:/apps/axis2/samples/zSample/Axis2UserGuide.wsdl -p 
+org.apache.axis2.axis2userguide -d adb -s -wv 1.1 -ss -sd</pre>
+
+<p>This statement tells the utility you want to create a service out of the
+operations in the file Axis2UserGuide.wsdl, and that the Java classes
+generated should be in the org.apache.axis2.axis2userguide package (-p). (You
+should see the appropriate directories created.) It also indicates that you
+want to use the Axis2 DataBinding Framework, or ADB (-d), to generate only
+synchronous, or blocking code (-s), and to generate server-side code (-ss) as
+opposed to a client, including the services.xml service descriptor file
+(-sd).</p>
+
+<p>At this point, you should see three new items in your chosen directory:
+the build.xml file, which includes instructions for Ant, the src directory,
+which includes all of the generated classes and stubs, the resources
+directory, which includes a regenerated version of the WSDL, and the
+services.xml file, which ultimately controls the service's behavior.</p>
+
+<p>You can compile the service at this point, but it doesn't actually do
+anything yet. You can solve that problem by opening the
+src\org\apache\axis2\axis2userguide\Axis2UserGuideServiceSkeleton.java file
+and either editing the code in bold -- make sure you manage parameter numbers
+-- or replacing all of the code with the following in Code Listing 15.</p>
+
+<h3>Code Listing 15 - Compiling the Service</h3>
+<pre>/**
+ * Axis2UserGuideServiceSkeleton.java
+ *
+ * This file was auto-generated from WSDL
+ * by the Apache Axis2 version: SNAPSHOT Oct 15, 2006 (11:23:18 
+GMT+00:00)
+ */
+package org.apache.axis2.axis2userguide;
+/**
+ *  Axis2UserGuideServiceSkeleton java skeleton for the axisService
+ */
+public class Axis2UserGuideServiceSkeleton {
+     
+         
+    /**
+     * Auto generated method signature
+         
+     * @param param7
+         
+    */
+    public  org.apache.axis2.axis2userguide.NoParametersResponse 
+NoParameters
+        (org.apache.axis2.axis2userguide.NoParametersRequest param7)
+         
+    {
+        <b>System.out.println(param7);
+
+        NoParametersResponse res =
+            new NoParametersResponse();
+
+        return res;</b>
+    }
+     
+         
+    /**
+     * Auto generated method signature
+         
+     * @param param9
+         
+    */
+    public  
+org.apache.axis2.axis2userguide.TwoWayOneParameterEchoResponse 
+TwoWayOneParameterEcho
+        (
+         org.apache.axis2.axis2userguide.TwoWayOneParameterEchoRequest 
+param9
+         )
+         
+    {
+        <b>System.out.println(param9.getEchoString());
+
+        TwoWayOneParameterEchoResponse res =
+            new TwoWayOneParameterEchoResponse();
+        
+        res.setEchoString(param9.getEchoString());
+
+        return res;</b>
+    }
+     
+         
+    /**
+     * Auto generated method signature
+         
+     * @param param11
+         
+    */
+    public  void DoInOnly
+        (
+         org.apache.axis2.axis2userguide.DoInOnlyRequest param11
+         )
+         
+    {
+        <b>System.out.println(param11.getMessageString());</b>
+    }
+     
+         
+    /**
+     * Auto generated method signature
+         
+     * @param param12
+         
+    */
+    public  
+org.apache.axis2.axis2userguide.MultipleParametersAddItemResponse 
+MultipleParametersAddItem
+        (
+         
+org.apache.axis2.axis2userguide.MultipleParametersAddItemRequest 
+param12
+         )
+         
+    {
+        <b>System.out.println(param12.getPrice());
+        System.out.println(param12.getItemId());
+        System.out.println(param12.getDescription());
+        System.out.println(param12.getItemName());
+
+        MultipleParametersAddItemResponse res =
+            new MultipleParametersAddItemResponse();
+        
+        res.setSuccessfulAdd(true);
+        res.setItemId(param12.getItemId());
+
+        return res;</b>
+    }
+     
+}</pre>
+
+<p>As in the case of generating clients, all of these classes, such as
+MultipleParametersAddItemRequest and TwoWayOneParameterEchoResponse, are
+generated by the utility, and can be found in the same directory as the
+skeleton file. They include methods such as setSuccessfulAdd(), which set the
+value of the content of an element in the response, and getItemName(), which
+retrieve the content of elements in the request.</p>
+
+<p>Save the file and compile it by typing: ant jar.server</p>
+
+<p>If all goes well, you should see the BUILD SUCCESSFUL message in your
+window, and the Axis2UserGuideService.aar file in the newly created build/lib
+directory.</p>
+
+<p><img alt="The BUILD SUCCESSFUL message in your window"
+src="images/fig05.jpg" /></p>
+
+<p>Now you need to deploy the service to the server. To do that, copy the
+Axis2UserGuideService.aar file to the WEB-INF/services directory of the
+application server. (You also have the option to use the administration
+tools. See the <a href="webadminguide.html">Web Administrator's Guide</a> for
+more information.)</p>
+
+<p>To verify that the service has been properly deployed, check the list of
+services at <a
+href="http://&lt;host&gt;:&lt;port&gt;/axis2/services/listServices">http://&lt;host&gt;:&lt;port&gt;/axis2/services/listServices</a>.</p>
+
+<p><img alt="Checking the list of services" src="images/fig06.jpg" /></p>
+
+<p>Now you should be able to access the service using any of the clients
+built in the <a href="userguide-creatingclients.html#generating">Generating
+Clients</a> document.</p>
+
+<p><strong>See Next Section</strong>- <a
+href="userguide-samples.html">Samples</a></p>
+</body>
+</html>

Added: webservices/axis2/trunk/java/xdocs/1_1/userguide-codelisting5.html
URL: http://svn.apache.org/viewvc/webservices/axis2/trunk/java/xdocs/1_1/userguide-codelisting5.html?view=auto&rev=488606
==============================================================================
--- webservices/axis2/trunk/java/xdocs/1_1/userguide-codelisting5.html (added)
+++ webservices/axis2/trunk/java/xdocs/1_1/userguide-codelisting5.html Tue Dec 19 01:53:49 2006
@@ -0,0 +1,198 @@
+<?xml version="1.0" encoding=""?>
+<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en">
+<head>
+  <meta http-equiv="content-type" content="" />
+  <title>Code Listing 4: Generating clients from the WSDL file</title>
+</head>
+
+<body>
+<h1>Code Listing 5 - Generating clients from the WSDL file</h1>
+<pre>&lt;?xml version="1.0" encoding="UTF-8"?&gt;
+&lt;wsdl:definitions
+   xmlns:apachesoap="http://xml.apache.org/xml-soap"
+   xmlns:impl="http://apache.org/axis2/Axis2UserGuide"
+   xmlns:intf="http://apache.org/axis2/Axis2UserGuide"
+   xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/"
+   xmlns:wsdlsoap="http://schemas.xmlsoap.org/wsdl/soap/"
+   xmlns:xsd="http://www.w3.org/2001/XMLSchema"
+   targetNamespace="http://apache.org/axis2/Axis2UserGuide"&gt;
+
+  &lt;wsdl:types&gt;
+    &lt;schema
+       elementFormDefault="qualified"
+       targetNamespace="http://apache.org/axis2/Axis2UserGuide"
+       xmlns="http://www.w3.org/2001/XMLSchema"&gt;
+      
+      &lt;!-- ELEMENTS --&gt;
+      
+      &lt;element name="DoInOnlyRequest"&gt;
+        &lt;complexType&gt;
+          &lt;sequence&gt;
+            &lt;element name="messageString" type="xsd:string"/&gt;
+          &lt;/sequence&gt;
+        &lt;/complexType&gt;
+      &lt;/element&gt;
+      
+      &lt;element name="TwoWayOneParameterEchoRequest"&gt;
+        &lt;complexType&gt;
+          &lt;sequence&gt;
+            &lt;element name="echoString" type="xsd:string"/&gt;
+          &lt;/sequence&gt;
+        &lt;/complexType&gt;
+      &lt;/element&gt;
+      &lt;element name="TwoWayOneParameterEchoResponse"&gt;
+        &lt;complexType&gt;
+          &lt;sequence&gt;
+            &lt;element name="echoString" type="xsd:string"/&gt;
+          &lt;/sequence&gt;
+        &lt;/complexType&gt;
+      &lt;/element&gt;
+      
+      &lt;element name="NoParametersRequest"&gt;
+        &lt;complexType/&gt;
+      &lt;/element&gt;
+      &lt;element name="NoParametersResponse"&gt;
+        &lt;complexType/&gt;
+      &lt;/element&gt;
+      
+      &lt;element name="MultipleParametersAddItemRequest"&gt;
+        &lt;complexType&gt;
+          &lt;sequence&gt;
+            &lt;element name="itemId" type="xsd:int"/&gt;
+            &lt;element name="itemName" type="xsd:string"/&gt;
+            &lt;element name="price" type="xsd:float"/&gt;
+            &lt;element name="description" type="xsd:string"/&gt;
+          &lt;/sequence&gt;
+        &lt;/complexType&gt;
+      &lt;/element&gt;
+
+      &lt;element name="MultipleParametersAddItemResponse"&gt;
+        &lt;complexType&gt;
+          &lt;sequence&gt;
+          &lt;element name="itemId" type="xsd:int"/&gt;
+          &lt;element name="successfulAdd" type="xsd:boolean"/&gt;
+          &lt;/sequence&gt;
+        &lt;/complexType&gt;
+      &lt;/element&gt;
+
+    &lt;/schema&gt;
+  &lt;/wsdl:types&gt;
+
+  
+  &lt;!-- MESSAGES --&gt;
+
+  &lt;wsdl:message name="DoInOnlyRequestMessage"&gt;
+    &lt;wsdl:part name="input" element="impl:DoInOnlyRequest"/&gt;
+  &lt;/wsdl:message&gt;
+
+  &lt;wsdl:message name="TwoWayOneParameterEchoRequestMessage"&gt;
+    &lt;wsdl:part name="input" element="impl:TwoWayOneParameterEchoRequest"/&gt;
+  &lt;/wsdl:message&gt;
+  &lt;wsdl:message name="TwoWayOneParameterEchoResponseMessage"&gt;
+    &lt;wsdl:part name="output" element="impl:TwoWayOneParameterEchoResponse"/&gt;
+  &lt;/wsdl:message&gt;
+
+  &lt;wsdl:message name="NoParametersRequestMessage"&gt;
+    &lt;wsdl:part name="input" element="impl:NoParametersRequest"/&gt;
+  &lt;/wsdl:message&gt;
+  &lt;wsdl:message name="NoParametersResponseMessage"&gt;
+    &lt;wsdl:part name="output" element="impl:NoParametersResponse"/&gt;
+  &lt;/wsdl:message&gt;
+
+  &lt;wsdl:message name="MultipleParametersAddItemRequestMessage"&gt;
+    &lt;wsdl:part name="input" element="impl:MultipleParametersAddItemRequest"/&gt;
+  &lt;/wsdl:message&gt;
+  &lt;wsdl:message name="MultipleParametersAddItemResponseMessage"&gt;
+    &lt;wsdl:part name="output" element="impl:MultipleParametersAddItemResponse"/&gt;
+  &lt;/wsdl:message&gt;
+
+
+  &lt;!-- Port type (operations) --&gt;
+
+  &lt;wsdl:portType name="Axis2UserGuidePortType"&gt;
+
+    &lt;wsdl:operation name="DoInOnly" parameterOrder="input"&gt;
+      &lt;wsdl:input name="DoInOnlyRequestMessage"
+                  message="impl:DoInOnlyRequestMessage"/&gt;
+    &lt;/wsdl:operation&gt;
+
+    &lt;wsdl:operation name="TwoWayOneParameterEcho" parameterOrder="input"&gt;
+      &lt;wsdl:input name="TwoWayOneParameterEchoRequestMessage"
+                  message="impl:TwoWayOneParameterEchoRequestMessage"/&gt;
+      &lt;wsdl:output name="TwoWayOneParameterEchoResponseMessage"
+                  message="impl:TwoWayOneParameterEchoResponseMessage"/&gt;
+    &lt;/wsdl:operation&gt;
+
+    &lt;wsdl:operation name="NoParameters" parameterOrder="input"&gt;
+      &lt;wsdl:input name="NoParametersRequestMessage"
+                  message="impl:NoParametersRequestMessage"/&gt;
+      &lt;wsdl:output name="NoParametersResponseMessage"
+                   message="impl:NoParametersResponseMessage"/&gt;
+    &lt;/wsdl:operation&gt;
+
+    &lt;wsdl:operation name="MultipleParametersAddItem" parameterOrder="input"&gt;
+      &lt;wsdl:input name="MultipleParametersAddItemRequestMessage"
+                  message="impl:MultipleParametersAddItemRequestMessage"/&gt;
+      &lt;wsdl:output name="MultipleParametersAddItemResponseMessage"
+                  message="impl:MultipleParametersAddItemResponseMessage"/&gt;
+    &lt;/wsdl:operation&gt;
+
+  &lt;/wsdl:portType&gt;
+
+
+  &lt;!-- BINDING (bind operations) --&gt;
+  &lt;wsdl:binding
+     name="Axis2UserGuideSoapBinding"
+     type="impl:Axis2UserGuidePortType"&gt;
+    &lt;wsdlsoap:binding style="document" transport="http://schemas.xmlsoap.org/soap/http"/&gt;
+
+    &lt;wsdl:operation name="DoInOnly"&gt;
+      &lt;wsdlsoap:operation soapAction="DoInOnly"/&gt;
+      &lt;wsdl:input&gt;
+        &lt;wsdlsoap:body use="literal"/&gt;
+      &lt;/wsdl:input&gt;
+    &lt;/wsdl:operation&gt;
+
+    &lt;wsdl:operation name="TwoWayOneParameterEcho"&gt;
+      &lt;wsdlsoap:operation soapAction="TwoWayOneParameterEcho"/&gt;
+      &lt;wsdl:input&gt;
+        &lt;wsdlsoap:body use="literal"/&gt;
+      &lt;/wsdl:input&gt;
+      &lt;wsdl:output&gt;
+        &lt;wsdlsoap:body use="literal"/&gt;
+      &lt;/wsdl:output&gt;
+    &lt;/wsdl:operation&gt;
+
+    &lt;wsdl:operation name="NoParameters"&gt;
+      &lt;wsdlsoap:operation soapAction="NoParameters"/&gt;
+      &lt;wsdl:input&gt;
+        &lt;wsdlsoap:body use="literal"/&gt;
+      &lt;/wsdl:input&gt;
+      &lt;wsdl:output&gt;
+        &lt;wsdlsoap:body use="literal"/&gt;
+      &lt;/wsdl:output&gt;
+    &lt;/wsdl:operation&gt;
+
+    &lt;wsdl:operation name="MultipleParametersAddItem"&gt;
+      &lt;wsdlsoap:operation soapAction="MultipleParametersAddItem"/&gt;
+      &lt;wsdl:input&gt;
+        &lt;wsdlsoap:body use="literal"/&gt;
+      &lt;/wsdl:input&gt;
+      &lt;wsdl:output&gt;
+        &lt;wsdlsoap:body use="literal"/&gt;
+      &lt;/wsdl:output&gt;
+    &lt;/wsdl:operation&gt;
+  &lt;/wsdl:binding&gt;
+
+
+  &lt;!-- SERVICE --&gt;
+
+  &lt;wsdl:service name="Axis2UserGuideService"&gt;
+    &lt;wsdl:port binding="impl:Axis2UserGuideSoapBinding"
+               name="Axis2UserGuide"&gt;
+      &lt;wsdlsoap:address location="http://localhost:8080/axis2/services/Axis2UserGuide"/&gt;
+    &lt;/wsdl:port&gt;
+  &lt;/wsdl:service&gt;
+&lt;/wsdl:definitions&gt;</pre>
+</body>
+</html>



---------------------------------------------------------------------
To unsubscribe, e-mail: axis-cvs-unsubscribe@ws.apache.org
For additional commands, e-mail: axis-cvs-help@ws.apache.org


Mime
View raw message