Package org.nuxeo.ecm.core.api.impl
Class PermissionFilter
- java.lang.Object
-
- org.nuxeo.ecm.core.api.impl.PermissionFilter
-
- All Implemented Interfaces:
Filter
public class PermissionFilter extends Object implements Filter
A filter based on permissions.If one of the permission check throws an Exception, the
accept(org.nuxeo.ecm.core.api.DocumentModel)
method returns false.- Since:
- 5.7.2
-
-
Constructor Summary
Constructors Constructor Description PermissionFilter(String permission, boolean isRequired)
PermissionFilter(List<String> required, List<String> excluded)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description boolean
accept(DocumentModel docModel)
Filters data models objects.protected boolean
hasPermission(CoreSession session, DocumentModel doc, Set<String> permissions, boolean required)
-
-
-
Method Detail
-
accept
public boolean accept(DocumentModel docModel)
Description copied from interface:Filter
Filters data models objects.
-
hasPermission
protected boolean hasPermission(CoreSession session, DocumentModel doc, Set<String> permissions, boolean required)
-
-