Class DynamicApplicationContext

java.lang.Object
com.sun.xml.wss.impl.policy.DynamicPolicyContext
com.sun.xml.wss.impl.configuration.DynamicApplicationContext

public class DynamicApplicationContext extends DynamicPolicyContext
Represents a concrete SecurityPolicy identifier context resolved at runtime, An XWS-Security DynamicPolicyCallback is passed an instance of a DynamicApplicationContext. A callback Handler handling DynamicPolicyCallback can make use of information in this context to dynamically determine the Security policy applicable for a request/response
  • Constructor Details

    • DynamicApplicationContext

      public DynamicApplicationContext()
      Create an empty DynamicApplicationContext
    • DynamicApplicationContext

      public DynamicApplicationContext(StaticPolicyContext context)
      Create a DynamicApplicationContext with an associated StaticPolicyContext context
      Parameters:
      context - the associated StaticPolicyContext
  • Method Details

    • setMessageIdentifier

      public void setMessageIdentifier(String messageIdentifier)
      Set the messageIdentifier for this Message associated with this context
      Parameters:
      messageIdentifier -
    • getMessageIdentifier

      public String getMessageIdentifier()
      Returns:
      messageIdentifier for the Message associated with this context
    • inBoundMessage

      public void inBoundMessage(boolean inBound)
      Set the Message direction (inbound/outbound) to which this context corresponds to
      Parameters:
      inBound - flag indicating the direction of the message
    • inBoundMessage

      public boolean inBoundMessage()
      Returns:
      true if the context is for an inbound message
    • setStaticPolicyContext

      public void setStaticPolicyContext(StaticPolicyContext context)
      set the associated StaticPolicyContext for this context
      Parameters:
      context - StaticPolicyContext
    • getStaticPolicyContext

      public StaticPolicyContext getStaticPolicyContext()
      Specified by:
      getStaticPolicyContext in class DynamicPolicyContext
      Returns:
      the associated StaticPolicContext if any, null otherwise
    • getRuntimeProperties

      public HashMap getRuntimeProperties()
      Returns:
      HashMap of runtime properties in this context
    • equals

      public boolean equals(DynamicApplicationContext ctx)
      equals operator
      Parameters:
      ctx - DynamicApplicationContext with which to compare for equality
      Returns:
      true if ctx is equal to this DynamicApplicationContext