Class: Console::Output::Split
- Inherits:
-
Object
- Object
- Console::Output::Split
- Defined in:
- lib/console/output/split.rb
Class Method Summary collapse
Instance Method Summary collapse
- #call ⇒ Object
-
#initialize(outputs) ⇒ Split
constructor
A new instance of Split.
- #verbose!(value = true) ⇒ Object
Constructor Details
#initialize(outputs) ⇒ Split
Returns a new instance of Split.
13 14 15 |
# File 'lib/console/output/split.rb', line 13 def initialize(outputs) @outputs = outputs end |
Class Method Details
.[](*outputs) ⇒ Object
9 10 11 |
# File 'lib/console/output/split.rb', line 9 def self.[](*outputs) self.new(outputs) end |
Instance Method Details
#call ⇒ Object
21 22 23 24 25 |
# File 'lib/console/output/split.rb', line 21 def call(...) @outputs.each do |output| output.call(...) end end |
#verbose!(value = true) ⇒ Object
17 18 19 |
# File 'lib/console/output/split.rb', line 17 def verbose!(value = true) @outputs.each{|output| output.verbose!(value)} end |