Overview
Comment: | OFMutableString: Implement more methods.
The only method that needs to be implemented by a subclass now is |
---|---|
Downloads: | Tarball | ZIP archive | SQL archive |
Timelines: | family | ancestors | descendants | both | trunk |
Files: | files | file ages | folders |
SHA3-256: |
9e8c8256161a0da6bdd3a5932935b7e3 |
User & Date: | js on 2012-12-29 14:31:10 |
Other Links: | manifest | tags |
Context
2012-12-29
| ||
14:43 | Prettify some code. check-in: 374956b098 user: js tags: trunk | |
14:31 | OFMutableString: Implement more methods. check-in: 9e8c825616 user: js tags: trunk | |
14:29 | OFXMLParser: OFMutableString -> OFString. check-in: 036c487137 user: js tags: trunk | |
Changes
Modified src/OFMutableString.m from [e77a1233fc] to [b484829d75].
︙ | ︙ | |||
297 298 299 300 301 302 303 | objc_autoreleasePoolPop(pool); } - (void)setCharacter: (of_unichar_t)character atIndex: (size_t)index { | > > | > > | > > > > | 297 298 299 300 301 302 303 304 305 306 307 308 309 310 311 312 313 314 315 316 317 318 319 320 | objc_autoreleasePoolPop(pool); } - (void)setCharacter: (of_unichar_t)character atIndex: (size_t)index { void *pool = objc_autoreleasePoolPush(); OFString *string; string = [OFString stringWithUnicodeString: &character length: 1]; [self replaceCharactersInRange: of_range(index, 1) withString: string]; objc_autoreleasePoolPop(pool); } - (void)appendUTF8String: (const char*)UTF8String { void *pool = objc_autoreleasePoolPush(); [self appendString: [OFString stringWithUTF8String: UTF8String]]; |
︙ | ︙ | |||
431 432 433 434 435 436 437 | wordStartTableSize: OF_UNICODE_TITLECASE_TABLE_SIZE wordMiddleTableSize: OF_UNICODE_LOWERCASE_TABLE_SIZE]; } - (void)insertString: (OFString*)string atIndex: (size_t)index { | | | | | | | < | 439 440 441 442 443 444 445 446 447 448 449 450 451 452 453 454 455 456 457 458 459 460 461 462 463 464 465 466 467 | wordStartTableSize: OF_UNICODE_TITLECASE_TABLE_SIZE wordMiddleTableSize: OF_UNICODE_LOWERCASE_TABLE_SIZE]; } - (void)insertString: (OFString*)string atIndex: (size_t)index { [self replaceCharactersInRange: of_range(index, 0) withString: string]; } - (void)deleteCharactersInRange: (of_range_t)range { [self replaceCharactersInRange: range withString: @""]; } - (void)replaceCharactersInRange: (of_range_t)range withString: (OFString*)replacement { [self doesNotRecognizeSelector: _cmd]; abort(); } - (void)replaceOccurrencesOfString: (OFString*)string withString: (OFString*)replacement { [self replaceOccurrencesOfString: string withString: replacement |
︙ | ︙ |