Class: Chef::Audit::Logger

Inherits:
Object
  • Object
show all
Defined in:
lib/chef/audit/logger.rb

Class Method Summary collapse

Class Method Details

.puts(message = "") ⇒ Object


23
24
25
26
27
28
# File 'lib/chef/audit/logger.rb', line 23

def self.puts(message = "")
  @buffer ||= StringIO.new
  @buffer.puts(message)

  Chef::Log.info(message)
end

.read_bufferObject


30
31
32
33
# File 'lib/chef/audit/logger.rb', line 30

def self.read_buffer
  return "" if @buffer.nil?
  @buffer.string
end