OpenCores
URL https://opencores.org/ocsvn/scarts/scarts/trunk

Subversion Repositories scarts

[/] [scarts/] [trunk/] [toolchain/] [scarts-gcc/] [gcc-4.1.1/] [libobjc/] [objc/] [Object.h] - Blame information for rev 14

Details | Compare with Previous | View Log

Line No. Rev Author Line
1 14 jlechner
/* Interface for the Object class for Objective-C.
2
   Copyright (C) 1993, 1994, 1995 Free Software Foundation, Inc.
3
 
4
This file is part of GCC.
5
 
6
GCC is free software; you can redistribute it and/or modify it
7
under the terms of the GNU General Public License as published by the
8
Free Software Foundation; either version 2, or (at your option) any
9
later version.
10
 
11
GCC is distributed in the hope that it will be useful, but WITHOUT
12
ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
13
FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public
14
License for more details.
15
 
16
You should have received a copy of the GNU General Public License
17
along with GCC; see the file COPYING.  If not, write to
18
the Free Software Foundation, 51 Franklin Street, Fifth Floor,
19
Boston, MA 02110-1301, USA.  */
20
 
21
/* As a special exception, if you link this library with files compiled
22
   with GCC to produce an executable, this does not cause the resulting
23
   executable to be covered by the GNU General Public License.  This
24
   exception does not however invalidate any other reasons why the
25
   executable file might be covered by the GNU General Public License. */
26
 
27
#ifndef __object_INCLUDE_GNU
28
#define __object_INCLUDE_GNU
29
 
30
#include "objc.h"
31
#include "typedstream.h"
32
 
33
#ifdef __cplusplus
34
extern "C" {
35
#endif
36
 
37
/*
38
 * All classes are derived from Object.  As such,
39
 * this is the overhead tacked onto those objects.
40
 */
41
@interface Object
42
{
43
    Class       isa;    /* A pointer to the instance's class structure */
44
}
45
 
46
        /* Initializing classes and instances */
47
+ initialize;
48
- init;
49
 
50
        /* Creating, freeing, and copying instances */
51
+ new;
52
+ alloc;
53
- free;
54
- copy;
55
- shallowCopy;
56
- deepen;
57
- deepCopy;
58
 
59
        /* Identifying classes */
60
- (Class)class;
61
- (Class)superClass;
62
- (MetaClass)metaClass;
63
- (const char *)name;
64
 
65
        /* Identifying and comparing objects */
66
- self;
67
- (unsigned int)hash;
68
- (BOOL)isEqual:anObject;
69
- (int)compare:anotherObject;
70
 
71
        /* Testing object type */
72
- (BOOL)isMetaClass;
73
- (BOOL)isClass;
74
- (BOOL)isInstance;
75
 
76
        /* Testing inheritance relationships */
77
- (BOOL)isKindOf:(Class)aClassObject;
78
- (BOOL)isMemberOf:(Class)aClassObject;
79
- (BOOL)isKindOfClassNamed:(const char *)aClassName;
80
- (BOOL)isMemberOfClassNamed:(const char *)aClassName;
81
 
82
        /* Testing class functionality */
83
+ (BOOL)instancesRespondTo:(SEL)aSel;
84
- (BOOL)respondsTo:(SEL)aSel;
85
 
86
        /* Testing protocol conformance */
87
- (BOOL)conformsTo:(Protocol*)aProtocol;
88
 
89
        /* Introspection */
90
+ (IMP)instanceMethodFor:(SEL)aSel;
91
- (IMP)methodFor:(SEL)aSel;
92
+ (struct objc_method_description *)descriptionForInstanceMethod:(SEL)aSel;
93
- (struct objc_method_description *)descriptionForMethod:(SEL)aSel;
94
 
95
        /* Sending messages determined at run time */
96
- perform:(SEL)aSel;
97
- perform:(SEL)aSel with:anObject;
98
- perform:(SEL)aSel with:anObject1 with:anObject2;
99
 
100
        /* Forwarding */
101
- (retval_t)forward:(SEL)aSel :(arglist_t)argFrame;
102
- (retval_t)performv:(SEL)aSel :(arglist_t)argFrame;
103
 
104
        /* Posing */
105
+ poseAs:(Class)aClassObject;
106
- (Class)transmuteClassTo:(Class)aClassObject;
107
 
108
        /* Enforcing intentions */
109
- subclassResponsibility:(SEL)aSel;
110
- notImplemented:(SEL)aSel;
111
- shouldNotImplement:(SEL)aSel;
112
 
113
        /* Error handling */
114
- doesNotRecognize:(SEL)aSel;
115
- error:(const char *)aString, ...;
116
 
117
        /* Archiving */
118
+ (int)version;
119
+ setVersion:(int)aVersion;
120
+ (int)streamVersion: (TypedStream*)aStream;
121
 
122
- read: (TypedStream*)aStream;
123
- write: (TypedStream*)aStream;
124
- awake;
125
 
126
@end
127
 
128
#ifdef __cplusplus
129
}
130
#endif
131
 
132
#endif

powered by: WebSVN 2.1.0

© copyright 1999-2024 OpenCores.org, equivalent to Oliscience, all rights reserved. OpenCores®, registered trademark.