gio.pollable_output_stream
Module for PollableOutputStream interface
Types 2
interfacePollableOutputStream
gio.pollable_output_stream.PollableOutputStream is implemented by gio.output_stream.OutputStreams that can be polled for readiness to write. This can be used when interfacing with a non-GIO API that expects UNIX-file-descriptor-style asynchronous I/O rather than GIO-style.
Some classes may implement gio.pollable_output_stream.PollableOutputStream but have only certain instances of that class be pollable. If gio.pollable_output_stream.PollableOutputStream.canPoll returns false, then the behavior of other gio.pollable_output_stream.PollableOutputStream methods is undefined.
Methods
bool canPoll()Checks if stream is actually pollable. Some classes may implement #GPollableOutputStream but have only certain instances of that class be pollable. If this method returns false, then the behavior o...glib.source.Source createSource(gio.cancellable.Cancellable cancellable = null)Creates a #GSource that triggers when stream can be written, or cancellable is triggered or an error occurs. The callback on the source is of the #GPollableSourceFunc type.bool isWritable()Checks if stream can be written.ptrdiff_t writeNonblocking(ubyte[] buffer, gio.cancellable.Cancellable cancellable = null)Attempts to write up to count bytes from buffer to stream, as with [gio.output_stream.OutputStream.write]. If stream is not currently writable, this will immediately return [gio.types.IOErrorEnum.W...gio.types.PollableReturn writevNonblocking(gio.types.OutputVector[] vectors, out size_t bytesWritten, gio.cancellable.Cancellable cancellable = null)Attempts to write the bytes contained in the n_vectors vectors to stream, as with [gio.output_stream.OutputStream.writev]. If stream is not currently writable, this will immediately return %G_POLLA...interfacePollableOutputStreamGidBuilderImpl(T)
Fluent builder implementation template for gio.pollable_output_stream.PollableOutputStream