The FileReader
object lets web applications asynchronously read the contents of files (or raw data buffers) stored on the user's computer, using File
or Blob
objects to specify the file or data to read.
Documentation FileReader by Mozilla Contributors, licensed under CC-BY-SA 2.5.
See:
Constructor
Variables
A handler for the error
event. This event is triggered each time the reading operation encounter an error.
A handler for the load
event. This event is triggered each time the reading operation is successfully completed.
A handler for the loadend
event. This event is triggered each time the reading operation is completed (either in success or failure).
A handler for the progress
event. This event is triggered while reading a Blob
content.
read onlyreadyState:Int
A number indicating the state of the FileReader
. This is one of the following:
EMPTY |
0 |
No data has been loaded yet. |
LOADING |
1 |
Data is currently being loaded. |
DONE |
2 |
The entire read request has been completed. |