Class: CSV::Parser::UnoptimizedStringIO

Inherits:
Object
  • Object
show all
Defined in:
lib/csv/parser.rb

Instance Method Summary collapse

Constructor Details

#initialize(string) ⇒ UnoptimizedStringIO

Returns a new instance of UnoptimizedStringIO.



711
712
713
# File 'lib/csv/parser.rb', line 711

def initialize(string)
  @io = StringIO.new(string, "rb:#{string.encoding}")
end

Instance Method Details

#each_line(*args, &block) ⇒ Object



719
720
721
# File 'lib/csv/parser.rb', line 719

def each_line(*args, &block)
  @io.each_line(*args, &block)
end

#eof?Boolean

Returns:

  • (Boolean)


723
724
725
# File 'lib/csv/parser.rb', line 723

def eof?
  @io.eof?
end

#gets(*args) ⇒ Object



715
716
717
# File 'lib/csv/parser.rb', line 715

def gets(*args)
  @io.gets(*args)
end