Module: Savon::Logger::ClassMethods

Defined in:
lib/savon/logger.rb

Instance Method Summary collapse

Instance Method Details

#log=(log) ⇒ Object

Sets whether to log.



14
15
16
# File 'lib/savon/logger.rb', line 14

def log=(log)
  @log = log
end

#log?Boolean

Returns whether to log. Defaults to true.

Returns:

  • (Boolean)


19
20
21
# File 'lib/savon/logger.rb', line 19

def log?
  @log != false
end

#log_levelObject

Returns the log level. Defaults to debug.



39
40
41
# File 'lib/savon/logger.rb', line 39

def log_level
  @log_level ||= :debug
end

#log_level=(log_level) ⇒ Object

Sets the log level.



34
35
36
# File 'lib/savon/logger.rb', line 34

def log_level=(log_level)
  @log_level = log_level
end

#loggerObject

Returns the logger. Defaults to an instance of Logger writing to STDOUT.



29
30
31
# File 'lib/savon/logger.rb', line 29

def logger
  @logger ||= ::Logger.new STDOUT
end

#logger=(logger) ⇒ Object

Sets the logger.



24
25
26
# File 'lib/savon/logger.rb', line 24

def logger=(logger)
  @logger = logger
end