diff options
Diffstat (limited to 'iPhone/CordovaLib/Classes/CDVFile.h')
-rwxr-xr-x | iPhone/CordovaLib/Classes/CDVFile.h | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/iPhone/CordovaLib/Classes/CDVFile.h b/iPhone/CordovaLib/Classes/CDVFile.h index 4862921..017b066 100755 --- a/iPhone/CordovaLib/Classes/CDVFile.h +++ b/iPhone/CordovaLib/Classes/CDVFile.h @@ -21,6 +21,7 @@ #import "CDVPlugin.h" enum CDVFileError { + NO_ERROR = 0, NOT_FOUND_ERR = 1, SECURITY_ERR = 2, ABORT_ERR = 3, @@ -76,6 +77,7 @@ extern NSString* const kCDVAssetsLibraryPrefix; - (void)readAsText:(CDVInvokedUrlCommand*)command; - (void)readAsDataURL:(CDVInvokedUrlCommand*)command; +- (void)readAsArrayBuffer:(CDVInvokedUrlCommand*)command; - (NSString*)getMimeTypeFromPath:(NSString*)fullPath; - (void)write:(CDVInvokedUrlCommand*)command; - (void)testFileExists:(CDVInvokedUrlCommand*)command; @@ -88,7 +90,8 @@ extern NSString* const kCDVAssetsLibraryPrefix; // - (BOOL) fileExists:(NSString*)fileName; // - (BOOL) directoryExists:(NSString*)dirName; -- (void)writeToFile:(NSString*)fileName withData:(NSString*)data append:(BOOL)shouldAppend callback:(NSString*)callbackId; +- (void)writeToFile:(NSString*)fileName withData:(NSData*)data append:(BOOL)shouldAppend callback:(NSString*)callbackId; +- (void)writeToFile:(NSString*)fileName withString:(NSString*)data encoding:(NSStringEncoding)encoding append:(BOOL)shouldAppend callback:(NSString*)callbackId; - (unsigned long long)truncateFile:(NSString*)filePath atPosition:(unsigned long long)pos; @property (nonatomic, strong) NSString* appDocsPath; |