2020-03-03 06:24:41 +00:00
|
|
|
#include <Object.h>
|
|
|
|
#include <AutoreleasePool.h>
|
2022-09-09 05:03:30 +00:00
|
|
|
#include <string.h>
|
2002-08-14 15:40:30 +00:00
|
|
|
|
2020-03-09 10:09:08 +00:00
|
|
|
static void link__obj_forward (void)
|
|
|
|
{
|
|
|
|
__obj_forward (nil, nil);
|
|
|
|
}
|
|
|
|
|
2012-11-15 04:40:11 +00:00
|
|
|
void *PR_FindGlobal (string name) = #0; //FIXME where?
|
|
|
|
|
2012-11-12 02:12:33 +00:00
|
|
|
void __obj_exec_class (struct obj_module *msg) = #0;
|
2020-03-09 15:09:46 +00:00
|
|
|
BOOL __obj_responds_to(id obj, SEL sel) = #0;
|
2011-03-25 07:46:32 +00:00
|
|
|
void (id object, int code, string fmt, ...) obj_error = #0;
|
|
|
|
void (id object, int code, string fmt, @va_list args) obj_verror = #0;
|
2022-01-23 12:54:03 +00:00
|
|
|
//obj_error_handler obj_set_error_handler (objc_error_handler func) = #0;
|
2002-08-14 15:40:30 +00:00
|
|
|
IMP (id receiver, SEL op) obj_msg_lookup = #0;
|
2003-05-15 05:58:31 +00:00
|
|
|
IMP (Super class, SEL op) obj_msg_lookup_super = #0;
|
2002-08-14 15:40:30 +00:00
|
|
|
id (id receiver, SEL op, ...) obj_msgSend = #0;
|
2011-02-13 10:07:30 +00:00
|
|
|
id obj_msgSend_super (Super *class, SEL op, ...) = #0;
|
2022-02-05 10:13:46 +00:00
|
|
|
@attribute(void_return) void obj_msg_sendv (id receiver, SEL op, @va_list args) = #0;
|
2012-11-08 11:24:25 +00:00
|
|
|
int obj_decrement_retaincount (id object) = #0;
|
|
|
|
int obj_increment_retaincount (id object) = #0;
|
|
|
|
int obj_get_retaincount (id object) = #0;
|
2011-03-25 07:46:32 +00:00
|
|
|
void *obj_malloc (int size) = #0;
|
|
|
|
void *obj_atomic_malloc (int size) = #0;
|
|
|
|
void *obj_valloc (int size) = #0;
|
|
|
|
void *obj_realloc (void *mem, int size) = #0;
|
|
|
|
void *obj_calloc (int nelem, int size) = #0;
|
2011-02-13 10:07:30 +00:00
|
|
|
void obj_free (void *mem) = #0;
|
2022-01-23 12:54:03 +00:00
|
|
|
void *obj_get_uninstalled_dtable (void) = #0;
|
2002-08-14 15:40:30 +00:00
|
|
|
|
2022-01-23 12:54:03 +00:00
|
|
|
Class obj_get_class (string name) = #0;
|
|
|
|
Class obj_lookup_class (string name) = #0;
|
|
|
|
Class obj_next_class (void **enum_stage) = #0;
|
2002-08-14 15:40:30 +00:00
|
|
|
|
|
|
|
string (SEL selector) sel_get_name = #0;
|
|
|
|
string (SEL selector) sel_get_type = #0;
|
|
|
|
SEL (string name) sel_get_uid = #0;
|
2003-08-23 06:12:10 +00:00
|
|
|
//SEL (string name) sel_get_any_uid = #0;
|
|
|
|
//SEL (string name) sel_get_any_typed_uid = #0;
|
|
|
|
//SEL (string name, string type) sel_get_typed_uid = #0;
|
2002-08-14 15:40:30 +00:00
|
|
|
SEL (string name) sel_register_name = #0;
|
2003-08-23 06:12:10 +00:00
|
|
|
//SEL (string name, string type) sel_register_typed_name = #0;
|
2002-08-14 15:40:30 +00:00
|
|
|
BOOL (SEL aSel) sel_is_mapped = #0;
|
|
|
|
|
2011-02-07 13:16:16 +00:00
|
|
|
Method *class_get_class_method (Class class, SEL aSel) = #0;
|
|
|
|
Method *class_get_instance_method (Class class, SEL aSel) = #0;
|
2002-08-14 15:40:30 +00:00
|
|
|
Class (Class imposter, Class superclass) class_pose_as = #0;
|
|
|
|
id (Class class) class_create_instance = #0;
|
|
|
|
string (Class class) class_get_class_name = #0;
|
2011-03-25 07:46:32 +00:00
|
|
|
int (Class class) class_get_instance_size = #0;
|
2002-08-14 15:40:30 +00:00
|
|
|
Class (Class class) class_get_meta_class = #0;
|
|
|
|
Class (Class class) class_get_super_class = #0;
|
2011-03-25 07:46:32 +00:00
|
|
|
int (Class class) class_get_version = #0;
|
2002-08-14 15:40:30 +00:00
|
|
|
BOOL (Class class) class_is_class = #0;
|
|
|
|
BOOL (Class class) class_is_meta_class = #0;
|
2011-03-25 07:46:32 +00:00
|
|
|
void (Class class, int version) class_set_version = #0;
|
2011-02-07 13:16:16 +00:00
|
|
|
void *class_get_gc_object_type (Class class) = #0;
|
2002-08-14 15:40:30 +00:00
|
|
|
void (Class class, string ivarname, BOOL gcInvisible) class_ivar_set_gcinvisible = #0;
|
|
|
|
|
2011-02-13 10:07:30 +00:00
|
|
|
IMP method_get_imp (Method *method) = #0;
|
2002-08-14 15:40:30 +00:00
|
|
|
IMP (Class class, SEL sel) get_imp = #0;
|
|
|
|
|
|
|
|
id (id object) object_copy = #0;
|
|
|
|
id (id object) object_dispose = #0;
|
|
|
|
Class (id object) object_get_class = #0;
|
|
|
|
string (id object) object_get_class_name = #0;
|
|
|
|
Class (id object) object_get_meta_class = #0;
|
|
|
|
Class (id object) object_get_super_class = #0;
|
|
|
|
BOOL (id object) object_is_class = #0;
|
|
|
|
BOOL (id object) object_is_instance = #0;
|
|
|
|
BOOL (id object) object_is_meta_class = #0;
|
|
|
|
|
2003-07-29 18:02:03 +00:00
|
|
|
@implementation Object (error)
|
2002-08-14 15:40:30 +00:00
|
|
|
|
2003-07-29 18:02:03 +00:00
|
|
|
- (void) error: (string)aString, ... = #0;
|
2002-08-14 15:40:30 +00:00
|
|
|
|
2003-07-29 18:02:03 +00:00
|
|
|
@end
|
|
|
|
|
2022-01-31 14:37:03 +00:00
|
|
|
typedef void arIMP(id, SEL, id);
|
|
|
|
|
2010-11-22 04:26:23 +00:00
|
|
|
@static BOOL allocDebug;
|
|
|
|
@static Class autoreleaseClass;
|
|
|
|
@static SEL autoreleaseSelector;
|
2022-01-31 14:37:03 +00:00
|
|
|
@static arIMP autoreleaseIMP;
|
2010-11-22 04:26:23 +00:00
|
|
|
|
2003-07-29 18:02:03 +00:00
|
|
|
@implementation Object
|
|
|
|
|
|
|
|
+ (void) initialize
|
2002-08-14 15:40:30 +00:00
|
|
|
{
|
2010-11-22 04:26:23 +00:00
|
|
|
//allocDebug = localinfo ("AllocDebug");
|
2003-07-29 18:02:03 +00:00
|
|
|
autoreleaseClass = [AutoreleasePool class];
|
|
|
|
autoreleaseSelector = @selector(addObject:);
|
2022-01-31 14:37:03 +00:00
|
|
|
autoreleaseIMP = (arIMP)[autoreleaseClass methodForSelector: autoreleaseSelector];
|
2003-07-29 18:02:03 +00:00
|
|
|
return;
|
2002-08-14 15:40:30 +00:00
|
|
|
}
|
|
|
|
|
2003-07-29 18:02:03 +00:00
|
|
|
+ (id) alloc
|
2002-08-14 15:40:30 +00:00
|
|
|
{
|
|
|
|
return class_create_instance (self);
|
|
|
|
}
|
|
|
|
|
2003-07-29 18:02:03 +00:00
|
|
|
+ (Class) class
|
2002-08-14 15:40:30 +00:00
|
|
|
{
|
2003-07-29 18:02:03 +00:00
|
|
|
return self;
|
2002-08-14 15:40:30 +00:00
|
|
|
}
|
|
|
|
|
2003-07-29 18:02:03 +00:00
|
|
|
+ (Class) superclass
|
2002-08-14 15:40:30 +00:00
|
|
|
{
|
2003-07-29 18:02:03 +00:00
|
|
|
return class_get_super_class (self);
|
2002-08-14 15:40:30 +00:00
|
|
|
}
|
|
|
|
|
2003-07-29 18:02:03 +00:00
|
|
|
+ (string) description
|
2002-08-14 15:40:30 +00:00
|
|
|
{
|
2003-07-29 18:02:03 +00:00
|
|
|
return class_get_class_name (self);
|
2002-08-14 15:40:30 +00:00
|
|
|
}
|
|
|
|
|
2003-07-29 18:02:03 +00:00
|
|
|
+ (id) new
|
2002-08-14 15:40:30 +00:00
|
|
|
{
|
2003-07-29 18:02:03 +00:00
|
|
|
return [[self alloc] init];
|
2002-08-14 15:40:30 +00:00
|
|
|
}
|
|
|
|
|
2003-07-29 18:02:03 +00:00
|
|
|
+ (BOOL) isKindOfClass: (Class)aClass
|
2002-08-14 15:40:30 +00:00
|
|
|
{
|
2003-07-29 18:02:03 +00:00
|
|
|
if (aClass == [Object class])
|
|
|
|
return YES;
|
|
|
|
return NO;
|
2002-08-14 15:40:30 +00:00
|
|
|
}
|
|
|
|
|
2011-03-10 11:51:04 +00:00
|
|
|
+ (BOOL) conformsToProtocol: (Protocol *)aProtocol = #0;
|
2003-07-29 18:02:03 +00:00
|
|
|
|
|
|
|
+ (BOOL) instancesRespondToSelector: (SEL)aSelector
|
2002-08-14 15:40:30 +00:00
|
|
|
{
|
2011-01-14 03:07:40 +00:00
|
|
|
return class_get_instance_method (self, aSelector) != nil;
|
2002-08-14 15:40:30 +00:00
|
|
|
}
|
|
|
|
|
2003-07-29 18:02:03 +00:00
|
|
|
+ (BOOL) respondsToSelector: (SEL)aSelector
|
2002-08-14 15:40:30 +00:00
|
|
|
{
|
2011-01-14 03:07:40 +00:00
|
|
|
return (class_get_class_method (self, aSelector) != nil);
|
2002-08-14 15:40:30 +00:00
|
|
|
}
|
|
|
|
|
2003-07-29 18:02:03 +00:00
|
|
|
/*
|
|
|
|
Returns a pointer to the function providing the instance method that is
|
|
|
|
used to respond to messages with the selector held in aSelector.
|
|
|
|
*/
|
|
|
|
+ (IMP) instanceMethodForSelector: (SEL)aSelector
|
2002-08-14 15:40:30 +00:00
|
|
|
{
|
2003-07-29 18:02:03 +00:00
|
|
|
if (!aSelector)
|
2011-01-14 03:07:40 +00:00
|
|
|
return nil;
|
2003-07-29 18:02:03 +00:00
|
|
|
|
|
|
|
return method_get_imp (class_get_instance_method (self, aSelector));
|
2002-08-14 15:40:30 +00:00
|
|
|
}
|
|
|
|
|
2003-07-29 18:02:03 +00:00
|
|
|
+ (void) poseAsClass: (Class)aClass
|
2002-08-14 15:40:30 +00:00
|
|
|
{
|
2003-07-29 18:02:03 +00:00
|
|
|
class_pose_as (self, aClass);
|
2002-08-14 15:40:30 +00:00
|
|
|
}
|
|
|
|
|
2003-07-29 18:02:03 +00:00
|
|
|
/*
|
|
|
|
INSTANCE METHODS
|
|
|
|
*/
|
|
|
|
|
|
|
|
- (id) init
|
2002-08-14 15:40:30 +00:00
|
|
|
{
|
2012-11-14 11:45:29 +00:00
|
|
|
obj_increment_retaincount (self);
|
2002-08-14 15:40:30 +00:00
|
|
|
return self;
|
|
|
|
}
|
|
|
|
|
2003-07-29 18:02:03 +00:00
|
|
|
- (void) dealloc
|
2002-08-14 15:40:30 +00:00
|
|
|
{
|
2003-07-29 18:02:03 +00:00
|
|
|
object_dispose (self);
|
2002-08-14 15:40:30 +00:00
|
|
|
}
|
|
|
|
|
2003-07-29 18:02:03 +00:00
|
|
|
- (Class) class
|
2002-08-14 15:40:30 +00:00
|
|
|
{
|
2003-07-29 18:02:03 +00:00
|
|
|
return object_get_class (self);
|
2002-08-14 15:40:30 +00:00
|
|
|
}
|
|
|
|
|
2003-07-29 18:02:03 +00:00
|
|
|
- (Class) superclass
|
2002-08-14 15:40:30 +00:00
|
|
|
{
|
2003-07-29 18:02:03 +00:00
|
|
|
return object_get_super_class (self);
|
2002-08-14 15:40:30 +00:00
|
|
|
}
|
|
|
|
|
2003-07-29 18:02:03 +00:00
|
|
|
- (string) description
|
2002-08-14 15:40:30 +00:00
|
|
|
{
|
2003-07-29 18:02:03 +00:00
|
|
|
return object_get_class_name (self);
|
2002-08-14 15:40:30 +00:00
|
|
|
}
|
|
|
|
|
2003-07-29 18:02:03 +00:00
|
|
|
- (id) self
|
2002-08-14 15:40:30 +00:00
|
|
|
{
|
2003-07-29 18:02:03 +00:00
|
|
|
return self;
|
2002-08-14 15:40:30 +00:00
|
|
|
}
|
|
|
|
|
2011-03-25 07:46:32 +00:00
|
|
|
- (unsigned) hash = #0; // can't cast pointer to int
|
2003-07-29 18:02:03 +00:00
|
|
|
|
|
|
|
- (BOOL) isEqual: (id)anObject
|
2002-08-14 15:40:30 +00:00
|
|
|
{
|
2003-07-29 18:02:03 +00:00
|
|
|
return self == anObject;
|
2002-08-14 15:40:30 +00:00
|
|
|
}
|
|
|
|
|
2003-07-29 18:02:03 +00:00
|
|
|
- (BOOL) isKindOfClass: (Class)aClass
|
2002-08-14 15:40:30 +00:00
|
|
|
{
|
2003-07-29 18:02:03 +00:00
|
|
|
local Class class;
|
|
|
|
|
|
|
|
for (class = [self class]; class; class = class_get_super_class (class))
|
|
|
|
if (class == aClass)
|
|
|
|
return YES;
|
2002-08-14 15:40:30 +00:00
|
|
|
return NO;
|
|
|
|
}
|
|
|
|
|
2003-07-29 18:02:03 +00:00
|
|
|
- (BOOL) isMemberOfClass: (Class)aClass
|
2002-08-14 15:40:30 +00:00
|
|
|
{
|
2003-07-29 18:02:03 +00:00
|
|
|
return ([self class] == aClass);
|
2002-08-14 15:40:30 +00:00
|
|
|
}
|
|
|
|
|
2003-07-29 18:02:03 +00:00
|
|
|
- (BOOL) respondsToSelector: (SEL)aSelector
|
2002-08-14 15:40:30 +00:00
|
|
|
{
|
2011-01-14 03:07:40 +00:00
|
|
|
return (class_get_instance_method ([self class], aSelector) != nil);
|
2002-08-14 15:40:30 +00:00
|
|
|
}
|
|
|
|
|
2011-02-07 13:16:16 +00:00
|
|
|
- (BOOL) conformsToProtocol: (Protocol *)aProtocol
|
2002-08-14 15:40:30 +00:00
|
|
|
{
|
2003-07-29 18:02:03 +00:00
|
|
|
return [[self class] conformsToProtocol: aProtocol];
|
2002-08-14 15:40:30 +00:00
|
|
|
}
|
|
|
|
|
2003-07-29 18:02:03 +00:00
|
|
|
/*
|
|
|
|
Returns a pointer to the function providing the method used to respond to
|
|
|
|
aSelector. If "self" is an instance, an instance method is returned. If
|
|
|
|
it's a class, a class method is returned.
|
|
|
|
*/
|
|
|
|
- (IMP) methodForSelector: (SEL)aSelector
|
2002-08-14 15:40:30 +00:00
|
|
|
{
|
2003-07-29 18:02:03 +00:00
|
|
|
local Class myClass = [self class];
|
2002-08-14 15:40:30 +00:00
|
|
|
|
2003-07-29 18:02:03 +00:00
|
|
|
if (!aSelector)
|
2011-01-14 03:07:40 +00:00
|
|
|
return nil;
|
2002-08-14 15:40:30 +00:00
|
|
|
|
|
|
|
return method_get_imp (object_is_instance (self)
|
2003-07-29 18:02:03 +00:00
|
|
|
? class_get_instance_method (myClass, aSelector)
|
|
|
|
: class_get_class_method (myClass, aSelector));
|
2002-08-14 15:40:30 +00:00
|
|
|
}
|
|
|
|
|
|
|
|
//+(struct objc_method_description *)descriptionForInstanceMethod:(SEL)aSel = #0;
|
|
|
|
//-(struct objc_method_description *)descriptionForMethod:(SEL)aSel = #0;
|
|
|
|
|
2003-07-29 18:02:03 +00:00
|
|
|
- (id) performSelector: (SEL)aSelector
|
2002-08-14 15:40:30 +00:00
|
|
|
{
|
2012-11-21 01:25:29 +00:00
|
|
|
local IMP msg = nil; // FIXME teach qfcc about noreturn
|
2003-07-29 18:02:03 +00:00
|
|
|
|
|
|
|
if (!aSelector || !(msg = obj_msg_lookup (self, aSelector)))
|
2004-02-04 00:56:33 +00:00
|
|
|
[self error: "invalid selector passed to %s: %s",
|
|
|
|
object_get_class_name (self),
|
|
|
|
sel_get_name (aSelector)];
|
2002-08-14 15:40:30 +00:00
|
|
|
|
2003-07-29 18:02:03 +00:00
|
|
|
return msg (self, aSelector);
|
2002-08-14 15:40:30 +00:00
|
|
|
}
|
|
|
|
|
2020-03-05 06:00:42 +00:00
|
|
|
- (id) performSelector: (SEL)aSelector withObject: (void *)anObject
|
2002-08-14 15:40:30 +00:00
|
|
|
{
|
2012-11-21 01:25:29 +00:00
|
|
|
local IMP msg = nil; // FIXME teach qfcc about noreturn
|
2002-08-14 15:40:30 +00:00
|
|
|
|
2003-07-29 18:02:03 +00:00
|
|
|
if (!aSelector || !(msg = obj_msg_lookup (self, aSelector)))
|
2004-02-04 00:56:33 +00:00
|
|
|
[self error: "invalid selector passed to %s: %s",
|
|
|
|
object_get_class_name (self),
|
|
|
|
sel_get_name (aSelector)];
|
2003-07-29 18:02:03 +00:00
|
|
|
|
|
|
|
return msg (self, aSelector, anObject);
|
2002-08-14 15:40:30 +00:00
|
|
|
}
|
|
|
|
|
2003-07-29 18:02:03 +00:00
|
|
|
- (id) performSelector: (SEL)aSelector
|
2020-03-05 06:00:42 +00:00
|
|
|
withObject: (void *)anObject
|
|
|
|
withObject: (void *)anotherObject
|
2002-08-14 15:40:30 +00:00
|
|
|
{
|
2003-07-29 18:02:03 +00:00
|
|
|
local IMP msg;
|
2002-08-14 15:40:30 +00:00
|
|
|
|
2012-11-21 01:25:29 +00:00
|
|
|
if (!aSelector || !(msg = obj_msg_lookup (self, aSelector))) {
|
2004-02-04 00:56:33 +00:00
|
|
|
[self error: "invalid selector passed to %s",
|
2003-07-29 18:02:03 +00:00
|
|
|
sel_get_name (_cmd)];
|
2012-11-21 01:25:29 +00:00
|
|
|
return nil; //FIXME teach qfcc about noreturn
|
|
|
|
}
|
2002-08-14 15:40:30 +00:00
|
|
|
|
2003-07-29 18:02:03 +00:00
|
|
|
return msg (self, aSelector, anObject, anotherObject);
|
|
|
|
}
|
2002-08-14 15:40:30 +00:00
|
|
|
|
2020-03-10 05:29:43 +00:00
|
|
|
- (void) performv: (SEL) sel : (@va_list) args
|
|
|
|
{
|
|
|
|
obj_msg_sendv (self, sel, args);
|
|
|
|
}
|
|
|
|
|
2003-07-29 18:02:03 +00:00
|
|
|
- (void) doesNotRecognizeSelector: (SEL)aSelector
|
2002-08-14 15:40:30 +00:00
|
|
|
{
|
2003-07-29 18:02:03 +00:00
|
|
|
[self error: "%s does not recognize %s",
|
|
|
|
object_get_class_name (self),
|
|
|
|
sel_get_name (aSelector)];
|
2002-08-14 15:40:30 +00:00
|
|
|
}
|
|
|
|
|
2003-07-29 18:02:03 +00:00
|
|
|
/*
|
|
|
|
MEMORY MANAGEMENT
|
|
|
|
|
|
|
|
These methods handle the manual garbage collection scheme.
|
|
|
|
*/
|
|
|
|
- (id) retain
|
2002-08-14 15:40:30 +00:00
|
|
|
{
|
2012-11-08 11:24:25 +00:00
|
|
|
obj_increment_retaincount (self);
|
2003-07-29 18:02:03 +00:00
|
|
|
return self;
|
2002-08-14 15:40:30 +00:00
|
|
|
}
|
|
|
|
|
2003-07-29 18:02:03 +00:00
|
|
|
- (/*oneway*/ void) release
|
2002-08-14 15:40:30 +00:00
|
|
|
{
|
2012-11-20 05:41:13 +00:00
|
|
|
int rc;
|
|
|
|
|
|
|
|
rc = obj_decrement_retaincount (self);
|
|
|
|
if (rc < 0)
|
|
|
|
obj_error (self, 0, "retain count went negative");
|
|
|
|
if (rc == 0)
|
2003-07-29 18:02:03 +00:00
|
|
|
[self dealloc];
|
2002-08-14 15:40:30 +00:00
|
|
|
}
|
|
|
|
|
2003-07-29 18:02:03 +00:00
|
|
|
- (id) autorelease
|
2002-08-14 15:40:30 +00:00
|
|
|
{
|
2010-11-22 04:26:23 +00:00
|
|
|
autoreleaseIMP (autoreleaseClass, autoreleaseSelector, self);
|
2010-11-24 02:45:49 +00:00
|
|
|
return self;
|
2002-08-14 15:40:30 +00:00
|
|
|
}
|
|
|
|
|
2003-08-01 21:20:04 +00:00
|
|
|
- (unsigned) retainCount
|
2002-08-14 15:40:30 +00:00
|
|
|
{
|
2012-11-08 11:24:25 +00:00
|
|
|
return obj_get_retaincount (self);
|
2002-08-14 15:40:30 +00:00
|
|
|
}
|
2012-11-08 11:38:19 +00:00
|
|
|
|
|
|
|
/* The class implementations of autorelease, retain and release are dummy
|
|
|
|
methods with no effect. They allow class objects to be stored in
|
|
|
|
containers that send retain and release messages. Thus, the class
|
|
|
|
implementation of retainCount always returns the maximum unsigned value.
|
|
|
|
*/
|
|
|
|
+ (id) autorelease
|
|
|
|
{
|
|
|
|
return self;
|
|
|
|
}
|
|
|
|
|
|
|
|
+ (id) retain
|
|
|
|
{
|
|
|
|
return self;
|
|
|
|
}
|
|
|
|
|
|
|
|
+ (/*oneway*/ void) release
|
|
|
|
{
|
|
|
|
}
|
|
|
|
|
|
|
|
+ (unsigned) retainCount
|
|
|
|
{
|
|
|
|
return UINT_MAX;
|
|
|
|
}
|
|
|
|
|
2003-07-29 18:02:03 +00:00
|
|
|
/*
|
|
|
|
CONVENIENCE METHODS
|
2002-08-14 15:40:30 +00:00
|
|
|
|
2003-07-29 18:02:03 +00:00
|
|
|
These methods exist only so that certain methods always work.
|
|
|
|
*/
|
|
|
|
|
|
|
|
- (id) copy
|
2002-08-14 15:40:30 +00:00
|
|
|
{
|
2003-07-29 18:02:03 +00:00
|
|
|
return self;
|
2002-08-14 15:40:30 +00:00
|
|
|
}
|
|
|
|
|
2003-07-29 18:02:03 +00:00
|
|
|
- (id) mutableCopy
|
|
|
|
{
|
|
|
|
return self;
|
|
|
|
}
|
2002-08-14 15:40:30 +00:00
|
|
|
|
2022-09-09 05:03:30 +00:00
|
|
|
- (string) describe
|
|
|
|
{
|
|
|
|
return sprintf ("[%s@%p]", object_get_class_name (self), self);
|
|
|
|
}
|
|
|
|
|
2002-08-14 15:40:30 +00:00
|
|
|
@end
|