Class: Checkpoint::Resource::Resolver
- Inherits:
-
Object
- Object
- Checkpoint::Resource::Resolver
- Defined in:
- lib/checkpoint/resource/resolver.rb
Overview
A Resource Resolver takes a concrete object (like a model instance) and resolves it into all Checkpoint::Resources for which a permit would allow an action. For example, this can be used to grant a credential on all items of a given model class or to implement cascading permissions when all credentials for a container should apply to the contained objects.
NOTE: This implementation currently always resolves to the entity and its type and nothing more. This needs some thought on an appropriate extension mechanism to mirror the PermissionMapper.