Skip to content

MessageStateStore

Sub classes

Name Children Inherits
InMemoryMessageStateStore
aclientp.task.state
In-memory implementation of MessageStateStore.

Base classes

Name Children Inherits
Protocol
typing
Base class for protocol classes.

⋔ Inheritance diagram

graph TD
  95970860557536["state.MessageStateStore"]
  95970836711072["typing.Protocol"]
  95970835676112["typing.Generic"]
  125067848591872["builtins.object"]
  95970836711072 --> 95970860557536
  95970835676112 --> 95970836711072
  125067848591872 --> 95970835676112

🛈 DocStrings

Bases: Protocol

Protocol for managing message states.

Source code in src/aclientp/task/state.py
class MessageStateStore(Protocol):
    """Protocol for managing message states."""

    def register_outgoing(self, request_id: int, method: str) -> asyncio.Future[Any]: ...

    def resolve_outgoing(self, request_id: int, result: Any) -> None: ...

    def reject_outgoing(self, request_id: int, error: RequestError) -> None: ...

    def reject_all_outgoing(self, error: BaseException) -> None: ...

    def begin_incoming(self, method: str, params: Any) -> IncomingMessage: ...

    def complete_incoming(self, record: IncomingMessage, result: Any) -> None: ...

    def fail_incoming(self, record: IncomingMessage, error: Exception) -> None: ...

:fa-brands-github: Show source on GitHub