Method: Oscillo::Enumerable#collect
- Defined in:
- lib/oscillo/enumerable.rb
#collect {|*signals| ... } ⇒ Signal Also known as: map
Returns a signal that is the result of running the values of the original signal through the block.
12 13 14 |
# File 'lib/oscillo/enumerable.rb', line 12 def collect(&block) self.class.new(self) { |*v, s| block.(*v) } end |