interface FileEntry : Entry
(js)
createWriter |
abstract fun createWriter(successCallback: FileWriterCallback, errorCallback: ErrorCallback? = definedExternally): Unit |
(js)
file |
abstract fun file(successCallback: FileCallback, errorCallback: ErrorCallback? = definedExternally): Unit |
(js)
append |
Append file content from a Blob. suspend fun FileEntry.append(data: Blob): Result<FileEntry, FileException>
Append file content from a plain string. suspend fun FileEntry.append(data: String): Result<FileEntry, FileException> |
(js)
copyTo |
Copy given file or directory to a new location. suspend fun Entry.copyTo(parent: DirectoryEntry, newName: String? = null): Result<Entry, FileException> |
(js)
createWriter |
Create a FileWriter object for a given file entry. suspend fun FileEntry.createWriter(): Result<FileWriter, FileException> |
(js)
file |
Get a File object for a given file entry. suspend fun FileEntry.file(): Result<File, FileException> |
(js)
getMetadata |
Get file or directory metadata. suspend fun Entry.getMetadata(): Result<Metadata, FileException> |
(js)
getParent |
Get file or directory parent directory entry. suspend fun Entry.getParent(): Result<DirectoryEntry, FileException> |
(js)
moveTo |
Move given file or directory to a new location. suspend fun Entry.moveTo(parent: DirectoryEntry, newName: String? = null): Result<Entry, FileException> |
(js)
readAsArrayBuffer |
Read file content as an array buffer. suspend fun FileEntry.readAsArrayBuffer(): Result<ArrayBuffer, FileException> |
(js)
readAsDataURL |
Read file content as a data url. suspend fun FileEntry.readAsDataURL(): Result<String, FileException> |
(js)
readAsText |
Read file content as a plain string. suspend fun FileEntry.readAsText(): Result<String, FileException> |
(js)
remove |
Remove given file or directory. suspend fun Entry.remove(): Result<Entry, FileException> |
(js)
write |
Write file content from a Blob. suspend fun FileEntry.write(data: Blob): Result<FileEntry, FileException>
Write file content from a plain string. suspend fun FileEntry.write(data: String): Result<FileEntry, FileException>
Write file content from an array buffer. suspend fun FileEntry.write(data: ArrayBuffer): Result<FileEntry, FileException> |
(js)
writeDataUrL |
Write file content from a data url. suspend fun FileEntry.writeDataUrL(dataUrl: String): Result<FileEntry, FileException> |