#[repr(transparent)]pub struct Shared<T, MM: SharedMemoryManager<T>> { /* private fields */ }
Expand description
Encapsulates memory management logic for shared types.
Trait Implementations
sourceimpl<T, MM: SharedMemoryManager<T>> Clone for Shared<T, MM>
impl<T, MM: SharedMemoryManager<T>> Clone for Shared<T, MM>
sourceimpl<T, MM: SharedMemoryManager<T>> Debug for Shared<T, MM>
impl<T, MM: SharedMemoryManager<T>> Debug for Shared<T, MM>
sourceimpl<T, MM: SharedMemoryManager<T>> Drop for Shared<T, MM>
impl<T, MM: SharedMemoryManager<T>> Drop for Shared<T, MM>
sourceimpl<T: 'static, MM: SharedMemoryManager<T>> FromGlibPtrBorrow<*mut T> for Shared<T, MM>
impl<T: 'static, MM: SharedMemoryManager<T>> FromGlibPtrBorrow<*mut T> for Shared<T, MM>
sourceunsafe fn from_glib_borrow(ptr: *mut T) -> Borrowed<Self>
unsafe fn from_glib_borrow(ptr: *mut T) -> Borrowed<Self>
Safety Read more
sourceimpl<T: 'static, MM: SharedMemoryManager<T>> FromGlibPtrFull<*mut T> for Shared<T, MM>
impl<T: 'static, MM: SharedMemoryManager<T>> FromGlibPtrFull<*mut T> for Shared<T, MM>
sourceunsafe fn from_glib_full(ptr: *mut T) -> Self
unsafe fn from_glib_full(ptr: *mut T) -> Self
Safety Read more
sourceimpl<T: 'static, MM: SharedMemoryManager<T>> FromGlibPtrNone<*const T> for Shared<T, MM>
impl<T: 'static, MM: SharedMemoryManager<T>> FromGlibPtrNone<*const T> for Shared<T, MM>
sourceunsafe fn from_glib_none(ptr: *const T) -> Self
unsafe fn from_glib_none(ptr: *const T) -> Self
Safety Read more
sourceimpl<T: 'static, MM: SharedMemoryManager<T>> FromGlibPtrNone<*mut T> for Shared<T, MM>
impl<T: 'static, MM: SharedMemoryManager<T>> FromGlibPtrNone<*mut T> for Shared<T, MM>
sourceunsafe fn from_glib_none(ptr: *mut T) -> Self
unsafe fn from_glib_none(ptr: *mut T) -> Self
Safety Read more
sourceimpl<T, MM: SharedMemoryManager<T>> Hash for Shared<T, MM>
impl<T, MM: SharedMemoryManager<T>> Hash for Shared<T, MM>
sourceimpl<T, MM: SharedMemoryManager<T>> Ord for Shared<T, MM>
impl<T, MM: SharedMemoryManager<T>> Ord for Shared<T, MM>
sourcefn partial_cmp(&self, other: &Self) -> Option<Ordering>
fn partial_cmp(&self, other: &Self) -> Option<Ordering>
This method returns an ordering between self
and other
values if one exists. Read more
1.0.0 · sourcefn lt(&self, other: &Rhs) -> bool
fn lt(&self, other: &Rhs) -> bool
This method tests less than (for self
and other
) and is used by the <
operator. Read more
1.0.0 · sourcefn le(&self, other: &Rhs) -> bool
fn le(&self, other: &Rhs) -> bool
This method tests less than or equal to (for self
and other
) and is used by the <=
operator. Read more
sourceimpl<'a, T: 'static, MM> ToGlibPtr<'a, *mut T> for Shared<T, MM> where
MM: SharedMemoryManager<T> + 'static,
impl<'a, T: 'static, MM> ToGlibPtr<'a, *mut T> for Shared<T, MM> where
MM: SharedMemoryManager<T> + 'static,
type Storage = &'a Self
sourcefn to_glib_none(&'a self) -> Stash<'a, *mut T, Self>
fn to_glib_none(&'a self) -> Stash<'a, *mut T, Self>
Transfer: none. Read more
sourcefn to_glib_full(&self) -> *mut T
fn to_glib_full(&self) -> *mut T
Transfer: full. Read more
sourcefn to_glib_container(&'a self) -> Stash<'a, P, Self>
fn to_glib_container(&'a self) -> Stash<'a, P, Self>
Transfer: container. Read more
impl<T, MM: SharedMemoryManager<T>> Eq for Shared<T, MM>
Auto Trait Implementations
impl<T, MM> RefUnwindSafe for Shared<T, MM> where
MM: RefUnwindSafe,
T: RefUnwindSafe,
impl<T, MM> !Send for Shared<T, MM>
impl<T, MM> !Sync for Shared<T, MM>
impl<T, MM> Unpin for Shared<T, MM>
impl<T, MM> UnwindSafe for Shared<T, MM> where
MM: RefUnwindSafe,
T: RefUnwindSafe,
Blanket Implementations
sourceimpl<T> BorrowMut<T> for T where
T: ?Sized,
impl<T> BorrowMut<T> for T where
T: ?Sized,
const: unstable · sourcefn borrow_mut(&mut self) -> &mut T
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.
sourcefn clone_into(&self, target: &mut T)
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