Differences From Artifact [37d4036ea2]:
- File
src/OFString.h
— part of check-in
[f3ccf14461]
at
2017-10-29 21:58:14
on branch trunk
— Convert methods to properties where appropriate
This improves Swift compatibility. (user: js, size: 37333) [annotate] [blame] [check-ins using]
To Artifact [cf140eeb90]:
- File src/OFString.h — part of check-in [1ec122d57c] at 2017-11-04 16:01:51 on branch trunk — +[stringWithUTF8StringNoCopy:length:freeWhenDone:] (user: js, size: 38671) [annotate] [blame] [check-ins using]
︙ | ︙ | |||
332 333 334 335 336 337 338 | * @return A new autoreleased OFString */ + (instancetype)stringWithUTF8String: (const char *)UTF8String length: (size_t)UTF8StringLength; /*! * @brief Creates a new OFString from a UTF-8 encoded C string without copying | | > > > > > > > > > > > > > > > > > > | 332 333 334 335 336 337 338 339 340 341 342 343 344 345 346 347 348 349 350 351 352 353 354 355 356 357 358 359 360 361 362 363 364 365 366 367 368 369 370 371 | * @return A new autoreleased OFString */ + (instancetype)stringWithUTF8String: (const char *)UTF8String length: (size_t)UTF8StringLength; /*! * @brief Creates a new OFString from a UTF-8 encoded C string without copying * the string, if possible. * * @note OFMutableString always creates a copy! * * @param UTF8String A UTF-8 encoded C string to initialize the OFString with * @param freeWhenDone Whether to free the C string when the OFString gets * deallocated * @return A new autoreleased OFString */ + (instancetype)stringWithUTF8StringNoCopy: (char *)UTF8String freeWhenDone: (bool)freeWhenDone; /*! * @brief Creates a new OFString from a UTF-8 encoded C string with the * specified length without copying the string, if possible. * * @note OFMutableString always creates a copy! * * @param UTF8String A UTF-8 encoded C string to initialize the OFString with * @param UTF8StringLength The length of the UTF-8 encoded C string * @param freeWhenDone Whether to free the C string when the OFString gets * deallocated * @return A new autoreleased OFString */ + (instancetype)stringWithUTF8StringNoCopy: (char *)UTF8String length: (size_t)UTF8StringLength freeWhenDone: (bool)freeWhenDone; /*! * @brief Creates a new OFString from a C string with the specified encoding. * * @param cString A C string to initialize the OFString with * @param encoding The encoding of the C string |
︙ | ︙ | |||
573 574 575 576 577 578 579 | * @return An initialized OFString */ - (instancetype)initWithUTF8String: (const char *)UTF8String length: (size_t)UTF8StringLength; /*! * @brief Initializes an already allocated OFString from an UTF-8 encoded C | | > > > > > > > > > | > > > > > > > > | 591 592 593 594 595 596 597 598 599 600 601 602 603 604 605 606 607 608 609 610 611 612 613 614 615 616 617 618 619 620 621 622 623 624 625 626 627 628 629 630 631 | * @return An initialized OFString */ - (instancetype)initWithUTF8String: (const char *)UTF8String length: (size_t)UTF8StringLength; /*! * @brief Initializes an already allocated OFString from an UTF-8 encoded C * string without copying the string, if possible. * * @note OFMutableString always creates a copy! * * @param UTF8String A UTF-8 encoded C string to initialize the OFString with * @param freeWhenDone Whether to free the C string when it is not needed * anymore * @return An initialized OFString */ - (instancetype)initWithUTF8StringNoCopy: (char *)UTF8String freeWhenDone: (bool)freeWhenDone; /*! * @brief Initializes an already allocated OFString from an UTF-8 encoded C * string with the specified length without copying the string, if * possible. * * @note OFMutableString always creates a copy! * * @param UTF8String A UTF-8 encoded C string to initialize the OFString with * @param UTF8StringLength The length of the UTF-8 encoded C string * @param freeWhenDone Whether to free the C string when it is not needed * anymore * @return An initialized OFString */ - (instancetype)initWithUTF8StringNoCopy: (char *)UTF8String length: (size_t)UTF8StringLength freeWhenDone: (bool)freeWhenDone; /*! * @brief Initializes an already allocated OFString from a C string with the * specified encoding. * * @param cString A C string to initialize the OFString with |
︙ | ︙ |