Sha256: 54761d018bae6eb3f15cf906678910d33ef297ceb1e078b1ae4fad1af50320bf
Contents?: true
Size: 485 Bytes
Versions: 9
Compression:
Stored size: 485 Bytes
Contents
require 'csv' module IOStreams module CSV class Reader # Read from a file or stream def self.open(file_name_or_io, options = Hash.new, &block) unless IOStreams.reader_stream?(file_name_or_io) ::CSV.open(file_name_or_io, options, &block) else begin csv = ::CSV.new(file_name_or_io, options) block.call(csv) ensure csv.close if csv end end end end end end
Version data entries
9 entries across 9 versions & 1 rubygems