Class
Class Methods
::
lib/csv/parser.rb
View on GitHub
# File tmp/rubies/ruby-2.6.10/lib/csv/parser.rb, line 21
def initialize(*args)
super
@keeps = []
end
No documentation available
Instance Methods
lib/csv/parser.rb
View on GitHub
# File tmp/rubies/ruby-2.6.10/lib/csv/parser.rb, line 26
def each_line(row_separator)
position = pos
rest.each_line(row_separator) do |line|
position += line.bytesize
self.pos = position
yield(line)
end
end
No documentation available
lib/csv/parser.rb
View on GitHub
# File tmp/rubies/ruby-2.6.10/lib/csv/parser.rb, line 44
def keep_back
self.pos = @keeps.pop
end
No documentation available
lib/csv/parser.rb
View on GitHub
# File tmp/rubies/ruby-2.6.10/lib/csv/parser.rb, line 48
def keep_drop
@keeps.pop
end
No documentation available
#
lib/csv/parser.rb
View on GitHub
# File tmp/rubies/ruby-2.6.10/lib/csv/parser.rb, line 39
def keep_end
start = @keeps.pop
string[start, pos - start]
end
No documentation available
lib/csv/parser.rb
View on GitHub
# File tmp/rubies/ruby-2.6.10/lib/csv/parser.rb, line 35
def keep_start
@keeps.push(pos)
end
No documentation available