Module: SafetyPatrol::Abilities::ClassMethods

Defined in:
lib/safety_patrol/abilities.rb

Instance Attribute Summary collapse

Instance Method Summary collapse

Instance Attribute Details

#_authorizerObject

Returns the value of attribute _authorizer.



11
12
13
# File 'lib/safety_patrol/abilities.rb', line 11

def _authorizer
  @_authorizer
end

Instance Method Details

#authorizer(object = nil) ⇒ Object



13
14
15
16
17
18
19
# File 'lib/safety_patrol/abilities.rb', line 13

def authorizer(object = nil)
	if object.nil?
		self._authorizer
	else
		self._authorizer = (object.is_a?(String)) ? Kernel.const_get(object).new : object.new
	end
end