rocketpal.core.library module

class rocketpal.core.library.Library(library_folder)[source]

Bases: ABC

Parameters:

library_folder (Path)

entries: dict[str, LibraryEntry]
get(id)[source]

Returns the library entry with the given id, or None if it does not exist.

Parameters:

id (str) – The id of the library entry to retrieve.

Returns:

The library entry with the given id, or None if it does not exist.

Return type:

LibraryEntry | None

library_folder: Path
abstractmethod load_entry(data)[source]
Parameters:

data (dict)

Return type:

LibraryEntry

abstractmethod new_entry()[source]
Return type:

LibraryEntry

reload()[source]

Reloads the library entries from the library folder.

Return type:

None

save()[source]

Saves the library entries to the library folder.

Return type:

None