class documentation

class ExplodingFile:

View In Hierarchy

A file-alike which raises exceptions from its I/O methods and keeps track of whether it has been closed.

Method __enter__ Undocumented
Method __exit__ Undocumented
Method close Mark the file as having been closed.
Method read No summary
Method write No summary
Instance Variable closed A bool which is False until close is called, then it is True.
def __enter__(self) -> ExplodingFile:

Undocumented

def __exit__(self, exc_type: object, exc_value: object, traceback: object):

Undocumented

def close(self):

Mark the file as having been closed.

def read(self, n: int = 0) -> NoReturn:
Raises
IOErrorAlways raised.
def write(self, what: bytes) -> NoReturn:
Raises
IOErrorAlways raised.
closed: bool =

A bool which is False until close is called, then it is True.