#[repr(C)]pub struct NSObject<'data>(_);
Expand description
An instance of the root class for most Objective-C objects.
See documentation.
Implementations
sourceimpl<'data> NSObject<'data>
impl<'data> NSObject<'data>
sourcepub fn retain_count(&self) -> usize
pub fn retain_count(&self) -> usize
Returns this object’s reference count.
This method is only useful for debugging certain objects.
See documentation.
sourcepub fn responds_to_selector(&self, selector: Sel) -> bool
pub fn responds_to_selector(&self, selector: Sel) -> bool
Returns true
if this object implements or inherits a method that can
respond to a specified message.
See documentation.
sourcepub fn is_kind_of_class(&self, class: &Class) -> bool
pub fn is_kind_of_class(&self, class: &Class) -> bool
Returns true
if this object is an instance or subclass of class
.
See documentation
sourcepub fn is_member_of_class(&self, class: &Class) -> bool
pub fn is_member_of_class(&self, class: &Class) -> bool
Returns true
if this object is an instance of class
.
See documentation
sourcepub fn hash(&self) -> NSUInteger
pub fn hash(&self) -> NSUInteger
Returns an integer that can be used as a table address in a hash table structure.
See documentation.
sourcepub fn copy(&self) -> Arc<Self>
pub fn copy(&self) -> Arc<Self>
Returns a copy of this object using
NSCopying
.
See documentation.
sourcepub fn mutable_copy(&self) -> Arc<Self>
pub fn mutable_copy(&self) -> Arc<Self>
Returns a copy of this object using
NSMutableCopying
.
See documentation.
sourcepub fn description(&self) -> Arc<NSString<'static>>
pub fn description(&self) -> Arc<NSString<'static>>
Returns a string that describes the contents of this object.
See documentation
sourcepub fn debug_description(&self) -> Arc<NSString<'static>>
pub fn debug_description(&self) -> Arc<NSString<'static>>
Returns a string that describes the contents of the receiver for presentation in the debugger.
See documentation
Trait Implementations
sourceimpl<'data> AsMut<NSErrorRecoveryAttempting<'data>> for NSObject<'data>
impl<'data> AsMut<NSErrorRecoveryAttempting<'data>> for NSObject<'data>
sourcefn as_mut(&mut self) -> &mut NSErrorRecoveryAttempting<'data>
fn as_mut(&mut self) -> &mut NSErrorRecoveryAttempting<'data>
Converts this type into a mutable reference of the (usually inferred) input type.
sourceimpl<'data, T> AsMut<T> for NSObject<'data> where
ObjCObject<'data>: AsMut<T>,
impl<'data, T> AsMut<T> for NSObject<'data> where
ObjCObject<'data>: AsMut<T>,
sourceimpl<'data> AsRef<NSErrorRecoveryAttempting<'data>> for NSObject<'data>
impl<'data> AsRef<NSErrorRecoveryAttempting<'data>> for NSObject<'data>
sourcefn as_ref(&self) -> &NSErrorRecoveryAttempting<'data>
fn as_ref(&self) -> &NSErrorRecoveryAttempting<'data>
Converts this type into a shared reference of the (usually inferred) input type.
sourceimpl<'data, T> AsRef<T> for NSObject<'data> where
ObjCObject<'data>: AsRef<T>,
impl<'data, T> AsRef<T> for NSObject<'data> where
ObjCObject<'data>: AsRef<T>,
sourceimpl<'data> Deref for NSObject<'data>
impl<'data> Deref for NSObject<'data>
type Target = ObjCObject<'data>
type Target = ObjCObject<'data>
The resulting type after dereferencing.
sourceimpl<'data> ObjectType for NSObject<'data>
impl<'data> ObjectType for NSObject<'data>
sourceimpl<'data> ObjectType<'data> for NSObject<'data>
impl<'data> ObjectType<'data> for NSObject<'data>
sourcefn as_objc_object(&self) -> &ObjCObject<'data>
fn as_objc_object(&self) -> &ObjCObject<'data>
Casts self
into a type-erased Objective-C object.
sourceimpl<'data> PartialEq<NSErrorRecoveryAttempting<'data>> for NSObject<'data> where
NSObject<'data>: PartialEq,
impl<'data> PartialEq<NSErrorRecoveryAttempting<'data>> for NSObject<'data> where
NSObject<'data>: PartialEq,
Auto Trait Implementations
impl<'data> RefUnwindSafe for NSObject<'data>
impl<'data> Send for NSObject<'data>
impl<'data> Sync for NSObject<'data>
impl<'data> Unpin for NSObject<'data>
impl<'data> UnwindSafe for NSObject<'data>
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