Module: Yell::Helpers::Formatter

Included in:
Adapters::Io, Logger
Defined in:
lib/yell/helpers/formatter.rb

Overview

:nodoc:

Instance Method Summary collapse

Instance Method Details

#formatterObject Also known as: format



15
16
17
# File 'lib/yell/helpers/formatter.rb', line 15

def formatter
  @__formatter__
end

#formatter=(pattern) ⇒ Object Also known as: format=

Set the format for your message.



7
8
9
10
11
12
# File 'lib/yell/helpers/formatter.rb', line 7

def formatter=( pattern )
  @__formatter__ = case pattern
  when Yell::Formatter then pattern
  else Yell::Formatter.new(*pattern)
  end
end