Skip to content
Myr

remove unused IteratorProxy

Before adoption: this commit came in with the history the project adopted, so no landing records it.

authored by Josh Schneier · committed by Josh Schneier · parent a7c2184 · Browse files · 1 file+0 added−23 removed
This commit

State

Before adoption: this commit came in with the history the project adopted, so no landing records it.

Diff stats

1 file+0 added−23 removed

  • other:+0 added−23 removed

1 file+0 added−23 removed

modified:requests/structures.py-23 removed
6 unmodified lines
7Data structures that power Requests.89"""1011import os11import collections13from itertools import islice121316class IteratorProxy(object):17 """docstring for IteratorProxy"""18 def __init__(self, i):19 self.i = i20 # self.i = chain.from_iterable(i)2122 def __iter__(self):23 return self.i2425 def __len__(self):26 if hasattr(self.i, '__len__'):27 return len(self.i)28 if hasattr(self.i, 'len'):29 return self.i.len30 if hasattr(self.i, 'fileno'):31 return os.fstat(self.i.fileno()).st_size3233 def read(self, n):34 return "".join(islice(self.i, None, n))353614class CaseInsensitiveDict(collections.MutableMapping):15 """16 A case-insensitive ``dict``-like object.17
87 unmodified lines