Struct glib::subclass::ObjectImplRef
source · pub struct ObjectImplRef<T: ObjectSubclass>(T::Type);
Expand description
Reference-counted wrapper around an ObjectSubclass
reference.
This can be used for passing into closures as strong or weak reference without manually going from the implementation type to the instance type and back.
Tuple Fields§
§0: T::Type
Implementations§
source§impl<T: ObjectSubclass> ObjectImplRef<T>
impl<T: ObjectSubclass> ObjectImplRef<T>
sourcepub fn downgrade(&self) -> ObjectImplWeakRef<T>
pub fn downgrade(&self) -> ObjectImplWeakRef<T>
Downgrade to a weak reference.
This can be upgraded to a strong reference again via ObjectImplWeakRef::upgrade
.
Trait Implementations§
source§impl<T: ObjectSubclass> Clone for ObjectImplRef<T>
impl<T: ObjectSubclass> Clone for ObjectImplRef<T>
source§impl<T: ObjectSubclass> Debug for ObjectImplRef<T>
impl<T: ObjectSubclass> Debug for ObjectImplRef<T>
source§impl<T: ObjectSubclass> Deref for ObjectImplRef<T>
impl<T: ObjectSubclass> Deref for ObjectImplRef<T>
source§impl<T: ObjectSubclass> Downgrade for ObjectImplRef<T>
impl<T: ObjectSubclass> Downgrade for ObjectImplRef<T>
source§impl<T: ObjectSubclass> Hash for ObjectImplRef<T>
impl<T: ObjectSubclass> Hash for ObjectImplRef<T>
source§impl<T: ObjectSubclass> Ord for ObjectImplRef<T>
impl<T: ObjectSubclass> Ord for ObjectImplRef<T>
source§impl<T: ObjectSubclass, OT: ObjectType> PartialEq<OT> for ObjectImplRef<T>
impl<T: ObjectSubclass, OT: ObjectType> PartialEq<OT> for ObjectImplRef<T>
source§impl<T: ObjectSubclass> PartialEq for ObjectImplRef<T>
impl<T: ObjectSubclass> PartialEq for ObjectImplRef<T>
source§impl<T: ObjectSubclass, OT: ObjectType> PartialOrd<OT> for ObjectImplRef<T>where
T::Type: PartialOrd<OT>,
impl<T: ObjectSubclass, OT: ObjectType> PartialOrd<OT> for ObjectImplRef<T>where
T::Type: PartialOrd<OT>,
source§impl<T: ObjectSubclass> PartialOrd for ObjectImplRef<T>
impl<T: ObjectSubclass> PartialOrd for ObjectImplRef<T>
impl<T: ObjectSubclass> Eq for ObjectImplRef<T>
impl<T: ObjectSubclass + Send + Sync> Send for ObjectImplRef<T>
impl<T: ObjectSubclass + Send + Sync> Sync for ObjectImplRef<T>
Auto Trait Implementations§
impl<T> Freeze for ObjectImplRef<T>
impl<T> RefUnwindSafe for ObjectImplRef<T>
impl<T> Unpin for ObjectImplRef<T>
impl<T> UnwindSafe for ObjectImplRef<T>
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
source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
source§unsafe fn clone_to_uninit(&self, dst: *mut T)
unsafe fn clone_to_uninit(&self, dst: *mut T)
🔬This is a nightly-only experimental API. (
clone_to_uninit
)