Class: CheekyDreams::StdIOAuditor
- Inherits:
-
Object
- Object
- CheekyDreams::StdIOAuditor
- Defined in:
- lib/cheeky-dreams.rb
Instance Method Summary collapse
- #audit(type, message) ⇒ Object
-
#initialize(out = STDOUT, err = STDERR) ⇒ StdIOAuditor
constructor
A new instance of StdIOAuditor.
Constructor Details
#initialize(out = STDOUT, err = STDERR) ⇒ StdIOAuditor
Returns a new instance of StdIOAuditor.
62 63 64 |
# File 'lib/cheeky-dreams.rb', line 62 def initialize out = STDOUT, err = STDERR @out, @err = out, err end |
Instance Method Details
#audit(type, message) ⇒ Object
66 67 68 69 70 71 72 73 |
# File 'lib/cheeky-dreams.rb', line 66 def audit type, case type when :error @err.puts "#{type} - #{}" else @out.puts "#{type} - #{}" end end |