Package ndg :: Package xacml :: Package finder :: Module policyfinderbase :: Class PolicyFinderBase
[hide private]

Class PolicyFinderBase

source code

object --+
         |
        PolicyFinderBase
Known Subclasses:

Base class for policy finders. The specific finder strategy is implemented in the findPolicy and findPolicySet methods.

Nested Classes [hide private]
  __metaclass__
Metaclass for defining Abstract Base Classes (ABCs).
Instance Methods [hide private]
 
__init__(self)
x.__init__(...) initializes x; see help(type(x)) for signature
source code
None (subclasses should return ndg.xacml.core.policy.Policy)
findPolicy(self, policyIdReference, common)
Retrieves a policy for a specified policy ID.
source code
None (subclasses should return ndg.xacml.core.policy.PolicySet)
findPolicySet(self, policySetIdReference, common)
Retrieves a policy set for a specified policy set ID.
source code
 
setReader(self, reader)
Sets the reader to be used when parsing referenced policies.
source code
 
addPolicyReference(self, policy) source code
 
addPolicySetReference(self, policySet) source code

Inherited from object: __delattr__, __format__, __getattribute__, __hash__, __new__, __reduce__, __reduce_ex__, __repr__, __setattr__, __sizeof__, __str__, __subclasshook__

Class Variables [hide private]
  __abstractmethods__ = frozenset(['findPolicy', 'findPolicySet'])
  _abc_cache = <_weakrefset.WeakSet object at 0x1011a6f90>
  _abc_negative_cache = <_weakrefset.WeakSet object at 0x1011a6fd0>
  _abc_negative_cache_version = 10
  _abc_registry = <_weakrefset.WeakSet object at 0x1011a6f50>
Properties [hide private]

Inherited from object: __class__

Method Details [hide private]

__init__(self)
(Constructor)

source code 

x.__init__(...) initializes x; see help(type(x)) for signature

Overrides: object.__init__
(inherited documentation)

findPolicy(self, policyIdReference, common)

source code 

Retrieves a policy for a specified policy ID.

Parameters:
  • policyIdReference (str) - policy ID reference
  • common (from ndg.xacml.parsers.common.Common) - parsing common data
Returns: None (subclasses should return ndg.xacml.core.policy.Policy)
policy
Decorators:
  • @abstractmethod

findPolicySet(self, policySetIdReference, common)

source code 

Retrieves a policy set for a specified policy set ID.

Parameters:
  • policySetIdReference (str) - policy set ID reference
  • common (from ndg.xacml.parsers.common.Common) - parsing common data
Returns: None (subclasses should return ndg.xacml.core.policy.PolicySet)
policy set
Decorators:
  • @abstractmethod

setReader(self, reader)

source code 

Sets the reader to be used when parsing referenced policies.

Parameters:
  • reader (ndg.xacml.parsers.AbstractReader derived type) - reader

addPolicyReference(self, policy)

source code 
Parameters:
  • policy (ndg.xacml.core.policy.Policy) - policy
Raises:
  • XMLParseError - if the policy's ID is a duplicate of one already found

addPolicySetReference(self, policySet)

source code 
Parameters:
  • policySet (ndg.xacml.core.policy.PolicySet) - policy set
Raises:
  • XMLParseError - if the policy's ID is a duplicate of one already found