@@ -115,11 +115,11 @@ * \return A new autoreleased OFString */ + stringWithString: (OFString*)str; /** - * Creates a new OFString with the contents of the specified file. + * 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 */ + stringWithContentsOfFile: (OFString*)path; @@ -364,13 +364,20 @@ * OFInvalidEncoding exception if the string contains any non-number characters. * * \return An OFNumber */ - (uintmax_t)hexadecimalValueAsInteger; + +/** + * 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; @end #import "OFConstString.h" #import "OFMutableString.h" #import "OFString+Hashing.h" #import "OFString+URLEncoding.h" #import "OFString+XMLEscaping.h" #import "OFString+XMLUnescaping.h"