Class: MultiProcess::Logger
- Defined in:
- lib/multi_process/logger.rb
Overview
Can create pipes and multiplex pipe content to put into given IO objects e.g. multiple output from multiple processes to current stdout.
Instance Attribute Summary
Attributes inherited from Receiver
Class Method Summary collapse
Instance Method Summary collapse
-
#initialize(*args) ⇒ Logger
constructor
Create new logger.
Methods inherited from Receiver
Constructor Details
#initialize(*args) ⇒ Logger
Create new logger.
14 15 16 17 18 19 20 |
# File 'lib/multi_process/logger.rb', line 14 def initialize(*args) @opts = Hash === args.last ? args.pop : {} @out = args[0] || $stdout @err = args[1] || $stderr super() end |
Class Method Details
.global ⇒ Object
69 70 71 |
# File 'lib/multi_process/logger.rb', line 69 def global @global ||= new $stdout, $stderr end |