aea.components.base
This module contains definitions of agent components.
Component Objects
class Component(ABC, WithLogger)
Abstract class for an agent component.
__
init__
| __init__(configuration: Optional[ComponentConfiguration] = None, is_vendor: bool = False, **kwargs: Any, ,) -> None
Initialize a package.
Arguments:
configuration
: the package configuration.is_vendor
: whether the package is vendorized.
component_
type
| @property
| component_type() -> ComponentType
Get the component type.
is_
vendor
| @property
| is_vendor() -> bool
Get whether the component is vendorized or not.
prefix_
import_
path
| @property
| prefix_import_path() -> str
Get the prefix import path for this component.
component_
id
| @property
| component_id() -> ComponentId
Ge the package id.
public_
id
| @property
| public_id() -> PublicId
Get the public id.
configuration
| @property
| configuration() -> ComponentConfiguration
Get the component configuration.
directory
| @property
| directory() -> Path
Get the directory. Raise error if it has not been set yet.
directory
| @directory.setter
| directory(path: Path) -> None
Set the directory. Raise error if already set.
build_
directory
| @property
| build_directory() -> Optional[str]
Get build directory for the component.
load_
aea_
package
load_aea_package(configuration: ComponentConfiguration) -> None
Load the AEA package.
It adds all the init.py modules into sys.modules
.
Arguments:
configuration
: the configuration object.
Returns:
None