com.sun.xml.ws.server.sei
Class EndpointArgumentsBuilder

java.lang.Object
  extended by com.sun.xml.ws.server.sei.EndpointArgumentsBuilder
Direct Known Subclasses:
EndpointArgumentsBuilder.AttachmentBuilder, EndpointArgumentsBuilder.Body, EndpointArgumentsBuilder.Composite, EndpointArgumentsBuilder.DocLit, EndpointArgumentsBuilder.Header, EndpointArgumentsBuilder.None, EndpointArgumentsBuilder.NullSetter, EndpointArgumentsBuilder.RpcLit

abstract class EndpointArgumentsBuilder
extends Object

Reads a request Message, disassembles it, and moves obtained Java values to the expected places.


Nested Class Summary
(package private) static class EndpointArgumentsBuilder.AttachmentBuilder
          Reads an Attachment into a Java parameter.
(package private) static class EndpointArgumentsBuilder.Body
          Reads the whole payload into a single JAXB bean.
(package private) static class EndpointArgumentsBuilder.Composite
          EndpointArgumentsBuilder that is a composition of multiple EndpointArgumentsBuilders.
(package private) static class EndpointArgumentsBuilder.DocLit
          Treats a payload as multiple parts wrapped into one element, and processes all such wrapped parts.
(package private) static class EndpointArgumentsBuilder.Header
          Reads a header into a JAXB object.
(package private) static class EndpointArgumentsBuilder.None
           
(package private) static class EndpointArgumentsBuilder.NullSetter
          EndpointArgumentsBuilder that sets the VM uninitialized value to the type.
(package private) static class EndpointArgumentsBuilder.RpcLit
          Treats a payload as multiple parts wrapped into one element, and processes all such wrapped parts.
 
Field Summary
static EndpointArgumentsBuilder NONE
          The singleton instance that produces null return value.
 
Constructor Summary
EndpointArgumentsBuilder()
           
 
Method Summary
static Object getVMUninitializedValue(Type type)
          Returns the 'uninitialized' value for the given type.
static String getWSDLPartName(Attachment att)
          Gets the WSDL part name of this attachment.
(package private) abstract  void readRequest(Message request, Object[] args)
          Reads a request Message, disassembles it, and moves obtained Java values to the expected places.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

NONE

public static EndpointArgumentsBuilder NONE
The singleton instance that produces null return value. Used for operations that doesn't have any output.

Constructor Detail

EndpointArgumentsBuilder

EndpointArgumentsBuilder()
Method Detail

readRequest

abstract void readRequest(Message request,
                          Object[] args)
                   throws JAXBException,
                          javax.xml.stream.XMLStreamException
Reads a request Message, disassembles it, and moves obtained Java values to the expected places.

Parameters:
request - The request Message to be de-composed.
args - The Java arguments given to the SEI method invocation. Some parts of the reply message may be set to Holders in the arguments.
Throws:
JAXBException - if there's an error during unmarshalling the request message.
javax.xml.stream.XMLStreamException - if there's an error during unmarshalling the request message.

getVMUninitializedValue

public static Object getVMUninitializedValue(Type type)
Returns the 'uninitialized' value for the given type.

For primitive types, it's '0', and for reference types, it's null.


getWSDLPartName

public static final String getWSDLPartName(Attachment att)
Gets the WSDL part name of this attachment.

According to WSI AP 1.0

 3.8 Value-space of Content-Id Header
   Definition: content-id part encoding
   The "content-id part encoding" consists of the concatenation of:
 The value of the name attribute of the wsdl:part element referenced by the mime:content, in which characters disallowed in content-id headers (non-ASCII characters as represented by code points above 0x7F) are escaped as follows:
     o Each disallowed character is converted to UTF-8 as one or more bytes.
     o Any bytes corresponding to a disallowed character are escaped with the URI escaping mechanism (that is, converted to %HH, where HH is the hexadecimal notation of the byte value).
     o The original character is replaced by the resulting character sequence.
 The character '=' (0x3D).
 A globally unique value such as a UUID.
 The character '@' (0x40).
 A valid domain name under the authority of the entity constructing the message.
 
So a wsdl:part fooPart will be encoded as:

Returns:
null if the parsing fails.