Developing Applications Using JAX-WS

Table of Contents

I. Starting from Java Code
1. Bottom-Up Service Development
Creating the SEI
Annotating the Code
Required Annotations
Optional Annotations
Defining the Binding Properties with Annotations
Defining Operation Properties with Annotations
Defining Parameter Properties with Annotations
Generating WSDL
2. Developing a Consumer Without a WSDL Contract
Creating a Service Object
Adding a Port to a Service
Getting a Proxy for an Endpoint
Implementing the Consumer's Business Logic
II. Starting from WSDL
3. A Starting Point WSDL Contract
4. Top-Down Service Development
Generating the Starting Point Code
Implementing the Service Provider
5. Developing a Consumer From a WSDL Contract
Generating the Stub Code
Implementing a Consumer
III. Common Development Tasks
6. Finding WSDL at Runtime
Instantiating a Proxy by Injection
Using a JAX-WS Catalog
Using a ServiceContractResolver Object
7. Generic Fault Handling
Runtime Faults
Protocol Faults
8. Creating Custom Exceptions
9. Publishing a Service
APIs Used to Publish a Service
Publishing a Service in a Plain Java Application
Publishing a Service in an OSGi Container
IV. Working with Data Types
10. Basic Data Binding Concepts
Including and Importing Schema Definitions
XML Namespace Mapping
The Object Factory
Adding Classes to the Runtime Marshaller
11. Using XML Elements
12. Using Simple Types
Primitive Types
Simple Types Defined by Restriction
Simple Type Substitution
13. Using Complex Types
Basic Complex Type Mapping
Deriving Complex Types from Simple Types
Deriving Complex Types from Complex Types
Occurrence Constraints
Occurrence Constraints on the All Element
Occurrence Constraints on the Choice Element
Occurrence Constraints on Elements
Occurrence Constraints on Sequences
Using Model Groups
14. Using Wild Card Types
Using Any Elements
Using the XML Schema anyType Type
Using Unbound Attributes
15. Element Substitution
Substitution Groups in XML Schema
Substitution Groups in Java
Widget Vendor Example
The checkWidgets Operation
The placeWidgetOrder Operation
16. Customizing How Types are Generated
Basics of Customizing Type Mappings
Specifying the Java Class of an XML Schema Primitive
Generating Java Classes for Simple Types
Customizing Enumeration Mapping
Customizing Fixed Value Attribute Mapping
Specifying the Base Type of an Element or an Attribute
17. Using A JAXBContext Object
V. Advanced Programming Tasks
18. Developing Asynchronous Applications
WSDL for Asynchronous Examples
Generating the Stub Code
Implementing an Asynchronous Client with the Polling Approach
Implementing an Asynchronous Client with the Callback Approach
Catching Exceptions Returned from a Remote Service
19. Using Raw XML Messages
Using XML in a Consumer
Usage Modes
Data Types
Working with Dispatch Objects
Using XML in a Service Provider
Messaging Modes
Data Types
Implementing a Provider Object
20. Working with Contexts
Understanding Contexts
Working with Contexts in a Service Implementation
Working with Contexts in a Consumer Implementation
Working with JMS Message Properties
Inspecting JMS Message Headers
Inspecting the Message Header Properties
Setting JMS Properties
21. Writing Handlers
Handlers: An Introduction
Implementing a Logical Handler
Handling Messages in a Logical Handler
Implementing a Protocol Handler
Handling Messages in a SOAP Handler
Initializing a Handler
Handling Fault Messages
Closing a Handler
Releasing a Handler
Configuring Endpoints to Use Handlers
Programmatic Configuration
Adding a Handler Chain to a Consumer
Adding a Handler Chain to a Service Provider
Spring Configuration
List of Figures
List of Tables
List of Examples