org.openpermis.policy
Interface PartFactory

All Known Subinterfaces:
PartBeanFactory
All Known Implementing Classes:
BasicPartBeanFactory

public interface PartFactory

Creates policy parts.

Since:
0.1.0

Method Summary
 Action createAction(String name, ParameterList parameterList)
          Creates an action.
 ActionCollection createActionCollection(Collection<? extends Action> collection)
          Creates a action collection.
 And createAnd(Predicate... predicates)
           
 Authority createAuthority(URI identity)
          Creates a new authority.
 Domain createDomain(List<List<URI>> domainURIs)
          Creates a new domain.
 Domain createDomain(URI uri)
          Creates a new domain.
 False createFalse()
           
 Not createNot(Predicate predicate)
           
 Obligation createObligation(String text)
          Creates a new obligation.
 ObligationCollection createObligationCollection(Collection<? extends Obligation> collection)
          Creates a obligation collection.
 Or createOr(Predicate... predicates)
           
 Policy createPolicy()
          Creates a new policy.
 Policy createPolicy(org.joda.time.DateTimeZone zone, RoleHierarchyCollection hierarchies, TargetAccessRuleCollection targetAccessRules, RoleAssignmentRuleCollection roleAssignmentRules)
          Creates a new policy.
 Present createPresent(Value<?> value)
           
 RoleAssignmentRule createRoleAssignmentRule(Authority authority, DomainBean subjectDomain, Collection<Role> roles, TimePeriodConstraint constraint, int delegationDepth)
          Creates a role assignment rule.
 RoleAssignmentRuleCollection createRoleAssignmentRuleCollection(Collection<? extends RoleAssignmentRule> collection)
          Creates a role assignment rule collection.
 RoleHierarchy createRoleHierarchy(URI uri)
          Creates a new role hierarchy.
 RoleHierarchyCollection createRoleHierarchyCollection(Collection<? extends RoleHierarchy> collection)
          Creates a new role hierarchy collection.
 SubstringOf createSubstringOf(Value<?> first, Value<?> second)
           
 Target createTarget(Domain domain, ActionCollection actions)
          Creates a target.
 TargetAccessRule createTargetAccessRule(TargetCollection targets, Collection<Role> roles, Predicate condition, ObligationCollection obligations)
          Creates a target access rule.
 TargetAccessRuleCollection createTargetAccessRuleCollection(Collection<? extends TargetAccessRule> collection)
          Creates a target access rule collection.
 TargetCollection createTargetCollection(Collection<? extends Target> collection)
          Creates a target collection.
 True createTrue()
           
 ValueRelationalPredicate createValueRelationalPredicate(ValueRelationalPredicate.Relation relation, Value<?> first, Value<?> second)
           
 ValueSetRelationalPredicate createValueSetRelationalPredicate(ValueSetRelationalPredicate.SetRelation relation, ValueSet first, ValueSet second)
           
 

Method Detail

createAction

Action createAction(String name,
                    ParameterList parameterList)
Creates an action.

Parameters:
name - the name that the created action will have.
parameterList - a ParameterList that defines the arguments for this action.
Returns:
an Action instance.
Since:
0.1.0

createActionCollection

ActionCollection createActionCollection(Collection<? extends Action> collection)
Creates a action collection.

Parameters:
collection - of Action's.
Returns:
a ActionCollection instance.
Since:
0.3.0

createAuthority

Authority createAuthority(URI identity)
Creates a new authority.

Parameters:
identity - the URI identifying the authority.
Returns:
an Authority instance.
Since:
0.1.0

createDomain

Domain createDomain(List<List<URI>> domainURIs)
Creates a new domain.

Parameters:
domainURIs - the List of URI Lists defining the domain.
Returns:
a Domain instance.
Since:
new

createDomain

Domain createDomain(URI uri)
Creates a new domain.

Parameters:
uri - the only URI the Domain consists of.
Returns:
a Domain instance.
Since:
new

createObligation

Obligation createObligation(String text)
Creates a new obligation.

Parameters:
text - the String describing the obligation.
Returns:
a Obligation instance.
Since:
0.3.0

createObligationCollection

ObligationCollection createObligationCollection(Collection<? extends Obligation> collection)
Creates a obligation collection.

Parameters:
collection - of Obligation's.
Returns:
a ObligationCollection instance.
Since:
0.3.0

createPolicy

Policy createPolicy()
Creates a new policy.

Returns:
a Policy instance.
Since:
0.1.0

createPolicy

Policy createPolicy(org.joda.time.DateTimeZone zone,
                    RoleHierarchyCollection hierarchies,
                    TargetAccessRuleCollection targetAccessRules,
                    RoleAssignmentRuleCollection roleAssignmentRules)
Creates a new policy.

Parameters:
zone - a DateTimeZone the time zone of this policy,
hierarchies - a RoleHierarchyCollection.
targetAccessRules - a TargetAccessRuleCollection.
roleAssignmentRules - RoleAssignmentRuleCollection.
Returns:
a Policy instance.
Since:
0.3.0

createRoleHierarchy

RoleHierarchy createRoleHierarchy(URI uri)
Creates a new role hierarchy.

Parameters:
uri - the URI uniquely identifying the role hierarchy.
Returns:
a RoleHierarchy instance.
Since:
0.3.0

createRoleHierarchyCollection

RoleHierarchyCollection createRoleHierarchyCollection(Collection<? extends RoleHierarchy> collection)
Creates a new role hierarchy collection.

Parameters:
collection - of RoleHierarchy's.
Returns:
a RoleHierarchyCollection instance.
Since:
0.3.0

createRoleAssignmentRule

RoleAssignmentRule createRoleAssignmentRule(Authority authority,
                                            DomainBean subjectDomain,
                                            Collection<Role> roles,
                                            TimePeriodConstraint constraint,
                                            int delegationDepth)
Creates a role assignment rule.

Parameters:
authority - the Authority granting the right to delegate roles.
subjectDomain - the Domain of subjects to which this role applies.
roles - the Roles that the rule allows to be delegated.
constraint - the TimePeriodConstraint of this rule.
delegationDepth - the number of times a role may be delegated to somebody else.
Returns:
a RoleAssignmentRule instance.
Since:
0.3.0

createRoleAssignmentRuleCollection

RoleAssignmentRuleCollection createRoleAssignmentRuleCollection(Collection<? extends RoleAssignmentRule> collection)
Creates a role assignment rule collection.

Parameters:
collection - of RoleAssignmentRule's.
Returns:
a RoleAssignmentRuleCollection instance.
Since:
0.3.0

createTarget

Target createTarget(Domain domain,
                    ActionCollection actions)
Creates a target.

Parameters:
domain - the Domain identifying the resources of this target.
actions - the ActionCollection that can be performed on the resources.
Returns:
a Target instance.
Since:
0.3.0

createTargetCollection

TargetCollection createTargetCollection(Collection<? extends Target> collection)
Creates a target collection.

Parameters:
collection - of Target's.
Returns:
a TargetCollection instance.
Since:
0.3.0

createTargetAccessRule

TargetAccessRule createTargetAccessRule(TargetCollection targets,
                                        Collection<Role> roles,
                                        Predicate condition,
                                        ObligationCollection obligations)
Creates a target access rule.

Parameters:
targets - a TargetCollection for which this rule applies.
roles - the Roles that a subject needs to get access to this target.
condition - the predicate that must evaluate to true in order for the rule to grant access.
obligations - the ObligationCollections for this rule.
Returns:
a TargetAccessRule instance.
Since:
0.3.0

createTargetAccessRuleCollection

TargetAccessRuleCollection createTargetAccessRuleCollection(Collection<? extends TargetAccessRule> collection)
Creates a target access rule collection.

Parameters:
collection - of TargetAccessRule's.
Returns:
a TargetAccessRuleCollection instance.
Since:
0.3.0

createTrue

True createTrue()
Since:
0.9.0

createFalse

False createFalse()
Since:
0.9.0

createAnd

And createAnd(Predicate... predicates)
Since:
0.9.0

createOr

Or createOr(Predicate... predicates)
Since:
0.9.0

createNot

Not createNot(Predicate predicate)
Since:
0.9.0

createPresent

Present createPresent(Value<?> value)
Since:
0.9.0

createSubstringOf

SubstringOf createSubstringOf(Value<?> first,
                              Value<?> second)
Since:
0.9.0

createValueRelationalPredicate

ValueRelationalPredicate createValueRelationalPredicate(ValueRelationalPredicate.Relation relation,
                                                        Value<?> first,
                                                        Value<?> second)
Since:
0.9.0

createValueSetRelationalPredicate

ValueSetRelationalPredicate createValueSetRelationalPredicate(ValueSetRelationalPredicate.SetRelation relation,
                                                              ValueSet first,
                                                              ValueSet second)
Since:
0.9.0


OpenPermis Role Based Access Control 0.9.0 (Build 16)
2009/08/13 07:16:59
Copyright (c) 2002-2007 Ergon Informatik AG