Lines Matching refs:stream
191 useful for extensions that filter a stream.
277 """The iterator for tokenstreams. Iterate over the stream
281 def __init__(self, stream):
282 self.stream = stream
288 token = self.stream.current
290 self.stream.close()
292 next(self.stream)
298 """A token stream is an iterable that yields :class:`Token`\\s. The
319 eos = property(lambda x: not x, doc="Are we at the end of the stream?")
322 """Push a token back to the stream."""
365 """Close the stream."""
553 """Calls tokeniter + tokenize and wraps it in a token stream.
555 stream = self.tokeniter(source, name, filename, state)
556 return TokenStream(self.wrap(stream, name, filename), name, filename)
558 def wrap(self, stream, name=None, filename=None):
559 """This is called with the stream as returned by `tokenize` and wraps
562 for lineno, token, value in stream: