pub struct NamespacedState { /* private fields */ }Expand description
A namespaced view over a shared state backend. Use one namespace per workflow instance so identical branch/key names cannot collide.
Implementations§
Trait Implementations§
Source§impl State for NamespacedState
impl State for NamespacedState
Source§fn append<'life0, 'life1, 'async_trait>(
&'life0 self,
key: &'life1 str,
item: Value,
max_len: Option<usize>,
ttl: Option<Duration>,
) -> Pin<Box<dyn Future<Output = ()> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
fn append<'life0, 'life1, 'async_trait>(
&'life0 self,
key: &'life1 str,
item: Value,
max_len: Option<usize>,
ttl: Option<Duration>,
) -> Pin<Box<dyn Future<Output = ()> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
Append
item to the list at key, keeping at most max_len entries
(oldest dropped first). Creates the list if absent. ttl bounds the
key’s lifetime.Auto Trait Implementations§
impl !RefUnwindSafe for NamespacedState
impl !UnwindSafe for NamespacedState
impl Freeze for NamespacedState
impl Send for NamespacedState
impl Sync for NamespacedState
impl Unpin for NamespacedState
impl UnsafeUnpin for NamespacedState
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