public interface PolicyService
Policyis stored under a unique name, for which there may be several other
Policyinstances. Consumers can either check whether such a policy restriction is active via
isRestricted(String, IObject)or let an exception be thrown by the
checkRestriction(String, IObject). Further, the list of currently active restrictions can be provided in bulk to clients via
listActiveRestrictions(IObject)so that restricted operations need not be called only to have an exception thrown.
|Modifier and Type||Method and Description|
Ask each configured
boolean isRestricted(String name, ome.model.IObject obj)
Policyinstance with the given name argument if it considers the restriction active for the given
IObjectargument. If any are active, return true.
void checkRestriction(String name, ome.model.IObject obj) throws ome.conditions.SecurityViolation
Policyinstance the chance to throw a
name- non-null identifier of a class of
obj- non-null "context" for this check.
checkRestriction(String, IObject)which considers itself active for the given argument.
obj- non-null context passed to each
Copyright © 2015 The University of Dundee & Open Microscopy Environment. All Rights Reserved.