pub struct DynamicManagedRefMut { /* private fields */ }
Implementations§
Source§impl DynamicManagedRefMut
impl DynamicManagedRefMut
pub fn new<T: ?Sized>(data: &mut T, lifetime: LifetimeRefMut) -> Self
Sourcepub unsafe fn new_raw(
type_hash: TypeHash,
lifetime: LifetimeRefMut,
data: *mut u8,
) -> Option<Self>
pub unsafe fn new_raw( type_hash: TypeHash, lifetime: LifetimeRefMut, data: *mut u8, ) -> Option<Self>
§Safety
pub fn make<T: ?Sized>(data: &mut T) -> (Self, Lifetime)
pub fn into_inner(self) -> (TypeHash, LifetimeRefMut, *mut u8)
pub fn into_typed<T>(self) -> Result<ManagedRefMut<T>, Self>
pub fn type_hash(&self) -> &TypeHash
pub fn lifetime(&self) -> &LifetimeRefMut
pub fn borrow(&self) -> Option<DynamicManagedRef>
pub fn borrow_mut(&mut self) -> Option<DynamicManagedRefMut>
pub fn is<T>(&self) -> bool
pub fn read<T>(&self) -> Option<ValueReadAccess<'_, T>>
pub fn write<T>(&mut self) -> Option<ValueWriteAccess<'_, T>>
Sourcepub unsafe fn try_map<T, U>(
self,
f: impl FnOnce(&mut T) -> Option<&mut U>,
) -> Option<Self>
pub unsafe fn try_map<T, U>( self, f: impl FnOnce(&mut T) -> Option<&mut U>, ) -> Option<Self>
§Safety
Sourcepub unsafe fn as_mut_ptr<T>(&mut self) -> Option<*mut T>
pub unsafe fn as_mut_ptr<T>(&mut self) -> Option<*mut T>
§Safety
Trait Implementations§
Source§impl From<DynamicManagedRefMut> for DynamicManagedValue
impl From<DynamicManagedRefMut> for DynamicManagedValue
Source§fn from(value: DynamicManagedRefMut) -> Self
fn from(value: DynamicManagedRefMut) -> Self
Converts to this type from the input type.
impl Send for DynamicManagedRefMut
impl Sync for DynamicManagedRefMut
Auto Trait Implementations§
impl Freeze for DynamicManagedRefMut
impl RefUnwindSafe for DynamicManagedRefMut
impl Unpin for DynamicManagedRefMut
impl UnwindSafe for DynamicManagedRefMut
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