Class: RIO::IOH::Dir

Inherits:
Base show all
Extended by:
Fwd
Defined in:
lib/rio/ioh.rb

Instance Attribute Summary

Attributes inherited from Base

#ios

Instance Method Summary collapse

Methods included from Fwd

fwd, fwd_reader, fwd_readers, fwd_writer, fwd_writers

Methods inherited from Base

#callstr, #handle, #initialize, #initialize_copy, #ior, #iow, #open?

Constructor Details

This class inherits a constructor from RIO::IOH::Base

Instance Method Details

#closeObject



157
158
159
160
161
162
163
# File 'lib/rio/ioh.rb', line 157

def close
  #p "#{callstr('close')} ios=#{ios}"
  unless ios.nil?
    ios.close
    ios = nil
  end
end

#closed?Boolean

Returns:

  • (Boolean)


164
# File 'lib/rio/ioh.rb', line 164

def closed?() ios.nil? end

#each(&block) ⇒ Object



165
166
167
168
169
# File 'lib/rio/ioh.rb', line 165

def each(&block)
  while filename = handle.read
    yield filename
  end
end