Skip to content

BaseComponent

BaseComponent

BaseComponent(cfg: dict)

Methods:

  • load

    Load a Component configuration from dict.

  • stringify_class

    Return a JSON-friendly representation of a value.

load

load(cfg: dict[str, Any]) -> None

Load a Component configuration from dict.

Parameters:

  • cfg

    (dict[str, Any]) –

    dict from JSON configuration .

Returns:

  • BaseConfig ( None ) –

    Instance initialized with the loaded configuration.

stringify_class classmethod

stringify_class(value: Any) -> Any

Return a JSON-friendly representation of a value.

Parameters:

  • value

    (Any) –

    Object to convert.

Returns:

  • Any

    A value that can be serialized by :mod:json.