NSObject

NSObject Mac OS X 10.0

NSObject is the root class of the Cocoa frameworks. This class defines the base functionality that enables objects to work with the Objective-C runtime.

figs/cocn_1373.gif

@interface NSObject <NSObject>
 // Initializers
   - (id)init;
 // Class Methods
   + (id)alloc;
   + (id)allocWithZone:(NSZone *)zone;
   + (Class)class;
   + (BOOL)conformsToProtocol:(Protocol *)protocol;
   + (id)copyWithZone:(NSZone *)zone;
   + (NSString *)description;
   + (void)initialize;
   + (IMP)instanceMethodForSelector:(SEL)aSelector;
   + (NSMethodSignature *)instanceMethodSignatureForSelector:(SEL)aSelector;
   + (BOOL)instancesRespondToSelector:(SEL)aSelector;
   + (BOOL)isSubclassOfClass:(Class)aClass;
   + (void)load;
   + (id)mutableCopyWithZone:(NSZone *)zone;
   + (id)new;
   + (void)poseAsClass:(Class)aClass;
   + (void)setVersion:(int)aVersion;
   + (Class)superclass;
   + (int)version;
 // Instance Methods
   - (void)URL:(NSURL *)sender resourceDataDidBecomeAvailable:(NSData *)newBytes;
   - (void)URL:(NSURL *)sender resourceDidFailLoadingWithReason:(NSString *)reason;
   - (void)URLResourceDidCancelLoading:(NSURL *)sender;
   - (void)URLResourceDidFinishLoading:(NSURL *)sender;
   - (id)awakeAfterUsingCoder:(NSCoder *)aDecoder;
   - (unsigned long)classCode;
   - (Class)classForArchiver;
   - (Class)classForCoder;
   - (Class)classForKeyedArchiver;
   - (Class)classForPortCoder;
   - (NSString *)className;
   - (id)copy;
   - (void)dealloc;
   - (void)doesNotRecognizeSelector:(SEL)aSelector;
   - (void)forwardInvocation:(NSInvocation *)anInvocation;
   - (IMP)methodForSelector:(SEL)aSelector;
   - (NSMethodSignature *)methodSignatureForSelector:(SEL)aSelector;
   - (id)mutableCopy;
   - (void)performSelector:(SEL)aSelector withObject:(id)anArgument afterDelay:(NSTimeInterval)delay;
   - (void)performSelector:(SEL)aSelector withObject:(id)anArgument afterDelay:(NSTimeInterval)delay
        inModes:(NSArray *)modes;
   - (void)performSelectorOnMainThread:(SEL)aSelector withObject:(id)arg waitUntilDone:(BOOL)wait;
   - (void)performSelectorOnMainThread:(SEL)aSelector withObject:(id)arg waitUntilDone:(BOOL)wait
        modes:(NSArray *)array;
   - (id)replacementObjectForArchiver:(NSArchiver *)archiver;
   - (id)replacementObjectForCoder:(NSCoder *)aCoder;
   - (id)replacementObjectForKeyedArchiver:(NSKeyedArchiver *)archiver;
   - (id)replacementObjectForPortCoder:(NSPortCoder *)coder;
 // Methods Implementing NSObject
   - (BOOL)isEqual:(id)object;
   - (unsigned)hash;
   - (Class)superclass;
   - (Class)class;
   - (id)self;
   - (NSZone *)zone;
   - (id)performSelector:(SEL)aSelector;
   - (id)performSelector:(SEL)aSelector withObject:(id)object;
   - (id)performSelector:(SEL)aSelector withObject:(id)object1 withObject:(id)object2;
   - (BOOL)isProxy;
   - (BOOL)isKindOfClass:(Class)aClass;
   - (BOOL)isMemberOfClass:(Class)aClass;
   - (BOOL)conformsToProtocol:(Protocol *)aProtocol;
   - (BOOL)respondsToSelector:(SEL)aSelector;
   - (id)retain;
   - (oneway void)release;
   - (id)autorelease;
   - (unsigned)retainCount;
   - (NSString *)description;

Subclasses

NSObject is a root class.



    Part II: API Quick Reference
    Chapter 13. Foundation Classes