class_docstr: A Scanner is used to read tokens from a stream of characters
  using the token set specified by a Plex.Lexicon.
  
  Constructor:
  
    Scanner(lexicon, stream, name = '')
  
      See the docstring of the __init__ method for details.
  
  Methods:
  
    See the docstrings of the individual methods for more
    information.
  
    read() --> (value, text)
      Reads the next lexical token from the stream.
  
    position() --> (name, line, col)
      Returns the position of the last token read using the
      read() method.
  
    begin(state_name)
      Causes scanner to change state.
  
    produce(value [, text])
      Causes return of a token value to the caller of the
      Scanner.
docstr: Called from an action procedure, causes |value| to be returned
  as the token value from read(). If |text| is supplied, it is
  returned in place of the scanned text.
  
  produce() can be called more than once during a single call to an action
  procedure, in which case the tokens are queued up and returned one
  at a time by subsequent calls to read(), until the queue is empty,
  whereupon scanning resumes.
docstr_tok: ["Called","from","an","action","procedure",",","causes","|value|","to","be","returned","as","the","token","value","from","read","(",")",".","If","|text|","is","supplied",",","it","is","returned","in","place","of","the","scanned","text",".","produce","(",")","can","be","called","more","than","once","during","a","single","call","to","an","action","procedure",",","in","which","case","the","tokens","are","queued","up","and","returned","one","at","a","time","by","subsequent","calls","to","read","(",")",",","until","the","queue","is","empty",",","whereupon","scanning","resumes","."]
code: def produce(self, value, text=None):
      """
      Called from an action procedure, causes |value| to be returned
      as the token value from read(). If |text| is supplied, it is
      returned in place of the scanned text.
  
      produce() can be called more than once during a single call to an action
      procedure, in which case the tokens are queued up and returned one
      at a time by subsequent calls to read(), until the queue is empty,
      whereupon scanning resumes.
      """
      if text is None:
          text = self.text
      self.queue.append((value, text))
  
file_path: catboost/contrib/tools/cython/Cython/Plex/Scanners.py
imports: from __future__ import absolute_import
  import cython
  from .None import Errors
  from .Regexps import BOL, EOL, EOF
label_desc: Use image node_id 9 for calling the Scanner obj's underlying member method code with example usage: obj.produce(value, text) without return types