parameters: (self, source, name=None, filename=None)
docstring: Lex the given sourcecode and return a generator that yields
          tokens as tuples in the form ``(lineno, token_type, value)``.
          This can be useful for :ref:`extension development <writing-extensions>`
          and debugging templates.
  
          This does not perform preprocessing.  If you want the preprocessing
          of the extensions to be applied you have to filter source through
          the :meth:`preprocess` method.
docstring_summary: Lex the given sourcecode and return a generator that yields
          tokens as tuples in the form ``(lineno, token_type, value)``.
          This can be useful for :ref:`extension development <writing-extensions>`
          and debugging templates.
docstring_tokens: Lex the given sourcecode and return a generator that yields tokens as tuples in the form ( lineno token_type value ) . This can be useful for : ref : extension development <writing - extensions > and debugging templates .
function: def lex(self, source, name=None, filename=None):
          """Lex the given sourcecode and return a generator that yields
          tokens as tuples in the form ``(lineno, token_type, value)``.
          This can be useful for :ref:`extension development <writing-extensions>`
          and debugging templates.
  
          This does not perform preprocessing.  If you want the preprocessing
          of the extensions to be applied you have to filter source through
          the :meth:`preprocess` method.
          """
          source = text_type(source)
          try:
              return self.lexer.tokeniter(source, name, filename)
          except TemplateSyntaxError:
              exc_info = sys.exc_info()
          self.handle_exception(exc_info, source_hint=source)
function_tokens: def lex ( self , source , name = None , filename = None ) : source = text_type ( source ) try : return self . lexer . tokeniter ( source , name , filename ) except TemplateSyntaxError : exc_info = sys . exc_info ( ) self . handle_exception ( exc_info , source_hint = source )