aea.decision_maker.messages.base

This module contains the base message and serialization definition.

InternalMessage

class InternalMessage()

This class implements a message.

__init__

 | __init__(body: Optional[Dict] = None, **kwargs)

Initialize a Message object.

Arguments:

  • body: the dictionary of values to hold.
  • kwargs: any additional value to add to the body. It will overwrite the body values.

body

 | @body.setter
 | body(body: Dict) -> None

Set the body of hte message.

Arguments:

  • body: the body.

Returns:

None

set

 | set(key: str, value: Any) -> None

Set key and value pair.

Arguments:

  • key: the key.
  • value: the value.

Returns:

None

get

 | get(key: str) -> Optional[Any]

Get value for key.

unset

 | unset(key: str) -> None

Unset value for key.

Arguments:

  • key: the key to unset the value of

is_set

 | is_set(key: str) -> bool

Check value is set for key.

Arguments:

  • key: the key to check

__eq__

 | __eq__(other)

Compare with another object.

__str__

 | __str__()

Get the string representation of the message.