WSDL2Ws


Contents

1. Functionality

The tool should be able to generate different types of Wrappers and Skelentons for the server side and client’s stubs for the client’s Side.WSDL2Ws tool in AxisC++ is written in Java.

      1.1 Types Of Classes

The Tool Should starts with a WSDL document and generate following classes.

·       WSDL2WS tool is used for building following C/C++ components

                   o Server side – Skeletons and Wrappers

                   o Client side – Stubs

                        ·       WSDL2WS tool that generates wrappers which used to deploy the Service in the AxisC++ engine. (Please refer the Wrapper Specification for more information)

The generated Wrappers perform the following functions. These wrappers act as RPC Providers.

o Serialization

o Deserialization

o Method invocation

       1.2 Programming Languages

The tool should able to generate classes for

       • C++

       • C

The tool should be extensible to support other programming languages if required.

       1.3 encoding style

The tool should be support SOAP1.2 encoding style and extensible to support other encoding styles as well.

      1.4 Style Of the Service

The tool should able to generate classes for following styles

• RPC

• Document

• Messaging

       1.5 Supports for making simple custom types

Tool generate Wrapper for custom types in following conditions

• Generate the method signatures of the types (serialize(), desirealize()) so that developer    can write serialize desirialize code in most efficient way.

• Generate the complete wrapper for WSDL types like struts

• Genarate the complete wrappers for Array of any simple or WSDL types like struts

2.Architecture

      2.1 Outline

The tool takes a top down approach. It starts with a wsdl document and generates all the classes necessary to deploy the web service. It generates

• Skeleton (wrapper class)

• Wrapper classes for complex types

• Server side and client Side stubs
The tool can be extensible to generate Service classes to be published For more information about the generated classes please refer to the architecture documentation.

  2.1 Mediator WsContext

The WSDL file and the user options are processed by the WSDLWs. The WSDL create a class called wsContext(WebServiceContext) which is the runtime representation of the processed data. This wsContext passes to the generators. The generators extract the information form the wsContext create the files.The wsContext act as a mediator and create a loosely coupled system.

wsContext has following componets

1. ServiceInfo – information about service

2. WrapperInfo – information about wrapper options

3. TypeMap – information about custom types

   2.2 Genarator

Generator generate a class depend on the options, It contains a class called SourceWriter and the concrete implementation of the SourceWriter decides what will Genarator generate. The SourceWriter factory create a correct type of generator depend on the options.

   2.4 flow of execution

1.WSDL file and user options are processed by the WSDL2Ws and WSContext object is created.

2. WebServiceGenaratorFactory will create WebServiceGenarator depend on the service style

3. Then the WebServiceGenarator will create right set of Generators to create the set of files

4.Each generator will invoke SourceWriter capable of writing each type of file. Rest of the logic is developer to decide (He have all needed info as WsContext).

   2.5 Sequence Diagram