Struct wasmer::LazyInit [−][src]
pub struct LazyInit<T: Sized> { /* fields omitted */ }
Expand description
Lazily init an item
Implementations
impl<T> LazyInit<T>
[src]
impl<T> LazyInit<T>
[src]pub unsafe fn get_unchecked(&self) -> &T
[src]
pub unsafe fn get_unchecked(&self) -> &T
[src]Safety
- The data must be initialized first
pub fn initialize(&mut self, value: T) -> bool
[src]
pub fn initialize(&mut self, value: T) -> bool
[src]Sets a value and marks the data as initialized.
Trait Implementations
impl<T: Send> Send for LazyInit<T>
[src]
Auto Trait Implementations
impl<T> RefUnwindSafe for LazyInit<T> where
T: RefUnwindSafe,
T: RefUnwindSafe,
impl<T> Sync for LazyInit<T> where
T: Sync,
T: Sync,
impl<T> Unpin for LazyInit<T> where
T: Unpin,
T: Unpin,
impl<T> UnwindSafe for LazyInit<T> where
T: UnwindSafe,
T: UnwindSafe,
Blanket Implementations
impl<T> ArchivePointee for T
impl<T> ArchivePointee for T
type ArchivedMetadata = ()
type ArchivedMetadata = ()
The archived version of the pointer metadata for this type.
pub fn pointer_metadata(
&<T as ArchivePointee>::ArchivedMetadata
) -> <T as Pointee>::Metadata
pub fn pointer_metadata(
&<T as ArchivePointee>::ArchivedMetadata
) -> <T as Pointee>::Metadata
Converts some archived metadata to the pointer metadata for itself.
impl<T> BorrowMut<T> for T where
T: ?Sized,
[src]
impl<T> BorrowMut<T> for T where
T: ?Sized,
[src]pub fn borrow_mut(&mut self) -> &mut T
[src]
pub fn borrow_mut(&mut self) -> &mut T
[src]Mutably borrows from an owned value. Read more
impl<T> Instrument for T
[src]
impl<T> Instrument for T
[src]fn instrument(self, span: Span) -> Instrumented<Self>
[src]
fn instrument(self, span: Span) -> Instrumented<Self>
[src]Instruments this type with the provided Span
, returning an
Instrumented
wrapper. Read more
fn in_current_span(self) -> Instrumented<Self>
[src]
fn in_current_span(self) -> Instrumented<Self>
[src]impl<T> Pointable for T
impl<T> Pointable for T
impl<T> ToOwned for T where
T: Clone,
[src]
impl<T> ToOwned for T where
T: Clone,
[src]type Owned = T
type Owned = T
The resulting type after obtaining ownership.
pub fn to_owned(&self) -> T
[src]
pub fn to_owned(&self) -> T
[src]Creates owned data from borrowed data, usually by cloning. Read more
pub fn clone_into(&self, target: &mut T)
[src]
pub fn clone_into(&self, target: &mut T)
[src]🔬 This is a nightly-only experimental API. (toowned_clone_into
)
recently added
Uses borrowed data to replace owned data, usually by cloning. Read more