FileScrewdriver extension
provides extensions for File
- on
Properties
-
isEmpty
→ Future<
bool> -
Available on File, provided by the FileScrewdriver extension
Returns a Future containing a bool indicating whetherthis
file is empty or not.no setter - isEmptySync → bool
-
Available on File, provided by the FileScrewdriver extension
Returns true ifthis
file is emptyno setter
Methods
-
appendBytes(
List< int> value) → Future<void> -
Available on File, provided by the FileScrewdriver extension
Appendsvalue
bytes at the end of the file. -
appendBytesSync(
List< int> value) → Future<void> -
Available on File, provided by the FileScrewdriver extension
Appendsvalue
bytes at the end of the file. -
appendFrom(
File file) → Future< void> -
Available on File, provided by the FileScrewdriver extension
Appends content offile
at the end ofthis
file. -
appendFromSync(
File file) → void -
Available on File, provided by the FileScrewdriver extension
Appends content offile
at the end ofthis
file. -
appendString(
String value, {Encoding encoding = utf8}) → Future< void> -
Available on File, provided by the FileScrewdriver extension
Appendsvalue
string at the end of the file using providedencoding
. -
appendStringLine(
String value, {Encoding encoding = utf8}) → Future< void> -
Available on File, provided by the FileScrewdriver extension
Appendsvalue
string as a new line at the end of the file using providedencoding
. -
appendStringSync(
String value, {Encoding encoding = utf8}) → void -
Available on File, provided by the FileScrewdriver extension
Appendsvalue
string at the end of the file using providedencoding
. -
clear(
) → Future< void> -
Available on File, provided by the FileScrewdriver extension
Asynchronously flushes all the data inthis
file leaving it to be empty. -
clearSync(
) → void -
Available on File, provided by the FileScrewdriver extension
Synchronously flushes all the data inthis
file leaving it to be empty. -
copyTo(
File other) → Future< void> -
Available on File, provided by the FileScrewdriver extension
Copies content ofthis
toother
file. -
onDeleted(
void block()) → StreamSubscription< FileSystemEvent> -
Available on File, provided by the FileScrewdriver extension
Callsblock
whenever thethis
file is deleted. Returns StreamSubscription which allows to cancel the listener. -
onModified(
void block()) → StreamSubscription< FileSystemEvent> -
Available on File, provided by the FileScrewdriver extension
Callsblock
whenever thethis
file is modified. Returns StreamSubscription which allows to cancel the listener.
Operators
-
operator +(
File file) → void -
Available on File, provided by the FileScrewdriver extension
Allows to append content offile
tothis
. -
operator <<(
String value) → void -
Available on File, provided by the FileScrewdriver extension
operator that allows to appendvalue
string at the end of the file using provided UTF-8 encoding.