Project Aristotle - ArisID Attribute Services

org.openliberty.arisid.policy
Interface IPolicy

All Superinterfaces:
IPolicyComponent

public interface IPolicy
extends IPolicyComponent

A implementation neutral WS-Policy object containing a set of constraints. An IPolicy may represent either WS-Policy or WS-PolicyReference entities.

Developers should use PolicyHandler to manage and evaluate contents of a Policy. This ensures that developer code is implementation neutral and can be supported on Apache Neethi, Oracle WS-Policy, or other implementations.


Field Summary
static java.lang.String POLICY_ELEMENT
           
static java.lang.String POLREF_ELEMENT
           
static java.lang.String URI_ATTR
           
 
Method Summary
 void addAssertion(IAssertion assertion)
          Adds an assertion (e.g.
 void appendChildren(org.w3c.dom.Node parent)
          Appends all document children nodes for the object to the parent specified.
 void dispose()
          Called when use of this object is finished.
 java.lang.String getName()
          Returns the name identifier of the policy.
 java.lang.Object getPolicy()
          Deprecated. Use of this method will render code bound to a specific implementation of WS-Policy and may impact deployability. Recommended only for internal use and policy provider implementations.
 boolean isReferencePolicy()
          Used to indicate whether this policy is actually a reference to an externally defined policy.
 void setName(java.lang.String name)
          Set the name identifier for a policy.
 java.lang.String toString()
           
 
Methods inherited from interface org.openliberty.arisid.policy.IPolicyComponent
equal, getType, serialize
 

Field Detail

POLICY_ELEMENT

static final java.lang.String POLICY_ELEMENT
See Also:
Constant Field Values

POLREF_ELEMENT

static final java.lang.String POLREF_ELEMENT
See Also:
Constant Field Values

URI_ATTR

static final java.lang.String URI_ATTR
See Also:
Constant Field Values
Method Detail

getName

java.lang.String getName()
Returns the name identifier of the policy.

Returns:
The name of the policy or null.

getPolicy

java.lang.Object getPolicy()
Deprecated. Use of this method will render code bound to a specific implementation of WS-Policy and may impact deployability. Recommended only for internal use and policy provider implementations.

Returns the actual policy object policy whether referenced or directly held. This method should not normally be used by application developers, instead, developers should be using PolicyUtil to access, manipulate, and test policy assertions.

Returns:
A the actual native provider library implementation of WS-Policy

toString

java.lang.String toString()
Overrides:
toString in class java.lang.Object
Returns:
A string representation of policy. Typically used for diagnostic and display purposes only.

appendChildren

void appendChildren(org.w3c.dom.Node parent)
Appends all document children nodes for the object to the parent specified. Used for serializing policy objects to DOM.

Parameters:
parent - A document node parent to add the current object to.

addAssertion

void addAssertion(IAssertion assertion)
Adds an assertion (e.g. PrivacyConstraint) to the existing policy

Parameters:
assertion - IAssertion object to be added to the policy

setName

void setName(java.lang.String name)
Set the name identifier for a policy.

Parameters:
name - String name of the policy.

isReferencePolicy

boolean isReferencePolicy()
Used to indicate whether this policy is actually a reference to an externally defined policy.

Returns:
true if a WS-Policy reference object

dispose

void dispose()
Called when use of this object is finished. Used to enhance GC.


OpenLiberty.org - Licensed under Apache APL 2.0