WritePipe class
The "write" end of an Pipe created by Pipe.create.
final pipe = await Pipe.create();
pipe.write.add("Hello World!".codeUnits);
pipe.write.close(); - Implemented types
Constructors
- WritePipe()
Properties
- done → Future read-onlyinherited
- A future that will complete when the consumer closes, or when an error occurs.
- encoding ↔ Encoding read / writeinherited
- The Encoding used when writing strings.
- hashCode → int read-onlyinherited
- The hash code for this object.
- runtimeType → Type read-onlyinherited
- A representation of the runtime type of the object.
Methods
- add(
List< int> data) → voidinherited - Adds byte
datato the target consumer, ignoring encoding. - addError(
Object error, [StackTrace? stackTrace]) → void inherited - Passes the error to the target consumer as an error event.
- addStream(
Stream< List< stream) → Futureint> >inherited - Adds all elements of the given
stream. - close(
) → Future inherited - Close the target consumer.
- flush(
) → Future inherited - Returns a Future that completes once all buffered data is accepted by the underlying StreamConsumer.
- noSuchMethod(
Invocation invocation) → dynamic inherited - Invoked when a non-existent method or property is accessed.
- toString(
) → String inherited - A string representation of this object.
- write(
Object? object) → void inherited - Converts
objectto a String by invoking Object.toString and adds the encoding of the result to the target consumer. - writeAll(
Iterable objects, [String separator = ""]) → void inherited - Iterates over the given
objectsand writes them in sequence. - writeCharCode(
int charCode) → void inherited - Writes the character of
charCode. - writeln(
[Object? object = ""]) → void inherited - Converts
objectto a String by invoking Object.toString and writes the result tothis, followed by a newline.
Operators
- operator ==(
Object other) → bool inherited - The equality operator.
© 2012 the Dart project authors
Licensed under the BSD 3-Clause "New" or "Revised" License.
https://api.dart.dev/stable/2.19.6/dart-io/WritePipe-class.html