public class PolicySourceModel extends Object implements Cloneable
ModelNode
instances associated with the actual model instance.Modifier | Constructor and Description |
---|---|
protected |
PolicySourceModel(NamespaceVersion nsVersion,
String policyId,
String policyName,
Collection<PrefixMapper> prefixMappers)
Constructor that creates a new policy source model instance with given
id or name identifier and a set of PrefixMappers.
|
Modifier and Type | Method and Description |
---|---|
protected PolicySourceModel |
clone() |
boolean |
containsPolicyReferences()
Returns a boolean value indicating whether this policy source model contains references to another policy source models.
|
static PolicySourceModel |
createPolicySourceModel(NamespaceVersion nsVersion)
Factory method that creates new policy source model instance.
|
static PolicySourceModel |
createPolicySourceModel(NamespaceVersion nsVersion,
String policyId,
String policyName)
Factory method that creates new policy source model instance and initializes it according to parameters provided.
|
boolean |
equals(Object obj)
An
Object.equals(Object obj) method override. |
void |
expand(PolicySourceModelContext context)
Expands current policy model.
|
NamespaceVersion |
getNamespaceVersion()
Returns an original namespace version of this policy source model.
|
String |
getPolicyId()
Returns a policy ID of this policy source model.
|
String |
getPolicyName()
Returns a policy name of this policy source model.
|
ModelNode |
getRootNode()
Returns a root node of this policy source model.
|
int |
hashCode()
An
Object.hashCode() method override. |
String |
toString()
Returns a string representation of the object.
|
protected PolicySourceModel(NamespaceVersion nsVersion, String policyId, String policyName, Collection<PrefixMapper> prefixMappers)
nsVersion
- The WS-Policy version.policyId
- Relative policy reference within an XML document. May be null
.policyName
- Absolute IRI of policy expression. May be null
.prefixMappers
- A collection of PrefixMappers to be used with this instance. May be null
.public static PolicySourceModel createPolicySourceModel(NamespaceVersion nsVersion)
nsVersion
- The policy versionpublic static PolicySourceModel createPolicySourceModel(NamespaceVersion nsVersion, String policyId, String policyName)
nsVersion
- The policy versionpolicyId
- local policy identifier - relative URI. May be null
.policyName
- global policy identifier - absolute policy expression URI. May be null
.public ModelNode getRootNode()
public String getPolicyName()
public String getPolicyId()
public NamespaceVersion getNamespaceVersion()
public boolean equals(Object obj)
Object.equals(Object obj)
method override.
When child nodes are tested for equality, the parent policy source model is not considered. Thus two different
policy source models instances may be equal based on their node content.public int hashCode()
Object.hashCode()
method override.public String toString()
toString
method
returns a string that "textually represents" this object.protected PolicySourceModel clone() throws CloneNotSupportedException
clone
in class Object
CloneNotSupportedException
public boolean containsPolicyReferences()
expand(PolicySourceModelContext)
and isExpanded()
for more details.true
or {code false} depending on whether this policy source model contains references to another policy source models.public void expand(PolicySourceModelContext context) throws PolicyException
isExpanded()
and containsPolicyReferences()
for more details.context
- a policy source model context holding the set of unmarshalled policy source models within the same context.PolicyException
- Thrown if a referenced policy could not be resolvedCopyright © 2006-2013 Oracle Corporation. All Rights Reserved.