def available(self):
"""
This is duplicate functionality if we have a HighPerformanceStreamIO.
But we also want to support those that aren't. TODO: Better solution?
"""
curPos = self._stream.tell()
self._stream.seek(0, SEEK_END)
endPos = self._stream.tell()
self._stream.seek(curPos)
return endPos-curPos
评论列表
文章目录