308
309
310
311
312
313
314
315
316
317
318
319
320
321
|
toNItems: count
withSize: itemSize];
} @catch (OFOutOfMemoryException *e) {
/* We don't really care, as we only made it smaller */
[e release];
}
}
- copy
{
OFDataArray *copy = [[OFDataArray alloc] initWithItemSize: itemSize];
[copy addNItems: count
fromCArray: data];
|
>
>
>
>
>
>
>
>
>
>
>
>
>
|
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
|
toNItems: count
withSize: itemSize];
} @catch (OFOutOfMemoryException *e) {
/* We don't really care, as we only made it smaller */
[e release];
}
}
- (void)removeLastItem
{
count--;
@try {
data = [self resizeMemory: data
toNItems: count
withSize: itemSize];
} @catch (OFOutOfMemoryException *e) {
/* We don't care, as we only made it smaller */
[e release];
}
}
- copy
{
OFDataArray *copy = [[OFDataArray alloc] initWithItemSize: itemSize];
[copy addNItems: count
fromCArray: data];
|