Struct intuicio_data::managed::ManagedLazy
source · pub struct ManagedLazy<T: ?Sized> { /* private fields */ }Implementations§
source§impl<T: ?Sized> ManagedLazy<T>
impl<T: ?Sized> ManagedLazy<T>
pub fn new(data: &T, lifetime: LifetimeLazy) -> Self
sourcepub unsafe fn new_raw(data: *const T, lifetime: LifetimeLazy) -> Self
pub unsafe fn new_raw(data: *const T, lifetime: LifetimeLazy) -> Self
§Safety
pub fn into_inner(self) -> (LifetimeLazy, NonNull<T>)
pub fn into_dynamic(self) -> DynamicManagedLazy
pub fn lifetime(&self) -> &LifetimeLazy
pub fn borrow(&self) -> Option<ManagedRef<T>>
pub fn borrow_mut(&self) -> Option<ManagedRefMut<T>>
pub fn read(&self) -> Option<ValueReadAccess<'_, T>>
pub fn write(&self) -> Option<ValueWriteAccess<'_, T>>
sourcepub unsafe fn try_map<U>(
self,
f: impl FnOnce(&mut T) -> Option<&mut U>
) -> Result<ManagedLazy<U>, Self>
pub unsafe fn try_map<U>( self, f: impl FnOnce(&mut T) -> Option<&mut U> ) -> Result<ManagedLazy<U>, Self>
§Safety
sourcepub unsafe fn as_mut_ptr(&self) -> Option<*mut T>
pub unsafe fn as_mut_ptr(&self) -> Option<*mut T>
§Safety
Trait Implementations§
source§impl<T: ?Sized> Clone for ManagedLazy<T>
impl<T: ?Sized> Clone for ManagedLazy<T>
source§impl<T> From<ManagedLazy<T>> for ManagedValue<T>
impl<T> From<ManagedLazy<T>> for ManagedValue<T>
source§fn from(value: ManagedLazy<T>) -> Self
fn from(value: ManagedLazy<T>) -> Self
Converts to this type from the input type.
source§impl<T> TryFrom<ManagedValue<T>> for ManagedLazy<T>
impl<T> TryFrom<ManagedValue<T>> for ManagedLazy<T>
impl<T> Send for ManagedLazy<T>
impl<T> Sync for ManagedLazy<T>
Auto Trait Implementations§
impl<T: ?Sized> RefUnwindSafe for ManagedLazy<T>where
T: RefUnwindSafe,
impl<T: ?Sized> Unpin for ManagedLazy<T>
impl<T: ?Sized> UnwindSafe for ManagedLazy<T>where
T: RefUnwindSafe,
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