fabio.fabioutils.BZ2File

Package fabio :: Module fabioutils :: Class BZ2File |
[hide private]
[frames] | no frames]

# Class BZ2File

source code

     object --+
              |
    bz2.BZ2File --+
                  |
                 BZ2File

Wrapper with lock

Instance Methods | [hide private]
file object |
__init__(name, mode='r', buffering=0, compresslevel=9) Open a bz2 file. | source code
getSize(self) | source code
setSize(self, value) | source code
Inherited from `bz2.BZ2File`: `__delattr__`, `__getattribute__`, `__iter__`, `__new__`, `__setattr__`, `close`, `next`, `read`, `readline`, `readlines`, `seek`, `tell`, `write`, `writelines`, `xreadlines` Inherited from `object`: `__format__`, `__hash__`, `__reduce__`, `__reduce_ex__`, `__repr__`, `__sizeof__`, `__str__`, `__subclasshook__`

Properties | [hide private]
| size
Inherited from `bz2.BZ2File`: `closed`, `mode`, `name`, `newlines`, `softspace` Inherited from `object`: `__class__`

Method Details | [hide private]

### __init__(name, mode='r', buffering=0, compresslevel=9) (Constructor) | source code
                Open a bz2 file. The mode can be 'r' or 'w', for reading (default) or
                writing. When opened for writing, the file will be created if it doesn't
                exist, and truncated otherwise. If the buffering argument is given, 0 means
                unbuffered, and larger numbers specify the buffer size. If compresslevel
                is given, must be a number between 1 and 9.

                Add a 'U' to mode to open the file for input with universal newline
                support. Any line ending in the input file will be seen as a '
    ' in
                Python. Also, a file so opened gains the attribute 'newlines'; the value
                for this attribute is one of None (no newline read yet), '
    ', '
    ',
                '
    ' or a tuple containing all the newline types seen. Universal
                newlines are available only when reading.
Returns: file object Overrides: object.__init__

Property Details | [hide private]

### size Get Method: getSize(self) Set Method: setSize(self, value)