Class DelegatingEntityDocsListGuard<O,S>
java.lang.Object
ch.tocco.nice2.security.api.AbstractListGuard
ch.tocco.nice2.dms.impl.security.guard.DelegatingEntityDocsListGuard<O,S>
- All Implemented Interfaces:
ListGuard
A
ListGuard implementation that accepts Entity or EntityPath objects
that may be from different models/paths.
The object are grouped according to the given Function and then evaluated separately.-
Field Summary
FieldsModifier and TypeFieldDescriptionstatic final Function<EntityReference, String> static final Function<EntityPath, Tuple2<String, String>> -
Constructor Summary
ConstructorsConstructorDescriptionDelegatingEntityDocsListGuard(SecurityManager securityManager, GuardContext guardContext, List<S> securedObjects, Function<S, O> mapperFunction) -
Method Summary
Modifier and TypeMethodDescriptionevaluatePermissions(Permission permission) Evaluates a permission.List<?> toGuard()Methods inherited from class AbstractListGuard
checkPermission
-
Field Details
-
ENTITY_PATH_FUNCTION
-
ENTITY_FUNCTION
-
-
Constructor Details
-
DelegatingEntityDocsListGuard
public DelegatingEntityDocsListGuard(SecurityManager securityManager, GuardContext guardContext, List<S> securedObjects, Function<S, O> mapperFunction)
-
-
Method Details
-
getPrincipal
-
getSecured
- Returns:
- The objects this guard is protecting.
-
evaluatePermissions
Description copied from interface:ListGuardEvaluates a permission. This method returns anGuard.Decisionproviding some more information about *why* a permission is granted or denied.- Parameters:
permission- The permission to evaluate.- Returns:
- An
Guard.Decision.
-
getSecurityContext
-
toGuard
-