pub struct ServerlessWriterLease {
pub database_key: String,
pub holder_id: String,
pub term: u64,
pub generation: u64,
pub acquired_at_ms: u64,
pub expires_at_ms: u64,
}Fields§
§database_key: String§holder_id: String§term: u64§generation: u64§acquired_at_ms: u64§expires_at_ms: u64Implementations§
Source§impl ServerlessWriterLease
impl ServerlessWriterLease
pub fn is_expired(&self, now_ms: u64) -> bool
pub fn fenced_by_term(&self, current_term: u64) -> bool
pub fn fencing_token(&self) -> (u64, u64)
Trait Implementations§
Source§impl Clone for ServerlessWriterLease
impl Clone for ServerlessWriterLease
Source§fn clone(&self) -> ServerlessWriterLease
fn clone(&self) -> ServerlessWriterLease
Returns a duplicate of the value. Read more
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreSource§impl Debug for ServerlessWriterLease
impl Debug for ServerlessWriterLease
impl Eq for ServerlessWriterLease
Source§impl PartialEq for ServerlessWriterLease
impl PartialEq for ServerlessWriterLease
Source§fn eq(&self, other: &ServerlessWriterLease) -> bool
fn eq(&self, other: &ServerlessWriterLease) -> bool
Tests for
self and other values to be equal, and is used by ==.impl StructuralPartialEq for ServerlessWriterLease
Auto Trait Implementations§
impl Freeze for ServerlessWriterLease
impl RefUnwindSafe for ServerlessWriterLease
impl Send for ServerlessWriterLease
impl Sync for ServerlessWriterLease
impl Unpin for ServerlessWriterLease
impl UnsafeUnpin for ServerlessWriterLease
impl UnwindSafe for ServerlessWriterLease
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