Class: LoggerHelper

Inherits:
Object
  • Object
show all
Defined in:
lib/facter/framework/logging/logger_helper.rb

Class Method Summary collapse

Class Method Details

.determine_callers_name(sender_self) ⇒ Object



5
6
7
8
9
10
11
12
13
14
15
16
# File 'lib/facter/framework/logging/logger_helper.rb', line 5

def determine_callers_name(sender_self)
  case sender_self
  when String
    sender_self
  when Class
    sender_self.name
  when Module
    sender_self.name
  else # when class is singleton
    sender_self.class.name
  end
end