FileCabinetReader

class wwt_data_formats.filecabinet.FileCabinetReader(stream)[source]

Bases: object

Reader for a simple container format for other files.

Unlike most of the other WWT data formats implemented in this package, the file cabinet is not an XML serialization of a data structure. Instead, it’s a container format for bundling files together.

Methods Summary

close()

Close the underlying stream, making this object essentially unusable.

filenames()

Return an iterable of the names of the files in this cabinet.

read_file(filename)

Read the specified file into memory in its entirety and return its contents.

Methods Documentation

close()[source]

Close the underlying stream, making this object essentially unusable.

filenames()[source]

Return an iterable of the names of the files in this cabinet.

read_file(filename)[source]

Read the specified file into memory in its entirety and return its contents.

Returns bytes.