module Shamu::Security::RolesService
Used to determine the roles that the current {Principal} should be given on a {Services::Service}.
Public Class Methods
create( scorpion, * )
click to toggle source
@!visibility private
# File lib/shamu/security/roles_service.rb, line 9 def self.create( scorpion, * ) scorpion.new EmptyRolesService end
Public Instance Methods
roles_for( principal, reload: false )
click to toggle source
@param [Principal] principal of the currently logged in user. @param [Boolean] reload to reload the roles from storage and bypass any caching. @return [Array<Symbol>] the roles granted to the principal.
# File lib/shamu/security/roles_service.rb, line 17 def roles_for( principal, reload: false ) [] end