Class MarshallingMethodEndpointAdapter

All Implemented Interfaces:
org.springframework.beans.factory.InitializingBean, EndpointAdapter
Direct Known Subclasses:
GenericMarshallingMethodEndpointAdapter

@Deprecated public class MarshallingMethodEndpointAdapter extends AbstractMethodEndpointAdapter implements org.springframework.beans.factory.InitializingBean
Deprecated.
as of Spring Web Services 2.0, in favor of DefaultMethodEndpointAdapter and MarshallingPayloadMethodProcessor.
Adapter that supports endpoint methods that use marshalling. Supports methods with the following signature:
 void handleMyMessage(MyUnmarshalledType request);
 
or
 MyMarshalledType handleMyMessage(MyUnmarshalledType request);
 
I.e. methods that take a single parameter that is supported by the Unmarshaller, and return either void or a type supported by the Marshaller. The method can have any name, as long as it is mapped by an EndpointMapping.

This endpoint needs a Marshaller and Unmarshaller, both of which can be set using properties.

Since:
1.0.0
Author:
Arjen Poutsma
See Also:
  • Constructor Details

    • MarshallingMethodEndpointAdapter

      public MarshallingMethodEndpointAdapter()
      Deprecated.
      Creates a new MarshallingMethodEndpointAdapter. The Marshaller and Unmarshaller must be injected using properties.
      See Also:
    • MarshallingMethodEndpointAdapter

      public MarshallingMethodEndpointAdapter(org.springframework.oxm.Marshaller marshaller)
      Deprecated.
      Creates a new MarshallingMethodEndpointAdapter with the given marshaller. If the given Marshaller also implements the Unmarshaller interface, it is used for both marshalling and unmarshalling. Otherwise, an exception is thrown.

      Note that all Marshaller implementations in Spring also implement the Unmarshaller interface, so that you can safely use this constructor.

      Parameters:
      marshaller - object used as marshaller and unmarshaller
      Throws:
      IllegalArgumentException - when marshaller does not implement the Unmarshaller interface
    • MarshallingMethodEndpointAdapter

      public MarshallingMethodEndpointAdapter(org.springframework.oxm.Marshaller marshaller, org.springframework.oxm.Unmarshaller unmarshaller)
      Deprecated.
      Creates a new MarshallingMethodEndpointAdapter with the given marshaller and unmarshaller.
      Parameters:
      marshaller - the marshaller to use
      unmarshaller - the unmarshaller to use
  • Method Details

    • getMarshaller

      public org.springframework.oxm.Marshaller getMarshaller()
      Deprecated.
      Returns the marshaller used for transforming objects into XML.
    • setMarshaller

      public final void setMarshaller(org.springframework.oxm.Marshaller marshaller)
      Deprecated.
      Sets the marshaller used for transforming objects into XML.
    • getUnmarshaller

      public org.springframework.oxm.Unmarshaller getUnmarshaller()
      Deprecated.
      Returns the unmarshaller used for transforming XML into objects.
    • setUnmarshaller

      public final void setUnmarshaller(org.springframework.oxm.Unmarshaller unmarshaller)
      Deprecated.
      Sets the unmarshaller used for transforming XML into objects.
    • afterPropertiesSet

      public void afterPropertiesSet() throws Exception
      Deprecated.
      Specified by:
      afterPropertiesSet in interface org.springframework.beans.factory.InitializingBean
      Throws:
      Exception
    • invokeInternal

      protected void invokeInternal(MessageContext messageContext, MethodEndpoint methodEndpoint) throws Exception
      Deprecated.
      Description copied from class: AbstractMethodEndpointAdapter
      Use the given method endpoint to handle the request.
      Specified by:
      invokeInternal in class AbstractMethodEndpointAdapter
      Parameters:
      messageContext - the current message context
      methodEndpoint - the method endpoint to use
      Throws:
      Exception - in case of errors
    • supportsInternal

      protected boolean supportsInternal(MethodEndpoint methodEndpoint)
      Deprecated.
      Supports a method with a single, unmarshallable parameter, and that return void or a marshallable type.
      Specified by:
      supportsInternal in class AbstractMethodEndpointAdapter
      Parameters:
      methodEndpoint - method endpoint to check
      Returns:
      whether or not this adapter can adapt the given method
      See Also:
      • Marshaller.supports(Class)
      • Unmarshaller.supports(Class)