eventstoredb#

Subpackages#

Submodules#

Package Contents#

Classes#

Client

Base class for protocol classes.

class eventstoredb.Client(options)[source]#

Bases: eventstoredb.client.read_stream.mixin.ReadStreamMixin, eventstoredb.client.append_to_stream.mixin.AppendToStreamMixin, eventstoredb.client.subscribe_to_stream.mixin.SubscribeToStreamMixin, eventstoredb.client.read_all.mixin.ReadAllMixin, eventstoredb.client.subscribe_to_all.mixin.SubscribeToAllMixin, eventstoredb.client.create_persistent_subscription_to_stream.mixin.CreatePersistentSubscriptionToStreamMixin, eventstoredb.client.update_persistent_subscription_to_stream.mixin.UpdatePersistentSubscriptionToStreamMixin, eventstoredb.client.delete_persistent_subscription_to_stream.mixin.DeletePersistentSubscriptionToStreamMixin, eventstoredb.client.subscribe_to_persistent_subscription_to_stream.mixin.SubscribeToPersistentSubscriptionToStreamMixin, eventstoredb.client.create_persistent_subscription_to_all.mixin.CreatePersistentSubscriptionToAllMixin, eventstoredb.client.update_persistent_subscription_to_all.mixin.UpdatePersistentSubscriptionToAllMixin, eventstoredb.client.delete_persistent_subscription_to_all.mixin.DeletePersistentSubscriptionToAllMixin, eventstoredb.client.get_persistent_subscription_details.mixin.GetPersistentSubscriptionDetailsMixin, eventstoredb.client.subscribe_to_persistent_subscription_to_all.mixin.SubscribeToPersistentSubscriptionToAllMixin

Base class for protocol classes.

Protocol classes are defined as:

class Proto(Protocol):
    def meth(self) -> int:
        ...

Such classes are primarily used with static type checkers that recognize structural subtyping (static duck-typing).

For example:

class C:
    def meth(self) -> int:
        return 0

def func(x: Proto) -> int:
    return x.meth()

func(C())  # Passes static type check

See PEP 544 for details. Protocol classes decorated with @typing.runtime_checkable act as simple-minded runtime protocols that check only the presence of given attributes, ignoring their type signatures. Protocol classes can be generic, they are defined as:

class GenProto[T](Protocol):
    def meth(self) -> T:
        ...
Parameters:

options (eventstoredb.client.types.ClientOptions | str) –

property channel: grpclib.client.Channel#
Return type:

grpclib.client.Channel