Spring Web Services Framework

org.springframework.ws.support
Class MarshallingUtils

java.lang.Object
  extended by org.springframework.ws.support.MarshallingUtils

public abstract class MarshallingUtils
extends Object

Helper class for endpoints and endpoint mappings that use marshalling.

Since:
1.0.0
Author:
Arjen Poutsma

Method Summary
static void marshal(Marshaller marshaller, Object graph, WebServiceMessage message)
          Marshals the given object to the payload of the given message using the provided Marshaller.
static Object unmarshal(Unmarshaller unmarshaller, WebServiceMessage message)
          Unmarshals the payload of the given message using the provided Unmarshaller.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Method Detail

unmarshal

public static Object unmarshal(Unmarshaller unmarshaller,
                               WebServiceMessage message)
                        throws IOException
Unmarshals the payload of the given message using the provided Unmarshaller.

If the request message has no payload (i.e. WebServiceMessage.getPayloadSource() returns null), this method will return null.

Parameters:
unmarshaller - the unmarshaller
message - the message of which the payload is to be unmarshalled
Returns:
the unmarshalled object
Throws:
IOException - in case of I/O errors

marshal

public static void marshal(Marshaller marshaller,
                           Object graph,
                           WebServiceMessage message)
                    throws IOException
Marshals the given object to the payload of the given message using the provided Marshaller.

Parameters:
marshaller - the marshaller
graph - the root of the object graph to marshal
message - the message of which the payload is to be unmarshalled
Throws:
IOException - in case of I/O errors

Spring Web Services Framework

Copyright © 2005-2010 The Spring Web Services Framework. All Rights Reserved.