47
48
49
50
51
52
53
54
55
56
57
58
59
60
|
- autorelease;
/**
* \return The retain count
*/
- (size_t)retainCount;
/**
* Adds a pointer to the memory pool.
* This is useful to add memory allocated by functions such as asprintf to the
* pool so it gets freed automatically when the object is freed.
*
* \param ptr A pointer to add to the memory pool
*/
|
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
|
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
|
- autorelease;
/**
* \return The retain count
*/
- (size_t)retainCount;
/**
* Frees the object and also frees all memory allocated via its memory pool.
*/
- free;
/**
* Compare two objects.
* Classes containing data (like strings, arrays, lists etc.) should reimplement
* this!
*
* \param obj The object which is tested for equality
* \return A boolean whether the object is equal to the other object
*/
- (BOOL)isEqual: (id)obj;
/**
* Calculate a hash for the object.
* Classes containing data (like strings, arrays, lists etc.) should reimplement
* this!
*
* \return A 24 bit hash for the object
*/
- (uint32_t)hash;
/**
* Adds a pointer to the memory pool.
* This is useful to add memory allocated by functions such as asprintf to the
* pool so it gets freed automatically when the object is freed.
*
* \param ptr A pointer to add to the memory pool
*/
|
105
106
107
108
109
110
111
112
113
114
115
116
117
|
/**
* Frees allocated memory and removes it from the memory pool.
*
* \param ptr A pointer to the allocated memory
*/
- freeMem: (void*)ptr;
/**
* Frees the object and also frees all memory allocated via its memory pool.
*/
- free;
@end
|
<
<
<
<
<
|
129
130
131
132
133
134
135
136
|
/**
* Frees allocated memory and removes it from the memory pool.
*
* \param ptr A pointer to the allocated memory
*/
- freeMem: (void*)ptr;
@end
|