Struct QObjectMutPtr
pub struct QObjectMutPtr(/* private fields */);Expand description
A thin wrapper around *mut QObject.
Using the ‘newtype’ idiom lets us implement ExternType
for it, which wouldn’t be possible for pure *mut QObject itself.
Implementations§
§impl QObjectMutPtr
impl QObjectMutPtr
pub unsafe fn from_raw(raw: *mut QObject) -> QObjectMutPtr
pub unsafe fn from_raw(raw: *mut QObject) -> QObjectMutPtr
Create a new instance from a raw pointer.
§Safety
The pointer is passed to C++ as a QObject* and may be dereferenced
there. This wrapper tracks neither ownership nor lifetime,
so the object must outlive every use of the underlying QObject pointer
(including any copy stored in a QVariant or QList).
pub fn as_mut_ptr(&self) -> *mut QObject
pub fn as_mut_ptr(&self) -> *mut QObject
Return a wrapped raw mut pointer.
Trait Implementations§
§impl Clone for QObjectMutPtr
impl Clone for QObjectMutPtr
§fn clone(&self) -> QObjectMutPtr
fn clone(&self) -> QObjectMutPtr
Returns a duplicate of the value. Read more
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read more§impl Debug for QObjectMutPtr
impl Debug for QObjectMutPtr
§impl ExternType for QObjectMutPtr
impl ExternType for QObjectMutPtr
§impl PartialEq for QObjectMutPtr
impl PartialEq for QObjectMutPtr
§impl QListElement for QObjectMutPtr
impl QListElement for QObjectMutPtr
type TypeId = (Q, L, i, s, t, __, Q, O, b, j, e, c, t, M, u, t, P, t, r)
fn append(list: &mut QList<QObjectMutPtr>, value: QObjectMutPtr)
fn append_clone(list: &mut QList<QObjectMutPtr>, value: &QObjectMutPtr)
fn clear(list: &mut QList<QObjectMutPtr>)
fn clone(list: &QList<QObjectMutPtr>) -> QList<QObjectMutPtr>
fn contains(list: &QList<QObjectMutPtr>, value: &QObjectMutPtr) -> bool
fn default() -> QList<QObjectMutPtr>
fn drop(list: &mut QList<QObjectMutPtr>)
§unsafe fn get_unchecked(
list: &QList<QObjectMutPtr>,
pos: isize,
) -> &QObjectMutPtr
unsafe fn get_unchecked( list: &QList<QObjectMutPtr>, pos: isize, ) -> &QObjectMutPtr
Safety Read more
fn index_of(list: &QList<QObjectMutPtr>, value: &QObjectMutPtr) -> isize
fn insert(list: &mut QList<QObjectMutPtr>, pos: isize, value: QObjectMutPtr)
fn insert_clone( list: &mut QList<QObjectMutPtr>, pos: isize, value: &QObjectMutPtr, )
fn len(list: &QList<QObjectMutPtr>) -> isize
fn remove(list: &mut QList<QObjectMutPtr>, pos: isize)
fn reserve(list: &mut QList<QObjectMutPtr>, size: isize)
§impl QVariantValue for QObjectMutPtr
impl QVariantValue for QObjectMutPtr
fn can_convert(variant: &QVariant) -> bool
fn construct(value: &QObjectMutPtr) -> QVariant
fn value_or_default(variant: &QVariant) -> QObjectMutPtr
impl Copy for QObjectMutPtr
impl Eq for QObjectMutPtr
impl StructuralPartialEq for QObjectMutPtr
Auto Trait Implementations§
impl Freeze for QObjectMutPtr
impl RefUnwindSafe for QObjectMutPtr
impl !Send for QObjectMutPtr
impl !Sync for QObjectMutPtr
impl Unpin for QObjectMutPtr
impl UnsafeUnpin for QObjectMutPtr
impl UnwindSafe for QObjectMutPtr
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