send


Description:

public ssize_t send (string buffer, size_t size, Cancellable? cancellable = null) throws Error

Send data (up to size bytes) from a stream.

On error -1 is returned and throws is set accordingly.

send can return any number of bytes, up to size. If more than size bytes have been sendd, the additional data will be returned in future calls to send.

If there is no data available, a g_io_error_would_block error will be returned.

Parameters:

this

the stream

buffer

a buffer to write data from (which should be at least size bytes long).

size

the number of bytes you want to write to the stream

cancellable

a gcancellable or null

Returns:

Number of bytes written.




2022 vala-language.org