HTML5 FileWriter


Supported Platform(s)

- BlackBerry PlayBook 1.0+
- BlackBerry 10
- Ripple Emulator
View Supported Platform Table
APIBB5.0BB6.0BB7.0PB1.0PB2.0BB10Ripple
abort       Y Y Y 
seek           YY
truncate           YY
write           YY
error       Y Y YY
fileName       Y Y YY
length       Y Y YY
onabort       Y Y YY
onerror       Y Y YY
onprogress       Y Y YY
onwrite       Y Y YY
onwriteend       Y Y YY
onwritestart       Y Y YY
position       Y Y YY
readyState       Y Y YY

Configuration Document Settings

To use all of the API described for this object, you must ensure the following settings are in your configuration document:

This API does not require a <feature> element to be declared in the configuration document of your BlackBerry WebWorks Application.

Permission Elements (PlayBook and BlackBerry 10+)
This API does not require a <permission> element to be declared in the configuration document of your BlackBerry WebWorks Application.

Functions

void abort
void seek
void truncate
void write

Properties

FileError error
String fileName
Long length
function onabort
function onerror
function onprogress
function onwrite
function onwriteend
function onwritestart
Long position
String readyState

Functions

void abort ()


Aborts writing file.


Supported Platforms
 - BlackBerry PlayBook 1.0+
 - BlackBerry 10

void seek (pointer : byte)


Moves the file pointer to the byte specified.


Supported Platforms
 - BlackBerry 10
 - Ripple Emulator


Parameters
pointer moves the pointer to the byte location specified

void truncate (pointer : byte)


Shortens the file to the length specified.


Supported Platforms
 - BlackBerry 10
 - Ripple Emulator


Parameters
pointer moved the end of file pointer to the location specified

void write (data : string)


Writes data to the file with a UTF-8 encoding.


Supported Platforms
 - BlackBerry 10
 - Ripple Emulator


Parameters
data written to the file in UTF-8 encoding

Properties

FileError error


object containing error


Supported Platforms
 - BlackBerry PlayBook 1.0+
 - BlackBerry 10
 - Ripple Emulator

String fileName


The name of the file to be written to


Supported Platforms
 - BlackBerry PlayBook 1.0+
 - BlackBerry 10
 - Ripple Emulator

Long length


lengh of the file to be written


Supported Platforms
 - BlackBerry PlayBook 1.0+
 - BlackBerry 10
 - Ripple Emulator

function onabort


function called when the file writing has been aborted


Supported Platforms
 - BlackBerry PlayBook 1.0+
 - BlackBerry 10
 - Ripple Emulator

function onerror


function called when there is an error during the file writing


Supported Platforms
 - BlackBerry PlayBook 1.0+
 - BlackBerry 10
 - Ripple Emulator

function onprogress


function called when writing is in progress


Supported Platforms
 - BlackBerry PlayBook 1.0+
 - BlackBerry 10
 - Ripple Emulator

function onwrite


function called when the request has completed successfully


Supported Platforms
 - BlackBerry PlayBook 1.0+
 - BlackBerry 10
 - Ripple Emulator

function onwriteend


function called when file writing has been completed


Supported Platforms
 - BlackBerry PlayBook 1.0+
 - BlackBerry 10
 - Ripple Emulator

function onwritestart


function called when the file writing starts


Supported Platforms
 - BlackBerry PlayBook 1.0+
 - BlackBerry 10
 - Ripple Emulator

Long position


current position of the file pointer


Supported Platforms
 - BlackBerry PlayBook 1.0+
 - BlackBerry 10
 - Ripple Emulator

String readyState


One of the three states the reader can be in INIT, WRITING or DONE.


Supported Platforms
 - BlackBerry PlayBook 1.0+
 - BlackBerry 10
 - Ripple Emulator

Documentation generated by JsDoc Toolkit 2.4.0 on Sun Dec 30 2012 18:15:38 GMT-0500 (EST)