Struct eventstore::Handle [−][src]
pub struct Handle { /* fields omitted */ }
A Handle to a running client. Handle
basically exposes the same
functions of Client
minus shutdown
.
Methods
impl Handle
[src]
impl Handle
pub fn write_events<S>(&self, stream: S) -> WriteEvents where
S: Into<Chars>,
[src]
pub fn write_events<S>(&self, stream: S) -> WriteEvents where
S: Into<Chars>,
Sends events to a given stream.
pub fn write_stream_metadata<S>(
&self,
stream: S,
metadata: StreamMetadata
) -> WriteStreamMetadata where
S: Into<Chars>,
[src]
pub fn write_stream_metadata<S>(
&self,
stream: S,
metadata: StreamMetadata
) -> WriteStreamMetadata where
S: Into<Chars>,
Sets the metadata for a stream.
pub fn read_event<S>(&self, stream: S, event_number: i64) -> ReadEvent where
S: Into<Chars>,
[src]
pub fn read_event<S>(&self, stream: S, event_number: i64) -> ReadEvent where
S: Into<Chars>,
Reads a single event from a given stream.
pub fn read_stream_metadata<S>(&self, stream: S) -> ReadStreamMetadata where
S: Into<Chars>,
[src]
pub fn read_stream_metadata<S>(&self, stream: S) -> ReadStreamMetadata where
S: Into<Chars>,
Gets the metadata of a stream.
pub fn start_transaction<S>(&self, stream: S) -> TransactionStart where
S: Into<Chars>,
[src]
pub fn start_transaction<S>(&self, stream: S) -> TransactionStart where
S: Into<Chars>,
Starts a transaction on a given stream.
pub fn read_stream<S>(&self, stream: S) -> ReadStreamEvents where
S: Into<Chars>,
[src]
pub fn read_stream<S>(&self, stream: S) -> ReadStreamEvents where
S: Into<Chars>,
Reads events from a given stream. The reading can be done forward and backward.
pub fn read_all(&self) -> ReadAllEvents
[src]
pub fn read_all(&self) -> ReadAllEvents
Reads events for the system stream $all
. The reading can be done
forward and backward.
pub fn delete_stream<S>(&self, stream: S) -> DeleteStream where
S: Into<Chars>,
[src]
pub fn delete_stream<S>(&self, stream: S) -> DeleteStream where
S: Into<Chars>,
Deletes a given stream. By default, the server performs a soft delete, More information can be found on the [Deleting streams and events] page.
pub fn subcribe_to_stream<S>(&self, stream_id: S) -> SubscribeToStream where
S: Into<Chars>,
[src]
pub fn subcribe_to_stream<S>(&self, stream_id: S) -> SubscribeToStream where
S: Into<Chars>,
Subscribes to a given stream. You will get notified of each new events written to this stream.
pub fn subscribe_to_stream_from<S>(&self, stream: S) -> RegularCatchupSubscribe where
S: Into<Chars>,
[src]
pub fn subscribe_to_stream_from<S>(&self, stream: S) -> RegularCatchupSubscribe where
S: Into<Chars>,
Subscribes to a given stream. This kind of subscription specifies a
starting point (by default, the beginning of a stream). For a regular
stream, that starting point will be an event number. For the system
stream $all
, it will be a position in the transaction file
(see subscribe_to_all_from
). This subscription will fetch every event
until the end of the stream, then will dispatch subsequently written
events.
For example, if a starting point of 50 is specified when a stream has 100 events in it, the subscriber can expect to see events 51 through 100, and then any events subsequenttly written events until such time as the subscription is dropped or closed.
pub fn subscribe_to_all_from(&self) -> AllCatchupSubscribe
[src]
pub fn subscribe_to_all_from(&self) -> AllCatchupSubscribe
Like subscribe_to_stream_from
but specific to system $all
stream.
pub fn create_persistent_subscription<S>(
&self,
stream_id: S,
group_name: S
) -> CreatePersistentSubscription where
S: Into<Chars>,
[src]
pub fn create_persistent_subscription<S>(
&self,
stream_id: S,
group_name: S
) -> CreatePersistentSubscription where
S: Into<Chars>,
Creates a persistent subscription group on a stream.
Persistent subscriptions are special kind of subscription where the server remembers the state of the subscription. This allows for many different modes of operations compared to a regular or catchup subscription where the client holds the subscription state.
pub fn update_persistent_subscription<S>(
&self,
stream_id: S,
group_name: S
) -> UpdatePersistentSubscription where
S: Into<Chars>,
[src]
pub fn update_persistent_subscription<S>(
&self,
stream_id: S,
group_name: S
) -> UpdatePersistentSubscription where
S: Into<Chars>,
Updates a persistent subscription group on a stream.
pub fn delete_persistent_subscription<S>(
&self,
stream_id: S,
group_name: S
) -> DeletePersistentSubscription where
S: Into<Chars>,
[src]
pub fn delete_persistent_subscription<S>(
&self,
stream_id: S,
group_name: S
) -> DeletePersistentSubscription where
S: Into<Chars>,
Deletes a persistent subscription group on a stream.
pub fn connect_persistent_subscription<S>(
&self,
stream_id: S,
group_name: S
) -> ConnectToPersistentSubscription where
S: Into<Chars>,
[src]
pub fn connect_persistent_subscription<S>(
&self,
stream_id: S,
group_name: S
) -> ConnectToPersistentSubscription where
S: Into<Chars>,
Connects to a persistent subscription group on a stream.