SOAP processing in JSP targets

Datatype support

JSP targets in PowerBuilder use the Apache Software Foundation’s Axis software for Simple Object Access Protocol (SOAP) processing. The Axis software includes support for user-defined complex datatypes and document-type WSDL files.

Axis provides a WSDL2 Java tool that builds Java proxies and skeletons for Web services with WSDL descriptions. Axis follows the Java API for the XML-Based Remote Procedure Calls (JAX-RPC) specification when generating Java client bindings from the WSDL descriptions and generates only those bindings necessary for the client. Table 8-9 shows the type of Java file generated from each entry type in the WSDL file.

Table 8-9: Java client bindings generated from WSDL file

For each WSDL

Java class generated

Type in the types section

JavaBean

complexType

Holder if this type is used as an in/out parameter

portType

Java interface

binding

Stub class

service

Service interface and service implementation (the locator)

In a JSP target, the authoring tool (HTML editor) is Unicode enabled so you can input text in multiple languages on a single page. It accepts UTF-16 Unicode text only, however JSP files with ANSI-encoded or UTF-8 text can still be imported in the editor. Text with these encodings is automatically converted to UTF-16.

Custom tag support in JSP targets

Custom tags to be used in a JSP target are processed at design time. The code to process a custom tag invoking a Web service is generated in Java and compiled using the Java compiler in the JDK. The generated code uses the Java client binding class generated by the Axis toolkit.

The main purpose of the generated code is to provide the glue needed to call and pass arguments from a custom tag in a JSP to the Axis toolkit. The custom tag provides the ability to access both input and output arguments through attributes (for input variables) and scripting variables (for output variables). In addition, the ability to access the return value is provided by a scripting variable.

For a custom tag to function properly, three components must be created: