class Firuta::Commands::Reduce

Public Class Methods

terminal?() click to toggle source
# File lib/firuta/commands/reduce.rb, line 14
def self.terminal?
  true
end

Public Instance Methods

apply_to(collection) click to toggle source
# File lib/firuta/commands/reduce.rb, line 10
def apply_to(collection)
  collection.reduce(*@params, &@proc)
end
call(element) click to toggle source
# File lib/firuta/commands/reduce.rb, line 6
def call(element)
  @proc.call(*@params, element)
end