class foxes.utils.DataBook[source]

Container class for file paths, either directly given or as static data within a package.

Parameters

data_book: DataBook, optional

A data book to start from

Attributes

dbase: dict

The data base. Key: context str, value: dict (file name str to pathlib.Path)

Public members

DataBook(data_book=None)[source]

Constructor.

add_data_package(context, package, file_sfx)[source]

Add static files from a package location.

add_data_package_file(context, package, file_name)[source]

Add a static file from a package location.

add_files(context, file_paths)[source]

Add file paths

add_file(context, file_path)[source]

Add a file path

get_file_path(context, file_name, check_raw=True, errors=True)[source]

Get path of a file

toc(context)[source]

Get list of contents