nbi.xmlsec.xacml.profile.rbac
Class PermissionPolicySet

java.lang.Object
  extended bynbi.xmlsec.xacml.profile.rbac.RBACPolicyElement
      extended bynbi.xmlsec.xacml.profile.rbac.RBACPolicy
          extended bynbi.xmlsec.xacml.profile.rbac.RBACPolicySet
              extended bynbi.xmlsec.xacml.profile.rbac.PermissionPolicySet

public class PermissionPolicySet
extends RBACPolicySet

This class implements a permission policy set according to the XACML RBAC Profile. It administers permission policies, which may be represented as a PolicySetor parsed from a PolicySet representation.

Since:
Version:
$Revision: 1.2 $
Author:
Lutz Suhrbier

Field Summary
(package private) static int DEFAULT_PERMIT_DENY
           
(package private) static int DEFAULT_PERMIT_INDETERMINATE
           
(package private) static int DEFAULT_PERMIT_NONE
           
(package private) static int DEFAULT_PERMIT_NOT_APPLICABLE
           
(package private) static int DEFAULT_PERMIT_PERMIT
           
(package private)  int defaultPermit
           
 
Fields inherited from class nbi.xmlsec.xacml.profile.rbac.RBACPolicySet
REPRESENT_POLICIES_AS_NONE, REPRESENT_POLICIES_AS_POLICY, REPRESENT_POLICIES_AS_POLICYREF
 
Fields inherited from class nbi.xmlsec.xacml.profile.rbac.RBACPolicy
elements, logger, permitRule
 
Fields inherited from class nbi.xmlsec.xacml.profile.rbac.RBACPolicyElement
 
Constructor Summary
PermissionPolicySet(PolicyReference policySet)
          Creates a permission policy set from its PolicyReference representation.
PermissionPolicySet(PolicySet policySet)
          Creates a permission policy set from its PolicySet representation.
PermissionPolicySet(String domain, String label)
          Creates a permission policy set from its identifier.
PermissionPolicySet(URI id)
          Creates a permission policy set from its identifier.
 
Method Summary
 boolean add(RBACPolicyElement element)
          If the element is an PermissionPolicy, the element is added to the set of elements.
 void parse(PolicyTreeElement element)
          Parses a permission policy set from its PolicySet representation.
 void parse(Target target)
          Parses the target of an PermissionPolicySet.
 boolean remove(RBACPolicyElement element)
          If the element is an PermissionPolicy, the element is removed from the set of elements.
 
Methods inherited from class nbi.xmlsec.xacml.profile.rbac.RBACPolicySet
encode, getPolicyRepresentationType, parse, setPolicyRepresentationType, toPolicyRerence, toPolicyTreeElement
 
Methods inherited from class nbi.xmlsec.xacml.profile.rbac.RBACPolicy
encode, equals, getElements, isPermitRule, parse, search, search, setPermitRule, toPolicyRerence, toPolicyTreeElement
 
Methods inherited from class nbi.xmlsec.xacml.profile.rbac.RBACPolicyElement
getIdentifier, getTarget, hashCode, setIdentifier, setIdentifier, setTarget, toString
 
Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, wait, wait, wait
 

Field Detail

DEFAULT_PERMIT_NONE

static final int DEFAULT_PERMIT_NONE
See Also:
Constant Field Values

DEFAULT_PERMIT_PERMIT

static final int DEFAULT_PERMIT_PERMIT
See Also:
Constant Field Values

DEFAULT_PERMIT_DENY

static final int DEFAULT_PERMIT_DENY
See Also:
Constant Field Values

DEFAULT_PERMIT_NOT_APPLICABLE

static final int DEFAULT_PERMIT_NOT_APPLICABLE
See Also:
Constant Field Values

DEFAULT_PERMIT_INDETERMINATE

static final int DEFAULT_PERMIT_INDETERMINATE
See Also:
Constant Field Values

defaultPermit

int defaultPermit
Constructor Detail

PermissionPolicySet

public PermissionPolicySet(String domain,
                           String label)
Creates a permission policy set from its identifier. The default policy representation type is set to REPRESENT_POLICIES_AS_POLICYREF.

Parameters:
domain - Identifier's domain.
label - Identifier's label.

PermissionPolicySet

public PermissionPolicySet(URI id)
                    throws ParsingException
Creates a permission policy set from its identifier. The default policy representation type is set to REPRESENT_POLICIES_AS_POLICYREF.

Parameters:
id - Identifier's URI representation.

PermissionPolicySet

public PermissionPolicySet(PolicySet policySet)
                    throws ParsingException
Creates a permission policy set from its PolicySet representation. The first policy parsed determines the policy representation type of the policy set.

Parameters:
policySet - PolicySetrepresentation.

PermissionPolicySet

public PermissionPolicySet(PolicyReference policySet)
                    throws ParsingException
Creates a permission policy set from its PolicyReference representation. The first policy parsed determines the policy representation type of the policy set.

Parameters:
policySet - PolicySetrepresentation.
Method Detail

add

public boolean add(RBACPolicyElement element)
If the element is an PermissionPolicy, the element is added to the set of elements.

Overrides:
add in class RBACPolicy
Parameters:
element - The element to be added.
Returns:
true, if the permission policy was succesfully added, false otherwise.
See Also:
RBACPolicy.add(RBACPolicyElement)

remove

public boolean remove(RBACPolicyElement element)
If the element is an PermissionPolicy, the element is removed from the set of elements.

Overrides:
remove in class RBACPolicy
Parameters:
element - The element to remove.
Returns:
true, if the permission policy was succesfully removed, false otherwise.
See Also:
RBACPolicy.remove(RBACPolicyElement)

parse

public void parse(Target target)
           throws ParsingException
Parses the target of an PermissionPolicySet.

Overrides:
parse in class RBACPolicyElement
Parameters:
target - The target to parse.
Throws:
ParsingException - Signals errors during the parsing process.
See Also:
RBACPolicyElement.parse(com.sun.xacml.Target)

parse

public void parse(PolicyTreeElement element)
           throws ParsingException
Parses a permission policy set from its PolicySet representation. The first policy parsed determines the policy representation type of the policy set.

Overrides:
parse in class RBACPolicySet
Parameters:
element - The policy set to parse.
Throws:
ParsingException - Indicates errors during the parsing process.


Copyright © 2006 Lutz Suhrbier, Freie Universitšt Berlin. All Rights Reserved.