class js.html.FileReader extends EventTarget
Available on js
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. File objects may be obtained in one of two ways: from a FileList
object returned as a result of a user selecting files using the <input>
element, or from a drag and drop operation's DataTransfer
object.
To create a FileReader
, simply do the following:
var reader = new FileReader();
See Using files from web applications for details and examples.
Documentation for this class was provided by MDN.
Class Fields
Instance Fields
Called when the read is completed, whether successful or not. This is called after either onload
or onerror
.
var readyState:Int
Indicates the state of the FileReader
. This will be one of the State constants. Read only.