Sha256: b452ed6d5fd5d9d55be14889eeafd78ec839faf21ed652ffa017f34163b21771

Contents?: true

Size: 188 Bytes

Versions: 9

Compression:

Stored size: 188 Bytes

Contents

module Stages
  class ExhaustCount < Stage
    def process
      results = 0
      while !source_empty?
        input
        results += 1
      end
      output results
    end
  end
end

Version data entries

9 entries across 9 versions & 1 rubygems

Version Path
stages-1.2.1 lib/stages/exhaust_count.rb
stages-1.2.0 lib/stages/exhaust_count.rb
stages-1.1.5 lib/stages/exhaust_count.rb
stages-1.1.2 lib/stages/exhaust_count.rb
stages-1.1.1 lib/stages/exhaust_count.rb
stages-1.0.1 lib/stages/exhaust_count.rb
stages-1.0.0 lib/stages/exhaust_count.rb
stages-0.4.1 lib/stages/exhaust_count.rb
stages-0.4.0 lib/stages/exhaust_count.rb