Apache CXF API

org.apache.cxf.ws.rm
Class RMContextUtils

java.lang.Object
  extended by org.apache.cxf.ws.rm.RMContextUtils

public final class RMContextUtils
extends Object

Holder for utility methods relating to contexts.


Constructor Summary
protected RMContextUtils()
          Prevents instantiation.
 
Method Summary
static void ensureExposedVersion(AddressingProperties maps)
          Ensures the appropriate version of WS-Addressing is used.
static String generateUUID()
           
static String getRMPropertiesKey(boolean outbound)
           
static boolean isRMProtocolMessage(String action)
          Checks if the action String belongs to an RM protocol message.
static boolean isServerSide(Message message)
          Determine if message is currently being processed on server side.
static AddressingPropertiesImpl retrieveMAPs(Message message, boolean isProviderContext, boolean isOutbound)
          Retrieves the addressing properties from the current message.
static RMProperties retrieveRMProperties(Message message, boolean outbound)
          Retrieve the RM properties from the current message.
static void storeMAPs(AddressingProperties maps, Message message, boolean isOutbound, boolean isRequestor)
          Store MAPs in the message.
static void storeRMProperties(Message message, RMProperties rmps, boolean outbound)
          Store the RM properties in the current message.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

RMContextUtils

protected RMContextUtils()
Prevents instantiation.

Method Detail

generateUUID

public static String generateUUID()
Returns:
a generated UUID

isServerSide

public static boolean isServerSide(Message message)
Determine if message is currently being processed on server side.

Parameters:
message - the current Message
Returns:
true iff message is currently being processed on server side

isRMProtocolMessage

public static boolean isRMProtocolMessage(String action)
Checks if the action String belongs to an RM protocol message.

Parameters:
action - the action
Returns:
true iff the action is not one of the RM protocol actions.

retrieveRMProperties

public static RMProperties retrieveRMProperties(Message message,
                                                boolean outbound)
Retrieve the RM properties from the current message.

Parameters:
message - the current message
outbound - true iff the message direction is outbound
Returns:
the RM properties

storeRMProperties

public static void storeRMProperties(Message message,
                                     RMProperties rmps,
                                     boolean outbound)
Store the RM properties in the current message.

Parameters:
message - the current message
rmps - the RM properties
outbound - iff the message direction is outbound

retrieveMAPs

public static AddressingPropertiesImpl retrieveMAPs(Message message,
                                                    boolean isProviderContext,
                                                    boolean isOutbound)
Retrieves the addressing properties from the current message.

Parameters:
message - the current message
isProviderContext - true if the binding provider request context available to the client application as opposed to the message context visible to handlers
isOutbound - true iff the message is outbound
Returns:
the current addressing properties

storeMAPs

public static void storeMAPs(AddressingProperties maps,
                             Message message,
                             boolean isOutbound,
                             boolean isRequestor)
Store MAPs in the message.

Parameters:
maps - the MAPs to store
message - the current message
isOutbound - true iff the message is outbound
isRequestor - true iff the current messaging role is that of requestor
handler - true if HANDLER scope, APPLICATION scope otherwise

ensureExposedVersion

public static void ensureExposedVersion(AddressingProperties maps)
Ensures the appropriate version of WS-Addressing is used.

Parameters:
maps - the addressing properties

getRMPropertiesKey

public static String getRMPropertiesKey(boolean outbound)

Apache CXF API

Apache CXF