AFL.automation.mixing.MixDB#

Functions

abstractmethod(funcobj)

A decorator indicating abstract methods.

Classes

ABC()

Helper class that provides a standard way to create an ABC using inheritance.

DBEngine()

MixDB([db_spec])

Pandas_DBEngine(dataframe)

PersistentConfig(path[, defaults, ...])

A dictionary-like class that serializes changes to disk

PersistentConfig_DBEngine(config_path)

Exceptions

NotFoundErr(*args, **kw)

NotFoundError

class AFL.automation.mixing.MixDB.MixDB(db_spec: str | Path | DataFrame | None = None)[source]#
__init__(db_spec: str | Path | DataFrame | None = None)[source]#
set_db()[source]#
static get_db()[source]#

Retrieve the global _MIXDB instance.

Raises:

ValueError – If _MIXDB is not set.

Returns:

The _MIXDB instance.

add_component(component_dict: Dict) str[source]#
remove_component(name=None, uid=None)[source]#
list_components()[source]#
update_component(component_dict: Dict) str[source]#
get_component(name=None, uid=None, interactive=True)[source]#
add_component_interactive(name, uid=None)[source]#
write()[source]#
class AFL.automation.mixing.MixDB.DBEngine[source]#
abstract add_component(component_dict: Dict) str[source]#
abstract update_component(component_dict: Dict) str[source]#
abstract remove_component(name=None, uid=None)[source]#
abstract list_components()[source]#
abstract get_component(name=None, uid=None)[source]#
abstract write(filename, writer='json')[source]#
class AFL.automation.mixing.MixDB.Pandas_DBEngine(dataframe: DataFrame)[source]#
__init__(dataframe: DataFrame)[source]#
static read_csv(db_spec)[source]#
static read_json(db_spec)[source]#
write(filename: str, writer: str = 'json') None[source]#
add_component(component_dict: Dict) str[source]#
update_component(component_dict: Dict) str[source]#
remove_component(name=None, uid=None)[source]#
list_components()[source]#
get_component(name=None, uid=None) Dict[source]#
class AFL.automation.mixing.MixDB.PersistentConfig_DBEngine(config_path: str)[source]#
__init__(config_path: str)[source]#
add_component(component_dict: Dict) str[source]#
update_component(component_dict: Dict) str[source]#
remove_component(name=None, uid=None)[source]#
list_components()[source]#
get_component(name=None, uid=None) Dict[source]#
write(filename: str, writer: str = 'json') None[source]#