@@ -121,21 +121,21 @@ * @brief Creates a new OFString from a UTF-8 encoded C string. * * @param UTF8String A UTF-8 encoded C string to initialize the OFString with * @return A new autoreleased OFString */ -+ (instancetype)stringWithUTF8String: (const char*)UTF8String; ++ (instancetype)stringWithUTF8String: (const char *)UTF8String; /*! * @brief Creates a new OFString from a UTF-8 encoded C string with the * specified length. * * @param UTF8String A UTF-8 encoded C string to initialize the OFString with * @param UTF8StringLength The length of the UTF-8 encoded C string * @return A new autoreleased OFString */ -+ (instancetype)stringWithUTF8String: (const char*)UTF8String ++ (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. @@ -143,21 +143,21 @@ * @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 ++ (instancetype)stringWithUTF8StringNoCopy: (char *)UTF8String 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 * @return A new autoreleased OFString */ -+ (instancetype)stringWithCString: (const char*)cString ++ (instancetype)stringWithCString: (const char *)cString encoding: (of_string_encoding_t)encoding; /*! * @brief Creates a new OFString from a C string with the specified encoding * and length. @@ -165,50 +165,50 @@ * @param cString A C string to initialize the OFString with * @param encoding The encoding of the C string * @param cStringLength The length of the C string * @return A new autoreleased OFString */ -+ (instancetype)stringWithCString: (const char*)cString ++ (instancetype)stringWithCString: (const char *)cString encoding: (of_string_encoding_t)encoding length: (size_t)cStringLength; /*! * @brief Creates a new OFString from another string. * * @param string A string to initialize the OFString with * @return A new autoreleased OFString */ -+ (instancetype)stringWithString: (OFString*)string; ++ (instancetype)stringWithString: (OFString *)string; /*! * @brief Creates a new OFString from a Unicode string with the specified * length. * * @param characters An array of Unicode characters * @param length The length of the Unicode character array * @return A new autoreleased OFString */ -+ (instancetype)stringWithCharacters: (const of_unichar_t*)characters ++ (instancetype)stringWithCharacters: (const of_unichar_t *)characters length: (size_t)length; /*! * @brief Creates a new OFString from a UTF-16 encoded string. * * @param string The UTF-16 string * @return A new autoreleased OFString */ -+ (instancetype)stringWithUTF16String: (const of_char16_t*)string; ++ (instancetype)stringWithUTF16String: (const of_char16_t *)string; /*! * @brief Creates a new OFString from a UTF-16 encoded string with the * specified length. * * @param string The UTF-16 string * @param length The length of the UTF-16 string * @return A new autoreleased OFString */ -+ (instancetype)stringWithUTF16String: (const of_char16_t*)string ++ (instancetype)stringWithUTF16String: (const of_char16_t *)string length: (size_t)length; /*! * @brief Creates a new OFString from a UTF-16 encoded string, assuming the * specified byte order if no byte order mark is found. @@ -215,11 +215,11 @@ * * @param string The UTF-16 string * @param byteOrder The byte order to assume if there is no byte order mark * @return A new autoreleased OFString */ -+ (instancetype)stringWithUTF16String: (const of_char16_t*)string ++ (instancetype)stringWithUTF16String: (const of_char16_t *)string byteOrder: (of_byte_order_t)byteOrder; /*! * @brief Creates a new OFString from a UTF-16 encoded string with the * specified length, assuming the specified byte order if no byte order @@ -228,31 +228,31 @@ * @param string The UTF-16 string * @param length The length of the UTF-16 string * @param byteOrder The byte order to assume if there is no byte order mark * @return A new autoreleased OFString */ -+ (instancetype)stringWithUTF16String: (const of_char16_t*)string ++ (instancetype)stringWithUTF16String: (const of_char16_t *)string length: (size_t)length byteOrder: (of_byte_order_t)byteOrder; /*! * @brief Creates a new OFString from a UTF-32 encoded string. * * @param string The UTF-32 string * @return A new autoreleased OFString */ -+ (instancetype)stringWithUTF32String: (const of_char32_t*)string; ++ (instancetype)stringWithUTF32String: (const of_char32_t *)string; /*! * @brief Creates a new OFString from a UTF-32 encoded string with the * specified length. * * @param string The UTF-32 string * @param length The length of the UTF-32 string * @return A new autoreleased OFString */ -+ (instancetype)stringWithUTF32String: (const of_char32_t*)string ++ (instancetype)stringWithUTF32String: (const of_char32_t *)string length: (size_t)length; /*! * @brief Creates a new OFString from a UTF-32 encoded string, assuming the * specified byte order if no byte order mark is found. @@ -259,11 +259,11 @@ * * @param string The UTF-32 string * @param byteOrder The byte order to assume if there is no byte order mark * @return A new autoreleased OFString */ -+ (instancetype)stringWithUTF32String: (const of_char32_t*)string ++ (instancetype)stringWithUTF32String: (const of_char32_t *)string byteOrder: (of_byte_order_t)byteOrder; /*! * @brief Creates a new OFString from a UTF-32 encoded string with the * specified length, assuming the specified byte order if no byte order @@ -272,44 +272,45 @@ * @param string The UTF-32 string * @param length The length of the UTF-32 string * @param byteOrder The byte order to assume if there is no byte order mark * @return A new autoreleased OFString */ -+ (instancetype)stringWithUTF32String: (const of_char32_t*)string ++ (instancetype)stringWithUTF32String: (const of_char32_t *)string length: (size_t)length byteOrder: (of_byte_order_t)byteOrder; /*! * @brief Creates a new OFString from a format string. * - * See printf for the format syntax. As an addition, %@ is available as format - * specifier for objects, %C for of_unichar_t and %S for const of_unichar_t*. + * See printf for the format syntax. As an addition, `%@` is available as + * format specifier for objects, `%C` for `of_unichar_t` and `%S` for + * `const of_unichar_t *`. * * @param format A string used as format to initialize the OFString * @return A new autoreleased OFString */ -+ (instancetype)stringWithFormat: (OFConstantString*)format, ...; ++ (instancetype)stringWithFormat: (OFConstantString *)format, ...; #ifdef OF_HAVE_FILES /*! * @brief Creates a new OFString with the contents of the specified UTF-8 * encoded file. * * @param path The path to the file * @return A new autoreleased OFString */ -+ (instancetype)stringWithContentsOfFile: (OFString*)path; ++ (instancetype)stringWithContentsOfFile: (OFString *)path; /*! * @brief Creates a new OFString with the contents of the specified file in the * specified encoding. * * @param path The path to the file * @param encoding The encoding of the file * @return A new autoreleased OFString */ -+ (instancetype)stringWithContentsOfFile: (OFString*)path ++ (instancetype)stringWithContentsOfFile: (OFString *)path encoding: (of_string_encoding_t)encoding; #endif #if defined(OF_HAVE_FILES) || defined(OF_HAVE_SOCKETS) /*! @@ -322,50 +323,50 @@ * UTF-8. * * @param URL The URL to the contents for the string * @return A new autoreleased OFString */ -+ (instancetype)stringWithContentsOfURL: (OFURL*)URL; ++ (instancetype)stringWithContentsOfURL: (OFURL *)URL; /*! * @brief Creates a new OFString with the contents of the specified URL in the * specified encoding. * * @param URL The URL to the contents for the string * @param encoding The encoding to assume * @return A new autoreleased OFString */ -+ (instancetype)stringWithContentsOfURL: (OFURL*)URL ++ (instancetype)stringWithContentsOfURL: (OFURL *)URL encoding: (of_string_encoding_t)encoding; #endif /*! * @brief Creates a path from the specified path components. * * @param components An array of components for the path * @return A new autoreleased OFString */ -+ (OFString*)pathWithComponents: (OFArray OF_GENERIC(OFString*)*)components; ++ (OFString *)pathWithComponents: (OFArray OF_GENERIC(OFString *) *)components; /*! * @brief Initializes an already allocated OFString from a UTF-8 encoded C * string. * * @param UTF8String A UTF-8 encoded C string to initialize the OFString with * @return An initialized OFString */ -- initWithUTF8String: (const char*)UTF8String; +- initWithUTF8String: (const char *)UTF8String; /*! * @brief Initializes an already allocated OFString from a UTF-8 encoded C * string with the specified length. * * @param UTF8String A UTF-8 encoded C string to initialize the OFString with * @param UTF8StringLength The length of the UTF-8 encoded C string * @return An initialized OFString */ -- initWithUTF8String: (const char*)UTF8String +- initWithUTF8String: (const char *)UTF8String length: (size_t)UTF8StringLength; /*! * @brief Initializes an already allocated OFString from an UTF-8 encoded C * string without copying it, if possible. @@ -375,11 +376,11 @@ * @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 */ -- initWithUTF8StringNoCopy: (char*)UTF8String +- initWithUTF8StringNoCopy: (char *)UTF8String freeWhenDone: (bool)freeWhenDone; /*! * @brief Initializes an already allocated OFString from a C string with the * specified encoding. @@ -386,11 +387,11 @@ * * @param cString A C string to initialize the OFString with * @param encoding The encoding of the C string * @return An initialized OFString */ -- initWithCString: (const char*)cString +- initWithCString: (const char *)cString encoding: (of_string_encoding_t)encoding; /*! * @brief Initializes an already allocated OFString from a C string with the * specified encoding and length. @@ -398,50 +399,50 @@ * @param cString A C string to initialize the OFString with * @param encoding The encoding of the C string * @param cStringLength The length of the C string * @return An initialized OFString */ -- initWithCString: (const char*)cString +- initWithCString: (const char *)cString encoding: (of_string_encoding_t)encoding length: (size_t)cStringLength; /*! * @brief Initializes an already allocated OFString with another string. * * @param string A string to initialize the OFString with * @return An initialized OFString */ -- initWithString: (OFString*)string; +- initWithString: (OFString *)string; /*! * @brief Initializes an already allocated OFString with a Unicode string with * the specified length. * * @param characters An array of Unicode characters * @param length The length of the Unicode character array * @return An initialized OFString */ -- initWithCharacters: (const of_unichar_t*)characters +- initWithCharacters: (const of_unichar_t *)characters length: (size_t)length; /*! * @brief Initializes an already allocated OFString with a UTF-16 string. * * @param string The UTF-16 string * @return An initialized OFString */ -- initWithUTF16String: (const of_char16_t*)string; +- initWithUTF16String: (const of_char16_t *)string; /*! * @brief Initializes an already allocated OFString with a UTF-16 string with * the specified length. * * @param string The UTF-16 string * @param length The length of the UTF-16 string * @return An initialized OFString */ -- initWithUTF16String: (const of_char16_t*)string +- initWithUTF16String: (const of_char16_t *)string length: (size_t)length; /*! * @brief Initializes an already allocated OFString with a UTF-16 string, * assuming the specified byte order if no byte order mark is found. @@ -448,11 +449,11 @@ * * @param string The UTF-16 string * @param byteOrder The byte order to assume if there is no byte order mark * @return An initialized OFString */ -- initWithUTF16String: (const of_char16_t*)string +- initWithUTF16String: (const of_char16_t *)string byteOrder: (of_byte_order_t)byteOrder; /*! * @brief Initializes an already allocated OFString with a UTF-16 string with * the specified length, assuming the specified byte order if no byte @@ -461,31 +462,31 @@ * @param string The UTF-16 string * @param length The length of the UTF-16 string * @param byteOrder The byte order to assume if there is no byte order mark * @return An initialized OFString */ -- initWithUTF16String: (const of_char16_t*)string +- initWithUTF16String: (const of_char16_t *)string length: (size_t)length byteOrder: (of_byte_order_t)byteOrder; /*! * @brief Initializes an already allocated OFString with a UTF-32 string. * * @param string The UTF-32 string * @return An initialized OFString */ -- initWithUTF32String: (const of_char32_t*)string; +- initWithUTF32String: (const of_char32_t *)string; /*! * @brief Initializes an already allocated OFString with a UTF-32 string with * the specified length * * @param string The UTF-32 string * @param length The length of the UTF-32 string * @return An initialized OFString */ -- initWithUTF32String: (const of_char32_t*)string +- initWithUTF32String: (const of_char32_t *)string length: (size_t)length; /*! * @brief Initializes an already allocated OFString with a UTF-32 string, * assuming the specified byte order if no byte order mark is found. @@ -492,11 +493,11 @@ * * @param string The UTF-32 string * @param byteOrder The byte order to assume if there is no byte order mark * @return An initialized OFString */ -- initWithUTF32String: (const of_char32_t*)string +- initWithUTF32String: (const of_char32_t *)string byteOrder: (of_byte_order_t)byteOrder; /*! * @brief Initializes an already allocated OFString with a UTF-32 string with * the specified length, assuming the specified byte order if no byte @@ -505,36 +506,38 @@ * @param string The UTF-32 string * @param length The length of the UTF-32 string * @param byteOrder The byte order to assume if there is no byte order mark * @return An initialized OFString */ -- initWithUTF32String: (const of_char32_t*)string +- initWithUTF32String: (const of_char32_t *)string length: (size_t)length byteOrder: (of_byte_order_t)byteOrder; /*! * @brief Initializes an already allocated OFString with a format string. * - * See printf for the format syntax. As an addition, %@ is available as format - * specifier for objects, %C for of_unichar_t and %S for const of_unichar_t*. + * See printf for the format syntax. As an addition, `%@` is available as + * format specifier for objects, `%C` for `of_unichar_t` and `%S` for + * `const of_unichar_t *`. * * @param format A string used as format to initialize the OFString * @return An initialized OFString */ -- initWithFormat: (OFConstantString*)format, ...; +- initWithFormat: (OFConstantString *)format, ...; /*! * @brief Initializes an already allocated OFString with a format string. * - * See printf for the format syntax. As an addition, %@ is available as format - * specifier for objects, %C for of_unichar_t and %S for const of_unichar_t*. + * See printf for the format syntax. As an addition, `%@` is available as + * format specifier for objects, `%C` for `of_unichar_t` and `%S` for + * `const of_unichar_t *`. * * @param format A string used as format to initialize the OFString * @param arguments The arguments used in the format string * @return An initialized OFString */ -- initWithFormat: (OFConstantString*)format +- initWithFormat: (OFConstantString *)format arguments: (va_list)arguments; #ifdef OF_HAVE_FILES /*! * @brief Initializes an already allocated OFString with the contents of the @@ -541,21 +544,21 @@ * specified file in the specified encoding. * * @param path The path to the file * @return An initialized OFString */ -- initWithContentsOfFile: (OFString*)path; +- initWithContentsOfFile: (OFString *)path; /*! * @brief Initializes an already allocated OFString with the contents of the * specified file in the specified encoding. * * @param path The path to the file * @param encoding The encoding of the file * @return An initialized OFString */ -- initWithContentsOfFile: (OFString*)path +- initWithContentsOfFile: (OFString *)path encoding: (of_string_encoding_t)encoding; #endif #if defined(OF_HAVE_FILES) || defined(OF_HAVE_SOCKETS) /*! @@ -569,21 +572,21 @@ * UTF-8. * * @param URL The URL to the contents for the string * @return An initialized OFString */ -- initWithContentsOfURL: (OFURL*)URL; +- initWithContentsOfURL: (OFURL *)URL; /*! * @brief Initializes an already allocated OFString with the contents of the * specified URL in the specified encoding. * * @param URL The URL to the contents for the string * @param encoding The encoding to assume * @return An initialized OFString */ -- initWithContentsOfURL: (OFURL*)URL +- initWithContentsOfURL: (OFURL *)URL encoding: (of_string_encoding_t)encoding; #endif /*! * @brief Writes the OFString into the specified C string with the specified @@ -594,11 +597,11 @@ * including the terminating zero * @param encoding The encoding to use for writing into the C string * @return The number of bytes written into the C string, without the * terminating zero */ -- (size_t)getCString: (char*)cString +- (size_t)getCString: (char *)cString maxLength: (size_t)maxLength encoding: (of_string_encoding_t)encoding; /*! * @brief Writes the OFString into the specified C string with the specified @@ -610,11 +613,11 @@ * including the terminating zero * @param encoding The encoding to use for writing into the C string * @return The number of bytes written into the C string, without the * terminating zero */ -- (size_t)getLossyCString: (char*)cString +- (size_t)getLossyCString: (char *)cString maxLength: (size_t)maxLength encoding: (of_string_encoding_t)encoding; /*! * @brief Returns the OFString as a C string in the specified encoding. @@ -624,11 +627,11 @@ * copy it. * * @param encoding The encoding for the C string * @return The OFString as a C string in the specified encoding */ -- (const char*)cStringWithEncoding: (of_string_encoding_t)encoding +- (const char *)cStringWithEncoding: (of_string_encoding_t)encoding OF_RETURNS_INNER_POINTER; /*! * @brief Returns the OFString as a C string in the specified encoding, * replacing characters that cannot be represented in the specified @@ -639,11 +642,11 @@ * copy it. * * @param encoding The encoding for the C string * @return The OFString as a C string in the specified encoding */ -- (const char*)lossyCStringWithEncoding: (of_string_encoding_t)encoding +- (const char *)lossyCStringWithEncoding: (of_string_encoding_t)encoding OF_RETURNS_INNER_POINTER; /*! * @brief Returns the OFString as a UTF-8 encoded C string. * @@ -651,11 +654,11 @@ * use the result outside the scope of the current autorelease pool, you have to * copy it. * * @return The OFString as a UTF-8 encoded C string */ -- (const char*)UTF8String OF_RETURNS_INNER_POINTER; +- (const char *)UTF8String OF_RETURNS_INNER_POINTER; /*! * @brief Returns the length of the string in Unicode characters. * * @return The length of the string in Unicode characters @@ -683,11 +686,11 @@ * case. * * @param otherString A string to compare with * @return An of_comparison_result_t */ -- (of_comparison_result_t)caseInsensitiveCompare: (OFString*)otherString; +- (of_comparison_result_t)caseInsensitiveCompare: (OFString *)otherString; /*! * @brief Returns the Unicode character at the specified index. * * @param index The index of the Unicode character to return @@ -700,21 +703,21 @@ * buffer. * * @param buffer The buffer to store the Unicode characters * @param range The range of the Unicode characters to copy */ -- (void)getCharacters: (of_unichar_t*)buffer +- (void)getCharacters: (of_unichar_t *)buffer inRange: (of_range_t)range; /*! * @brief Returns the range of the first occurrence of the string. * * @param string The string to search * @return The range of the first occurrence of the string or a range with * `OF_NOT_FOUND` as start position if it was not found */ -- (of_range_t)rangeOfString: (OFString*)string; +- (of_range_t)rangeOfString: (OFString *)string; /*! * @brief Returns the range of the string. * * @param string The string to search @@ -724,11 +727,11 @@ * -----------------------------|------------------------------- * `OF_STRING_SEARCH_BACKWARDS` | Search backwards in the string * @return The range of the first occurrence of the string or a range with * `OF_NOT_FOUND` as start position if it was not found */ -- (of_range_t)rangeOfString: (OFString*)string +- (of_range_t)rangeOfString: (OFString *)string options: (int)options; /*! * @brief Returns the range of the string in the specified range. * @@ -740,82 +743,82 @@ * `OF_STRING_SEARCH_BACKWARDS` | Search backwards in the string * @param range The range in which to search * @return The range of the first occurrence of the string or a range with * `OF_NOT_FOUND` as start position if it was not found */ -- (of_range_t)rangeOfString: (OFString*)string +- (of_range_t)rangeOfString: (OFString *)string options: (int)options range: (of_range_t)range; /*! * @brief Returns whether the string contains the specified string. * * @param string The string to search * @return Whether the string contains the specified string */ -- (bool)containsString: (OFString*)string; +- (bool)containsString: (OFString *)string; /*! * @brief Creates a substring with the specified range. * * @param range The range of the substring * @return The substring as a new autoreleased OFString */ -- (OFString*)substringWithRange: (of_range_t)range; +- (OFString *)substringWithRange: (of_range_t)range; /*! * @brief Creates a new string by appending another string. * * @param string The string to append * @return A new, autoreleased OFString with the specified string appended */ -- (OFString*)stringByAppendingString: (OFString*)string; +- (OFString *)stringByAppendingString: (OFString *)string; /*! * @brief Creates a new string by appending the specified format. * * @param format A format string which generates the string to append * @return A new, autoreleased OFString with the specified format appended */ -- (OFString*)stringByAppendingFormat: (OFConstantString*)format, ...; +- (OFString *)stringByAppendingFormat: (OFConstantString *)format, ...; /*! * @brief Creates a new string by appending the specified format. * * @param format A format string which generates the string to append * @param arguments The arguments used in the format string * @return A new, autoreleased OFString with the specified format appended */ -- (OFString*)stringByAppendingFormat: (OFConstantString*)format - arguments: (va_list)arguments; +- (OFString *)stringByAppendingFormat: (OFConstantString *)format + arguments: (va_list)arguments; /*! * @brief Creates a new string by appending a path component. * * @param component The path component to append * @return A new, autoreleased OFString with the path component appended */ -- (OFString*)stringByAppendingPathComponent: (OFString*)component; +- (OFString *)stringByAppendingPathComponent: (OFString *)component; /*! * @brief Creates a new string by prepending another string. * * @param string The string to prepend * @return A new autoreleased OFString with the specified string prepended */ -- (OFString*)stringByPrependingString: (OFString*)string; +- (OFString *)stringByPrependingString: (OFString *)string; /*! * @brief Creates a new string by replacing the occurrences of the specified * string with the specified replacement. * * @param string The string to replace * @param replacement The string with which it should be replaced * @return A new string with the occurrences of the specified string replaced */ -- (OFString*)stringByReplacingOccurrencesOfString: (OFString*)string - withString: (OFString*)replacement; +- (OFString *)stringByReplacingOccurrencesOfString: (OFString *)string + withString: (OFString *)replacement; /*! * @brief Creates a new string by replacing the occurrences of the specified * string in the specified range with the specified replacement. * @@ -825,28 +828,28 @@ * Possible values are: * * None yet * @param range The range in which to replace the string * @return A new string with the occurrences of the specified string replaced */ -- (OFString*)stringByReplacingOccurrencesOfString: (OFString*)string - withString: (OFString*)replacement - options: (int)options - range: (of_range_t)range; +- (OFString *)stringByReplacingOccurrencesOfString: (OFString *)string + withString: (OFString *)replacement + options: (int)options + range: (of_range_t)range; /*! * @brief Returns the string in uppercase. * * @return The string in uppercase */ -- (OFString*)uppercaseString; +- (OFString *)uppercaseString; /*! * @brief Returns the string in lowercase. * * @return The string in lowercase */ -- (OFString*)lowercaseString; +- (OFString *)lowercaseString; /*! * @brief Returns the string capitalized. * * @note This only considers spaces, tabs and newlines to be word delimiters! @@ -853,58 +856,58 @@ * Also note that this might change in the future to all word delimiters * specified by Unicode! * * @return The capitalized string */ -- (OFString*)capitalizedString; +- (OFString *)capitalizedString; /*! * @brief Creates a new string by deleting leading whitespaces. * * @return A new autoreleased OFString with leading whitespaces deleted */ -- (OFString*)stringByDeletingLeadingWhitespaces; +- (OFString *)stringByDeletingLeadingWhitespaces; /*! * @brief Creates a new string by deleting trailing whitespaces. * * @return A new autoreleased OFString with trailing whitespaces deleted */ -- (OFString*)stringByDeletingTrailingWhitespaces; +- (OFString *)stringByDeletingTrailingWhitespaces; /*! * @brief Creates a new string by deleting leading and trailing whitespaces. * * @return A new autoreleased OFString with leading and trailing whitespaces * deleted */ -- (OFString*)stringByDeletingEnclosingWhitespaces; +- (OFString *)stringByDeletingEnclosingWhitespaces; /*! * @brief Checks whether the string has the specified prefix. * * @param prefix The prefix to check for * @return A boolean whether the string has the specified prefix */ -- (bool)hasPrefix: (OFString*)prefix; +- (bool)hasPrefix: (OFString *)prefix; /*! * @brief Checks whether the string has the specified suffix. * * @param suffix The suffix to check for * @return A boolean whether the string has the specified suffix */ -- (bool)hasSuffix: (OFString*)suffix; +- (bool)hasSuffix: (OFString *)suffix; /*! * @brief Separates an OFString into an OFArray of OFStrings. * * @param delimiter The delimiter for separating * @return An autoreleased OFArray with the separated string */ -- (OFArray OF_GENERIC(OFString*)*)componentsSeparatedByString: - (OFString*)delimiter; +- (OFArray OF_GENERIC(OFString *) *)componentsSeparatedByString: + (OFString *)delimiter; /*! * @brief Separates an OFString into an OFArray of OFStrings. * * @param delimiter The delimiter for separating @@ -913,65 +916,65 @@ * Value | Description * -----------------------|---------------------- * `OF_STRING_SKIP_EMPTY` | Skip empty components * @return An autoreleased OFArray with the separated string */ -- (OFArray OF_GENERIC(OFString*)*) - componentsSeparatedByString: (OFString*)delimiter +- (OFArray OF_GENERIC(OFString *) *) + componentsSeparatedByString: (OFString *)delimiter options: (int)options; /*! * @brief Returns the components of the path. * * @return The components of the path */ -- (OFArray OF_GENERIC(OFString*)*)pathComponents; +- (OFArray OF_GENERIC(OFString *) *)pathComponents; /*! * @brief Returns the last component of the path. * * @return The last component of the path */ -- (OFString*)lastPathComponent; +- (OFString *)lastPathComponent; /*! * @brief Returns the file extension of the path. * * @return The file extension of the path */ -- (OFString*)pathExtension; +- (OFString *)pathExtension; /*! * @brief Returns the directory name of the path. * * @return The directory name of the path */ -- (OFString*)stringByDeletingLastPathComponent; +- (OFString *)stringByDeletingLastPathComponent; /*! * @brief Returns a new string with the file extension of the path removed. * * @return A new string with the file extension of the path removed */ -- (OFString*)stringByDeletingPathExtension; +- (OFString *)stringByDeletingPathExtension; /*! * @brief Returns the path with relative sub paths resolved. * * @return The path with relative sub paths resolved */ -- (OFString*)stringByStandardizingPath; +- (OFString *)stringByStandardizingPath; /*! * @brief Returns the URL path with relative sub paths resolved. * * This works similar to @ref stringByStandardizingPath, but is intended for * standardization of paths that are part of a URL. * * @return The URL path with relative sub paths resolved */ -- (OFString*)stringByStandardizingURLPath; +- (OFString *)stringByStandardizingURLPath; /*! * @brief Returns the decimal value of the string as an `intmax_t`. * * Leading and trailing whitespaces are ignored. @@ -1043,11 +1046,11 @@ * use the result outside the scope of the current autorelease pool, you have to * copy it. * * @return The string as an array of Unicode characters */ -- (const of_unichar_t*)characters OF_RETURNS_INNER_POINTER; +- (const of_unichar_t *)characters OF_RETURNS_INNER_POINTER; /*! * @brief Returns the string in UTF-16 encoding with native byte order. * * The result is valid until the autorelease pool is released. If you want to @@ -1054,11 +1057,11 @@ * use the result outside the scope of the current autorelease pool, you have to * copy it. * * @return The string in UTF-16 encoding with native byte order */ -- (const of_char16_t*)UTF16String OF_RETURNS_INNER_POINTER; +- (const of_char16_t *)UTF16String OF_RETURNS_INNER_POINTER; /*! * @brief Returns the string in UTF-16 encoding with the specified byte order. * * The result is valid until the autorelease pool is released. If you want to @@ -1066,11 +1069,11 @@ * copy it. * * @param byteOrder The byte order for the UTF-16 encoding * @return The string in UTF-16 encoding with the specified byte order */ -- (const of_char16_t*)UTF16StringWithByteOrder: (of_byte_order_t)byteOrder +- (const of_char16_t *)UTF16StringWithByteOrder: (of_byte_order_t)byteOrder OF_RETURNS_INNER_POINTER; /*! * @brief Returns the length of the string in UTF-16 characters. * @@ -1085,11 +1088,11 @@ * use the result outside the scope of the current autorelease pool, you have to * copy it. * * @return The string in UTF-32 encoding with native byte order */ -- (const of_char32_t*)UTF32String OF_RETURNS_INNER_POINTER; +- (const of_char32_t *)UTF32String OF_RETURNS_INNER_POINTER; /*! * @brief Returns the string in UTF-32 encoding with the specified byte order. * * The result is valid until the autorelease pool is released. If you want to @@ -1097,29 +1100,29 @@ * copy it. * * @param byteOrder The byte order for the UTF-32 encoding * @return The string in UTF-32 encoding with the specified byte order */ -- (const of_char32_t*)UTF32StringWithByteOrder: (of_byte_order_t)byteOrder +- (const of_char32_t *)UTF32StringWithByteOrder: (of_byte_order_t)byteOrder OF_RETURNS_INNER_POINTER; #ifdef OF_HAVE_FILES /*! * @brief Writes the string into the specified file using UTF-8 encoding. * * @param path The path of the file to write to */ -- (void)writeToFile: (OFString*)path; +- (void)writeToFile: (OFString *)path; /*! * @brief Writes the string into the specified file using the specified * encoding. * * @param path The path of the file to write to * @param encoding The encoding to use to write the string into the file */ -- (void)writeToFile: (OFString*)path +- (void)writeToFile: (OFString *)path encoding: (of_string_encoding_t)encoding; #endif #ifdef OF_HAVE_BLOCKS /*! @@ -1132,15 +1135,15 @@ @end #ifdef __cplusplus extern "C" { #endif -extern of_string_encoding_t of_string_parse_encoding(OFString*); -extern size_t of_string_utf8_encode(of_unichar_t, char*); -extern ssize_t of_string_utf8_decode(const char*, size_t, of_unichar_t*); -extern size_t of_string_utf16_length(const of_char16_t*); -extern size_t of_string_utf32_length(const of_char32_t*); +extern of_string_encoding_t of_string_parse_encoding(OFString *); +extern size_t of_string_utf8_encode(of_unichar_t, char *); +extern ssize_t of_string_utf8_decode(const char *, size_t, of_unichar_t *); +extern size_t of_string_utf16_length(const of_char16_t *); +extern size_t of_string_utf32_length(const of_char32_t *); #ifdef __cplusplus } #endif OF_ASSUME_NONNULL_END