class Cannonbol::Len

Public Instance Methods

__match?(needle, thread_state = nil) click to toggle source
# File lib/cannonbol/cannonbol.rb, line 340
def __match?(needle, thread_state = nil)

  if thread_state
    needle.pull(thread_state)
  else
    len_temp = len(needle)
    [needle.push(len_temp)] if needle.remaining_string.length >= len_temp
  end

end