pub enum ActorMessage {
Get(String),
Set {
key: String,
value: usize,
expiry: Duration,
},
Update {
key: String,
value: usize,
},
Expire(String),
Remove(String),
}Expand description
Represents message that can be handled by a StoreActor
Variants§
Get(String)
Get the remaining count based on the provided identifier
Set
Set the count of the client identified by key to value valid for expiry
Update
Change the value of count for the client identified by key by value
Expire(String)
Get the expiration time for the client.
Remove(String)
Remove the client from the store
Trait Implementations§
Source§impl Handler<ActorMessage> for MemcacheStoreActor
impl Handler<ActorMessage> for MemcacheStoreActor
Source§impl Handler<ActorMessage> for MemoryStoreActor
impl Handler<ActorMessage> for MemoryStoreActor
Source§impl Handler<ActorMessage> for RedisStoreActor
impl Handler<ActorMessage> for RedisStoreActor
Source§impl Message for ActorMessage
impl Message for ActorMessage
Source§type Result = ActorResponse
type Result = ActorResponse
The type of value that this message will resolved with if it is
successful.
Auto Trait Implementations§
impl Freeze for ActorMessage
impl RefUnwindSafe for ActorMessage
impl Send for ActorMessage
impl Sync for ActorMessage
impl Unpin for ActorMessage
impl UnwindSafe for ActorMessage
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more
Source§impl<T> Instrument for T
impl<T> Instrument for T
Source§fn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
Source§fn in_current_span(self) -> Instrumented<Self>
fn in_current_span(self) -> Instrumented<Self>
Source§impl<T> Instrument for T
impl<T> Instrument for T
Source§fn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
Source§fn in_current_span(self) -> Instrumented<Self>
fn in_current_span(self) -> Instrumented<Self>
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self>
fn into_either(self, into_left: bool) -> Either<Self, Self>
Converts
self into a Left variant of Either<Self, Self>
if into_left is true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
Converts
self into a Left variant of Either<Self, Self>
if into_left(&self) returns true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read more