Creates a SocketSource that triggers when this can
be written, or cancellable
is triggered or an error occurs.
The callback on the source is of the PollableSourceFunc type.
As with is_writable, it is possible that the stream may not actually be writable even after the source triggers, so you should use write_nonblocking rather than write from the callback.
this | |
cancellable |
a Cancellable, or null |
a new SocketSource |