Package ch.tocco.nice2.security.impl
Class PolicyImpl
java.lang.Object
ch.tocco.nice2.security.impl.PolicyImpl
- All Implemented Interfaces:
Policy,Serializable,Iterable<Rule>
Simple implementation of
Policy.
This is used to be an anonymous class in PolicyBuilderImpl, which caused
that the containing policy builder remained in memory even though it was no longer needed.- See Also:
-
Field Summary
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptiongetRules()booleanisEmpty()iterator()subPolicy(Permission permission) Returns aPolicythat contains only rules that are relevant for the given permission.subPolicy(SecurityDomain securityDomain) Returns aPolicythat contains only rules that are relevant for the given domain.Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitMethods inherited from interface java.lang.Iterable
forEach, spliterator
-
Constructor Details
-
PolicyImpl
-
-
Method Details
-
isEmpty
public boolean isEmpty() -
getRules
-
subPolicy
Description copied from interface:PolicyReturns aPolicythat contains only rules that are relevant for the given permission. This policy may be cached internally and is more efficient than filtering rules manually. -
subPolicy
Description copied from interface:PolicyReturns aPolicythat contains only rules that are relevant for the given domain. This policy may be cached internally and is more efficient than filtering rules manually. -
iterator
-