/external/libaom/libaom/tools/ |
wrap-commit-msg.py | 44 def main(fileobj): 48 line = fileobj.readline() 61 if fileobj == sys.stdin: 62 fileobj = sys.stdout 64 fileobj.seek(0) 65 fileobj.truncate(0) 66 fileobj.write(output)
|
/external/libvpx/libvpx/tools/ |
wrap-commit-msg.py | 42 def main(fileobj): 46 line = fileobj.readline() 59 if fileobj == sys.stdin: 60 fileobj = sys.stdout 62 fileobj.seek(0) 63 fileobj.truncate(0) 64 fileobj.write(output)
|
/device/linaro/bootloader/edk2/AppPkg/Applications/Python/Python-2.7.2/Lib/test/ |
test_csv.py | 122 fileobj = os.fdopen(fd, "w+b")
124 writer = csv.writer(fileobj, **kwargs)
126 fileobj.seek(0)
127 self.assertEqual(fileobj.read(),
130 fileobj.close()
199 fileobj = os.fdopen(fd, "w+b")
201 writer = csv.writer(fileobj)
204 fileobj.seek(0)
205 self.assertEqual(fileobj.read(), "a,b\r\nc,d\r\n")
207 fileobj.close() 375 fileobj = os.fdopen(fd, "w+b") variable in class:TestDialectRegistry.test_dialect_apply.testC 386 fileobj = os.fdopen(fd, "w+b") variable in class:TestDialectRegistry.test_dialect_apply.testC 397 fileobj = os.fdopen(fd, "w+b") variable in class:TestDialectRegistry.test_dialect_apply.testC 408 fileobj = os.fdopen(fd, "w+b") variable in class:TestDialectRegistry.test_dialect_apply.testC 419 fileobj = os.fdopen(fd, "w+b") variable in class:TestDialectRegistry.test_dialect_apply.testC [all...] |
/device/linaro/bootloader/edk2/AppPkg/Applications/Python/Python-2.7.2/Lib/ |
gzip.py | 46 compresslevel=9, fileobj=None, mtime=None):
49 At least one of fileobj and filename must be given a
52 The new class instance is based on fileobj, which can be a regular
57 When fileobj is not None, the filename argument is only used to be
60 fileobj, if discernible; otherwise, it defaults to the empty string,
65 is the mode of fileobj if discernible; otherwise, the default is 'rb'.
88 if fileobj is None:
89 fileobj = self.myfileobj = __builtin__.open(filename, mode or 'rb')
91 if hasattr(fileobj, 'name'): filename = fileobj.name [all...] |
tarfile.py | 260 """Copy length bytes from fileobj src to fileobj dst.
398 def __init__(self, name, mode, comptype, fileobj, bufsize):
402 if fileobj is None:
403 fileobj = _LowLevelFile(name, mode)
409 fileobj = _StreamProxy(fileobj)
410 comptype = fileobj.getcomptype()
415 self.fileobj = fileobj
[all...] |
/external/python/cpython2/Lib/ |
gzip.py | 46 compresslevel=9, fileobj=None, mtime=None): 49 At least one of fileobj and filename must be given a 52 The new class instance is based on fileobj, which can be a regular 57 When fileobj is not None, the filename argument is only used to be 60 fileobj, if discernible; otherwise, it defaults to the empty string, 65 is the mode of fileobj if discernible; otherwise, the default is 'rb'. 93 if fileobj is None: 94 fileobj = self.myfileobj = __builtin__.open(filename, mode or 'rb') 96 # Issue #13781: os.fdopen() creates a fileobj with a bogus name 98 filename = getattr(fileobj, 'name', '' [all...] |
tarfile.py | 260 """Copy length bytes from fileobj src to fileobj dst. 398 def __init__(self, name, mode, comptype, fileobj, bufsize): 402 if fileobj is None: 403 fileobj = _LowLevelFile(name, mode) 409 fileobj = _StreamProxy(fileobj) 410 comptype = fileobj.getcomptype() 415 self.fileobj = fileobj [all...] |
/external/python/cpython3/Lib/ |
selectors.py | 21 def _fileobj_to_fd(fileobj): 25 fileobj -- file object or file descriptor 33 if isinstance(fileobj, int): 34 fd = fileobj 37 fd = int(fileobj.fileno()) 40 "{!r}".format(fileobj)) from None 46 SelectorKey = namedtuple('SelectorKey', ['fileobj', 'fd', 'events', 'data']) 48 SelectorKey.__doc__ = """SelectorKey(fileobj, fd, events, data) 54 SelectorKey.fileobj.__doc__ = 'File object registered.' 69 def __getitem__(self, fileobj) [all...] |
gzip.py | 124 compresslevel=9, fileobj=None, mtime=None): 127 At least one of fileobj and filename must be given a 130 The new class instance is based on fileobj, which can be a regular 135 When fileobj is not None, the filename argument is only used to be 138 fileobj, if discernible; otherwise, it defaults to the empty string, 143 is the mode of fileobj if discernible; otherwise, the default is 'rb'. 162 if fileobj is None: 163 fileobj = self.myfileobj = builtins.open(filename, mode or 'rb') 165 filename = getattr(fileobj, 'name', '') 171 mode = getattr(fileobj, 'mode', 'rb' [all...] |
tarfile.py | 235 """Copy length bytes from fileobj src to fileobj dst. 345 def __init__(self, name, mode, comptype, fileobj, bufsize): 349 if fileobj is None: 350 fileobj = _LowLevelFile(name, mode) 356 fileobj = _StreamProxy(fileobj) 357 comptype = fileobj.getcomptype() 362 self.fileobj = fileobj [all...] |
/external/python/cpython3/Lib/test/ |
test_csv.py | 123 with TemporaryFile("w+", newline='') as fileobj: 124 writer = csv.writer(fileobj, **kwargs) 126 fileobj.seek(0) 127 self.assertEqual(fileobj.read(), 131 with TemporaryFile("w+", newline='') as fileobj: 132 writer = csv.writer(fileobj, **kwargs) 135 fileobj.seek(0) 136 self.assertEqual(fileobj.read(), '') 207 with TemporaryFile("w+", newline='') as fileobj: 208 writer = csv.writer(fileobj) [all...] |
test_gzip.py | 146 f = gzip.GzipFile(fileobj=io.BytesIO(compressed), mode='rb') 156 fileobj = f.fileobj 157 self.assertFalse(fileobj.closed) 159 self.assertTrue(fileobj.closed) 168 fileobj = f.fileobj 169 self.assertFalse(fileobj.closed) 171 self.assertTrue(fileobj.closed) 302 self.assertTrue(hasattr(f.fileobj, "name") [all...] |
/external/python/cpython2/Lib/test/ |
test_csv.py | 124 fileobj = os.fdopen(fd, "w+b") 126 writer = csv.writer(fileobj, **kwargs) 128 fileobj.seek(0) 129 self.assertEqual(fileobj.read(), 132 fileobj.close() 137 fileobj = os.fdopen(fd, "w+b") 139 writer = csv.writer(fileobj, **kwargs) 142 fileobj.seek(0) 143 self.assertEqual(fileobj.read(), '') 145 fileobj.close( 406 fileobj = os.fdopen(fd, "w+b") variable in class:TestDialectRegistry.test_dialect_apply.testC 417 fileobj = os.fdopen(fd, "w+b") variable in class:TestDialectRegistry.test_dialect_apply.testC 428 fileobj = os.fdopen(fd, "w+b") variable in class:TestDialectRegistry.test_dialect_apply.testC 439 fileobj = os.fdopen(fd, "w+b") variable in class:TestDialectRegistry.test_dialect_apply.testC 450 fileobj = os.fdopen(fd, "w+b") variable in class:TestDialectRegistry.test_dialect_apply.testC [all...] |
test_gzip.py | 56 gzip.GzipFile(fileobj=fobj, mode="rb") as f: 328 # Issue #13781: Creating a GzipFile using a fileobj from os.fdopen() 332 with gzip.GzipFile(fileobj=f, mode="w") as g: 338 with gzip.GzipFile(fileobj=f, mode="w") as g: 344 with gzip.GzipFile(fileobj=f, mode='r') as g: 346 with gzip.GzipFile(fileobj=f, mode='w') as g: 348 with gzip.GzipFile(fileobj=f, mode='a') as g: 351 gzip.GzipFile(fileobj=f, mode='z') 354 with gzip.GzipFile(fileobj=f) as g: 358 with gzip.GzipFile(fileobj=f) as g [all...] |
/external/python/cpython3/Tools/tz/ |
zdump.py | 18 def fromfile(cls, fileobj): 19 if fileobj.read(4).decode() != "TZif": 21 fileobj.seek(20) 22 header = fileobj.read(24) 26 transitions.fromfile(fileobj, tzh_timecnt) 31 type_indices.fromfile(fileobj, tzh_timecnt) 35 ttis.append(ttinfo._make(struct.unpack(">lbb", fileobj.read(6)))) 37 abbrs = fileobj.read(tzh_charcnt) 79 with open(filepath, 'rb') as fileobj: 80 tzi = TZInfo.fromfile(fileobj) [all...] |
/external/python/apitools/ |
setup.py | 58 with open('README.rst') as fileobj: 59 README = fileobj.read()
|
/external/python/cpython2/Lib/plat-mac/ |
applesingle.py | 51 def __init__(self, fileobj, verbose=False): 52 header = fileobj.read(AS_HEADER_LENGTH) 67 headers = [fileobj.read(AS_ENTRY_LENGTH) for i in xrange(nentry)] 76 fileobj.seek(offset) 77 data = fileobj.read(length)
|
/external/libkmsxx/py/tests/ |
db.py | 76 def readdrm(fileobj, mask): 83 def readkey(fileobj, mask): 96 callback(key.fileobj, mask)
|
modeset_event.py | 7 def readdrm(fileobj, mask): 17 key.data(key.fileobj, mask)
|
/external/python/dateutil/dateutil/tz/ |
tz.py | 379 :param fileobj: 385 information in the event that ``fileobj`` is a file object. If omitted 386 and ``fileobj`` is a file stream, this parameter will be set either to 387 ``fileobj``'s ``name`` attribute or to ``repr(fileobj)``. 396 def __init__(self, fileobj, filename=None): 400 if isinstance(fileobj, string_types): 401 self._filename = fileobj 402 fileobj = open(fileobj, 'rb' [all...] |
/device/linaro/bootloader/edk2/AppPkg/Applications/Python/Python-2.7.10/Objects/ |
moduleobject.c | 83 PyObject *fileobj;
local 90 (fileobj = PyDict_GetItemString(d, "__file__")) == NULL ||
91 !PyString_Check(fileobj))
96 return PyString_AsString(fileobj);
|
/device/linaro/bootloader/edk2/AppPkg/Applications/Python/Python-2.7.2/Objects/ |
moduleobject.c | 83 PyObject *fileobj;
local 90 (fileobj = PyDict_GetItemString(d, "__file__")) == NULL ||
91 !PyString_Check(fileobj))
96 return PyString_AsString(fileobj);
|
/external/python/cpython2/Objects/ |
moduleobject.c | 83 PyObject *fileobj; local 90 (fileobj = PyDict_GetItemString(d, "__file__")) == NULL || 91 !PyString_Check(fileobj)) 96 return PyString_AsString(fileobj);
|
/external/autotest/client/bin/ |
test_config.py | 107 fileobj = file(self.cfg, 'w') 109 self.parser.write(fileobj) 111 fileobj.close()
|
/external/jsoncpp/scons-tools/ |
targz.py | 44 fileobj = gzip.GzipFile( target_path, 'wb', compression ) 45 tar = tarfile.TarFile(os.path.splitext(target_path)[0], 'w', fileobj)
|