ObjFW  Check-in [bfee66b3ec]

Overview
Comment:Introduce a naming scheme for placeholder classes.
Downloads: Tarball | ZIP archive | SQL archive
Timelines: family | ancestors | descendants | both | trunk
Files: files | file ages | folders
SHA3-256: bfee66b3ec2b0cc86badea5c4cbee794e6b7fe9ed5b767a3810e31baf32ba3fb
User & Date: js on 2011-08-13 10:16:37
Other Links: manifest | tags
Context
2011-08-21
11:03
Make OFDictionary an abstract class. check-in: c0098f89fe user: js tags: trunk
2011-08-13
10:16
Introduce a naming scheme for placeholder classes. check-in: bfee66b3ec user: js tags: trunk
10:04
Introduce a naming scheme for classes implementing abstract classes. check-in: 80d754522a user: js tags: trunk
Changes

Modified src/OFArray.h from [23dded9802] to [0e8f7a98da].

292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
 *		all objects except the first
 * \return The array folded to a single object
 */
- (id)foldUsingBlock: (of_array_fold_block_t)block;
#endif
@end

@interface OFArrayPlaceholder: OFArray
@end

@interface OFArrayEnumerator: OFEnumerator
{
	OFArray	      *array;
	size_t	      count;
	unsigned long mutations;







|







292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
 *		all objects except the first
 * \return The array folded to a single object
 */
- (id)foldUsingBlock: (of_array_fold_block_t)block;
#endif
@end

@interface OFArray_placeholder: OFArray
@end

@interface OFArrayEnumerator: OFEnumerator
{
	OFArray	      *array;
	size_t	      count;
	unsigned long mutations;

Modified src/OFArray.m from [2988c16d4d] to [e560d96eaf].

31
32
33
34
35
36
37
38
39
40
41
42
43
44
45

#import "macros.h"

static struct {
	Class isa;
} placeholder;

@implementation OFArrayPlaceholder
- init
{
	return (id)[[OFArray_adjacent alloc] init];
}

- initWithObject: (id)object
{







|







31
32
33
34
35
36
37
38
39
40
41
42
43
44
45

#import "macros.h"

static struct {
	Class isa;
} placeholder;

@implementation OFArray_placeholder
- init
{
	return (id)[[OFArray_adjacent alloc] init];
}

- initWithObject: (id)object
{
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
}
@end

@implementation OFArray
+ (void)initialize
{
	if (self == [OFArray class])
		placeholder.isa = [OFArrayPlaceholder class];
}

+ alloc
{
	if (self == [OFArray class])
		return (id)&placeholder;








|







110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
}
@end

@implementation OFArray
+ (void)initialize
{
	if (self == [OFArray class])
		placeholder.isa = [OFArray_placeholder class];
}

+ alloc
{
	if (self == [OFArray class])
		return (id)&placeholder;