︙ | | | ︙ | |
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
|
* LICENSE.GPLv2 or LICENSE.GPLv3 respectively included in the packaging of this
* file.
*/
#include "config.h"
#include <stdarg.h>
#import "OFArray.h"
#import "OFArray_subarray.h"
#import "OFArray_adjacent.h"
#import "OFString.h"
#import "OFXMLElement.h"
#import "OFEnumerationMutationException.h"
#import "OFInvalidArgumentException.h"
#import "OFNotImplementedException.h"
#import "OFOutOfRangeException.h"
#import "autorelease.h"
#import "macros.h"
static struct {
Class isa;
|
>
<
|
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
|
* LICENSE.GPLv2 or LICENSE.GPLv3 respectively included in the packaging of this
* file.
*/
#include "config.h"
#include <stdarg.h>
#include <stdlib.h>
#import "OFArray.h"
#import "OFArray_subarray.h"
#import "OFArray_adjacent.h"
#import "OFString.h"
#import "OFXMLElement.h"
#import "OFEnumerationMutationException.h"
#import "OFInvalidArgumentException.h"
#import "OFOutOfRangeException.h"
#import "autorelease.h"
#import "macros.h"
static struct {
Class isa;
|
︙ | | | ︙ | |
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
|
- (void)release
{
}
- (void)dealloc
{
@throw [OFNotImplementedException exceptionWithClass: [self class]
selector: _cmd];
[super dealloc]; /* Get rid of a stupid warning */
}
@end
@implementation OFArray
+ (void)initialize
{
if (self == [OFArray class])
|
|
>
|
|
>
|
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
|
- (void)release
{
}
- (void)dealloc
{
[self doesNotRecognizeSelector: _cmd];
abort();
/* Get rid of a stupid warning */
[super dealloc];
}
@end
@implementation OFArray
+ (void)initialize
{
if (self == [OFArray class])
|
︙ | | | ︙ | |
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
|
return [[[self alloc] initWithObjects: objects
count: count] autorelease];
}
- init
{
if (object_getClass(self) == [OFArray class]) {
Class c = [self class];
[self release];
@throw [OFNotImplementedException exceptionWithClass: c
selector: _cmd];
}
return [super init];
}
- initWithObject: (id)object
{
|
>
|
>
>
|
|
<
>
|
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
|
return [[[self alloc] initWithObjects: objects
count: count] autorelease];
}
- init
{
if (object_getClass(self) == [OFArray class]) {
@try {
[self doesNotRecognizeSelector: _cmd];
abort();
} @catch (id e) {
[self release];
@throw e;
}
}
return [super init];
}
- initWithObject: (id)object
{
|
︙ | | | ︙ | |
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
|
return ret;
}
- initWithObject: (id)firstObject
arguments: (va_list)arguments
{
Class c = [self class];
[self release];
@throw [OFNotImplementedException exceptionWithClass: c
selector: _cmd];
}
- initWithArray: (OFArray*)array
{
Class c = [self class];
[self release];
@throw [OFNotImplementedException exceptionWithClass: c
selector: _cmd];
}
- initWithObjects: (id const*)objects
count: (size_t)count
{
Class c = [self class];
[self release];
@throw [OFNotImplementedException exceptionWithClass: c
selector: _cmd];
}
- initWithSerialization: (OFXMLElement*)element
{
Class c = [self class];
[self release];
@throw [OFNotImplementedException exceptionWithClass: c
selector: _cmd];
}
- (size_t)count
{
@throw [OFNotImplementedException exceptionWithClass: [self class]
selector: _cmd];
}
- (void)getObjects: (id*)buffer
inRange: (of_range_t)range
{
size_t i;
|
>
|
>
>
|
|
<
>
>
|
>
>
|
|
<
>
>
|
>
>
|
|
<
>
>
|
>
>
|
|
<
>
<
|
>
|
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
|
return ret;
}
- initWithObject: (id)firstObject
arguments: (va_list)arguments
{
@try {
[self doesNotRecognizeSelector: _cmd];
abort();
} @catch (id e) {
[self release];
@throw e;
}
}
- initWithArray: (OFArray*)array
{
@try {
[self doesNotRecognizeSelector: _cmd];
abort();
} @catch (id e) {
[self release];
@throw e;
}
}
- initWithObjects: (id const*)objects
count: (size_t)count
{
@try {
[self doesNotRecognizeSelector: _cmd];
abort();
} @catch (id e) {
[self release];
@throw e;
}
}
- initWithSerialization: (OFXMLElement*)element
{
@try {
[self doesNotRecognizeSelector: _cmd];
abort();
} @catch (id e) {
[self release];
@throw e;
}
}
- (size_t)count
{
[self doesNotRecognizeSelector: _cmd];
abort();
}
- (void)getObjects: (id*)buffer
inRange: (of_range_t)range
{
size_t i;
|
︙ | | | ︙ | |
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
|
- mutableCopy
{
return [[OFMutableArray alloc] initWithArray: self];
}
- (id)objectAtIndex: (size_t)index
{
@throw [OFNotImplementedException exceptionWithClass: [self class]
selector: _cmd];
}
- (id)objectAtIndexedSubscript: (size_t)index
{
return [self objectAtIndex: index];
}
|
<
|
>
|
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
|
- mutableCopy
{
return [[OFMutableArray alloc] initWithArray: self];
}
- (id)objectAtIndex: (size_t)index
{
[self doesNotRecognizeSelector: _cmd];
abort();
}
- (id)objectAtIndexedSubscript: (size_t)index
{
return [self objectAtIndex: index];
}
|
︙ | | | ︙ | |