22
23
24
25
26
27
28
|
/**
* Resets the enumerator, so the next call to nextObject returns the first
* object again.
*/
- reset;
@end
|
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
|
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
|
/**
* Resets the enumerator, so the next call to nextObject returns the first
* object again.
*/
- reset;
@end
/*
* This needs to be exactly like this because it's hardcoded in the compiler.
*
* We need this bad check to see if we already imported Cocoa, which defines
* this as well.
*/
#define of_fast_enumeration_state_t NSFastEnumerationState
#ifndef NSINTEGER_DEFINED
typedef struct __of_fast_enumeration_state {
unsigned long state;
id *itemsPtr;
unsigned long *mutationsPtr;
unsigned long extra[5];
} of_fast_enumeration_state_t;
#endif
/**
* The OFFastEnumeration protocol needs to be implemented by all classes
* supporting fast enumeration.
*/
@protocol OFFastEnumeration
- (int)countByEnumeratingWithState: (of_fast_enumeration_state_t*)state
objects: (id*)objects
count: (int)count;
@end
|