|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectorg.wso2.balana.AbstractObligation
org.wso2.balana.xacml2.Obligation
public class Obligation
Represents ObligationType in the XACML 2.0 policy schema. In XACML 2.0, this element represent both
in policy and result. Therefore this has extends the AbstractObligation
and implements
the ObligationResult
Field Summary |
---|
Fields inherited from class org.wso2.balana.AbstractObligation |
---|
fulfillOn, obligationId |
Constructor Summary | |
---|---|
Obligation(URI obligationId,
int fulfillOn,
List<Attribute> assignments)
Constructor that takes all the data associated with an obligation. |
Method Summary | |
---|---|
String |
encode()
Encodes this Obligation into its XML form |
void |
encode(StringBuilder builder)
Encodes this Obligation into its XML form and writes this out to the provided
StringBuilder |
ObligationResult |
evaluate(EvaluationCtx ctx)
Evaluates obligation and creates the results |
List<Attribute> |
getAssignments()
Returns the attribute assignment data in this obligation. |
static Obligation |
getInstance(Node root)
Creates an instance of Obligation based on the DOM root node. |
Methods inherited from class org.wso2.balana.AbstractObligation |
---|
getFulfillOn, getId |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
---|
public Obligation(URI obligationId, int fulfillOn, List<Attribute> assignments)
Attribute
objects, but only the fields used by the
AttributeAssignmentType are used.
obligationId
- the obligation's idfulfillOn
- the effect denoting when to fulfill this obligationassignments
- a List
of Attribute
sMethod Detail |
---|
public static Obligation getInstance(Node root) throws ParsingException
Obligation
based on the DOM root node.
root
- the DOM root of the ObligationType XML type
ParsingException
- if the structure isn't validpublic ObligationResult evaluate(EvaluationCtx ctx)
AbstractObligation
evaluate
in class AbstractObligation
ctx
- EvaluationCtx
ObligationResult
public List<Attribute> getAssignments()
List
contains
objects of type Attribute
with only the correct attribute fields being used.
public String encode()
Obligation
into its XML form
encode
in interface ObligationResult
String
public void encode(StringBuilder builder)
Obligation
into its XML form and writes this out to the provided
StringBuilder
- Specified by:
encode
in interface ObligationResult
- Specified by:
encode
in class AbstractObligation
- Parameters:
builder
- string stream into which the XML-encoded data is written
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |