Skip to content
instance method

StringScanner#eos?

() -> bool
eos? → true or false

Returns whether the position is at the end of the stored string:

Example
scanner = StringScanner.new('foobarbaz')
scanner.eos? # => false
pos = 3
scanner.eos? # => false
scanner.terminate
scanner.eos? # => true
See also #concat #exist? #check_until #fixed_anchor? also in 4.1 · 3.4 · 3.3 · 3.2 · 3.1 · 3.0