Method: Log4r::MailOutputter#initialize
- Defined in:
- lib/log4r/mail_outputter.rb
#initialize(_name, hash = {}) ⇒ MailOutputter
Returns a new instance of MailOutputter.
10 11 12 13 14 15 16 17 18 19 |
# File 'lib/log4r/mail_outputter.rb', line 10 def initialize(_name, hash={}) super(_name, hash) @host = hash[:host] || hash["host"] || "localhost" @port = hash[:port] || hash["port"] || 25 @from = hash[:from] || hash["from"] || "" @to = hash[:to] || hash["to"] || "" @subject = hash[:subject] || hash["subject"] || "" @body = hash[:body] || hash["body"] || "" @encoding = hash[:encoding] || hash["encoding"] || "UTF-8" end |