Class AbstractMembershipHierarchyPolicyProcessor
java.lang.Object
ch.tocco.nice2.persist.security.api.provider.AbstractCustomPolicyProcessor
ch.tocco.nice2.optional.membershiphierarchy.spi.policy.AbstractMembershipHierarchyPolicyProcessor
- All Implemented Interfaces:
PolicyProcessor
- Direct Known Subclasses:
AddressMembershipHierarchyPolicyProcessor
,MembershipHierarchyPolicyProcessor
,UserMembershipHierarchyPolicyProcessor
public abstract class AbstractMembershipHierarchyPolicyProcessor
extends AbstractCustomPolicyProcessor
Base class for policy processors that are based on the membership hierarchy structure.
This class obtains all readable addresses using a recursive query.
All addresses found through 'relAssociation_address' are writable and addresses found through
'relAssociation_address_read' are readable.
Two rules are then added to the policy (one for read and one for write access - if any addresses were found),
the condition of the rule is created by the subclass, depending on the path to the address.
-
Field Summary
Fields inherited from class ch.tocco.nice2.persist.security.api.provider.AbstractCustomPolicyProcessor
typeManager
-
Constructor Summary
ConstructorDescriptionAbstractMembershipHierarchyPolicyProcessor
(SecurityManager securityManager, TypeManager typeManager, DataModel dataModel, AddressHierarchyResolver addressHierarchyResolver) -
Method Summary
Modifier and TypeMethodDescriptionprotected abstract Node
createCondition
(Set<PrimaryKey> addressKeys, EntityModel entityModel) protected void
doProcessPolicy
(PolicyBuilder policy, EntityModel entityModel) Methods inherited from class ch.tocco.nice2.persist.security.api.provider.AbstractCustomPolicyProcessor
appendRule, handleEntityModel, handlePrincipal, prependRule, processPolicy
-
Constructor Details
-
AbstractMembershipHierarchyPolicyProcessor
public AbstractMembershipHierarchyPolicyProcessor(SecurityManager securityManager, TypeManager typeManager, DataModel dataModel, AddressHierarchyResolver addressHierarchyResolver)
-
-
Method Details
-
doProcessPolicy
- Specified by:
doProcessPolicy
in classAbstractCustomPolicyProcessor
-
createCondition
-