class Ruumba::Iterators::StdinIterator
Iterator which returns the file passed in via stdin
Attributes
file[R]
Public Class Methods
new(file)
click to toggle source
# File lib/ruumba/iterators.rb, line 12 def initialize(file) @file = file end
Public Instance Methods
each(&block)
click to toggle source
# File lib/ruumba/iterators.rb, line 16 def each(&block) [[file, STDIN.read]].each(&block) end