T - type of the entity encapsulated into the PermissionBean.public interface AuthorizationHandler<T> extends Service
AuthorizationRequestBean, PermissionBean| Modifier and Type | Method and Description |
|---|---|
PermissionBean<T> |
getPermission(AuthorizationRequestBean request)
Decides if a user is authorized to perform the operation on an asset in a site.
|
getManager, getResponse, setManagerPermissionBean<T> getPermission(AuthorizationRequestBean request) throws ServiceException
AuthorizationHandler ;MyData ; authHandler = ...; // get the service object AuthorizationRequestBean req = ...; // Populate request object PermissionBean ;MyData ; perm = authHandler.getPermission(); // If the operation is permitted boolean permitted = perm.isPermitted(); AssetId asset = perm.getAsset(); // Further information MyData data = perm.getEntity();
request - input to this service.ServiceException - in case of any server side exceptions. see Function