Struct jsonrpc_pubsub::manager::NumericIdProvider
source · [−]pub struct NumericIdProvider { /* private fields */ }
Expand description
Provides a thread-safe incrementing integer which can be used as a subscription ID.
Implementations
sourceimpl NumericIdProvider
impl NumericIdProvider
sourcepub fn with_id(id: AtomicUsize) -> Self
pub fn with_id(id: AtomicUsize) -> Self
Create a new NumericIdProvider starting from the given ID.
Trait Implementations
sourceimpl Clone for NumericIdProvider
impl Clone for NumericIdProvider
sourcefn clone(&self) -> NumericIdProvider
fn clone(&self) -> NumericIdProvider
Returns a copy of the value. Read more
1.0.0 · sourcefn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from source
. Read more
sourceimpl Debug for NumericIdProvider
impl Debug for NumericIdProvider
sourceimpl Default for NumericIdProvider
impl Default for NumericIdProvider
sourceimpl IdProvider for NumericIdProvider
impl IdProvider for NumericIdProvider
Auto Trait Implementations
impl RefUnwindSafe for NumericIdProvider
impl Send for NumericIdProvider
impl Sync for NumericIdProvider
impl Unpin for NumericIdProvider
impl UnwindSafe for NumericIdProvider
Blanket Implementations
sourceimpl<T> BorrowMut<T> for T where
T: ?Sized,
impl<T> BorrowMut<T> for T where
T: ?Sized,
const: unstable · sourcepub fn borrow_mut(&mut self) -> &mut T
pub fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more
sourceimpl<T> ToOwned for T where
T: Clone,
impl<T> ToOwned for T where
T: Clone,
type Owned = T
type Owned = T
The resulting type after obtaining ownership.
sourcepub fn to_owned(&self) -> T
pub fn to_owned(&self) -> T
Creates owned data from borrowed data, usually by cloning. Read more
sourcepub fn clone_into(&self, target: &mut T)
pub fn clone_into(&self, target: &mut T)
🔬 This is a nightly-only experimental API. (
toowned_clone_into
)Uses borrowed data to replace owned data, usually by cloning. Read more