mirror of
https://github.com/gnustep/libs-base.git
synced 2025-05-31 08:41:03 +00:00
Add two previously unimplemented methods.
git-svn-id: svn+ssh://svn.gna.org/svn/gnustep/libs/base/trunk@28252 72102866-910b-0410-8b05-ffd578937521
This commit is contained in:
parent
0acc1506cd
commit
fd2861f3ae
3 changed files with 355 additions and 316 deletions
|
@ -102,12 +102,23 @@ enum {
|
|||
- (BOOL) isEqualToData: (NSData*)other;
|
||||
- (NSUInteger) length;
|
||||
|
||||
// Storing Data
|
||||
|
||||
/**
|
||||
* <p>Writes a copy of the data encapsulated by the receiver to a file
|
||||
* at path. If the useAuxiliaryFile flag is YES, this writes to a
|
||||
* temporary file and then renames that to the file at path, thus
|
||||
* ensuring that path exists and does not contain partially written
|
||||
* data at any point.
|
||||
* </p>
|
||||
* <p>On success returns YES, on failure returns NO.
|
||||
* </p>
|
||||
*/
|
||||
- (BOOL) writeToFile: (NSString*)path
|
||||
atomically: (BOOL)useAuxiliaryFile;
|
||||
|
||||
#if OS_API_VERSION(GS_API_MACOSX, GS_API_LATEST)
|
||||
/**
|
||||
* Writes a copy of the contents of the receiver to the specified URL.
|
||||
*/
|
||||
- (BOOL) writeToURL: (NSURL*)anURL atomically: (BOOL)flag;
|
||||
#endif
|
||||
|
||||
|
@ -131,11 +142,23 @@ enum {
|
|||
atIndex: (unsigned int)index;
|
||||
|
||||
#if OS_API_VERSION(100400,GS_API_LATEST)
|
||||
/** Not implemented */
|
||||
/**
|
||||
* <p>Writes a copy of the data encapsulated by the receiver to a file
|
||||
* at path. If the NSAtomicWrite option is set, this writes to a
|
||||
* temporary file and then renames that to the file at path, thus
|
||||
* ensuring that path exists and does not contain partially written
|
||||
* data at any point.
|
||||
* </p>
|
||||
* <p>On success returns YES, on failure returns NO.
|
||||
* </p>
|
||||
*/
|
||||
- (BOOL) writeToFile: (NSString *)path
|
||||
options: (NSUInteger)writeOptionsMask
|
||||
error: (NSError **)errorPtr;
|
||||
/** Not implemented */
|
||||
|
||||
/**
|
||||
* Writes a copy of the contents of the receiver to the specified URL.
|
||||
*/
|
||||
- (BOOL) writeToURL: (NSURL *)url
|
||||
options: (NSUInteger)writeOptionsMask
|
||||
error: (NSError **)errorPtr;
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue