Differences From Artifact [16603a1ba8]:
- File
src/OFMutableArray.h
— part of check-in
[a0fd103a0b]
at
2021-03-07 02:36:04
on branch trunk
— Style change: Allow more than 1 argument per line
This is only migrating some places, others will be migrated as they are
touched. (user: js, size: 6829) [annotate] [blame] [check-ins using] [more...]
To Artifact [a684ec1cde]:
- File src/OFMutableArray.h — part of check-in [e23daca6ef] at 2021-04-17 02:40:59 on branch new-naming-convention — Rename all types in OFArray.h (user: js, size: 6455) [annotate] [blame] [check-ins using] [more...]
︙ | ︙ | |||
23 24 25 26 27 28 29 | /** * @brief A block for replacing values in an OFMutableArray. * * @param object The object to replace * @param index The index of the object to replace * @return The object to replace the object with */ | | | 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 | /** * @brief A block for replacing values in an OFMutableArray. * * @param object The object to replace * @param index The index of the object to replace * @return The object to replace the object with */ typedef id _Nonnull (^OFArrayReplaceBlock)(id object, size_t index); #endif /** * @class OFMutableArray OFArray.h ObjFW/OFArray.h * * @brief An abstract class for storing, adding and removing objects in an * array. |
︙ | ︙ | |||
155 156 157 158 159 160 161 | - (void)removeObjectAtIndex: (size_t)index; /** * @brief Removes the object in the specified range. * * @param range The range of the objects to remove */ | | | | < < < < | | < < < < | > | 155 156 157 158 159 160 161 162 163 164 165 166 167 168 169 170 171 172 173 174 175 176 177 178 179 180 181 182 183 184 185 186 187 188 189 190 191 192 193 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 | - (void)removeObjectAtIndex: (size_t)index; /** * @brief Removes the object in the specified range. * * @param range The range of the objects to remove */ - (void)removeObjectsInRange: (OFRange)range; /** * @brief Removes the last object. */ - (void)removeLastObject; /** * @brief Removes all objects. */ - (void)removeAllObjects; #ifdef OF_HAVE_BLOCKS /** * @brief Replaces each object with the object returned by the block. * * @param block The block which returns a new object for each object */ - (void)replaceObjectsUsingBlock: (OFArrayReplaceBlock)block; #endif /** * @brief Exchange the objects at the specified indices. * * @param index1 The index of the first object to exchange * @param index2 The index of the second object to exchange */ - (void)exchangeObjectAtIndex: (size_t)index1 withObjectAtIndex: (size_t)index2; /** * @brief Sorts the array in ascending order. */ - (void)sort; /** * @brief Sorts the array using the specified selector and options. * * @param selector The selector to use to sort the array. It's signature * should be the same as that of -[compare:]. * @param options The options to use when sorting the array */ - (void)sortUsingSelector: (SEL)selector options: (OFArraySortOptions)options; #ifdef OF_HAVE_BLOCKS /** * @brief Sorts the array using the specified comparator and options. * * @param comparator The comparator to use to sort the array * @param options The options to use when sorting the array */ - (void)sortUsingComparator: (OFComparator)comparator options: (OFArraySortOptions)options; #endif /** * @brief Reverts the order of the objects in the array. */ - (void)reverse; |
︙ | ︙ |