nabto_device_virtual_stream_close()

DESCRIPTION

Close a stream. When a stream has been closed no further data can be written to the stream. Data can however still be read from the stream until the other peer closes the stream.

When the future resolves, all data written has been read by the other peer.

DECLARATION

    NABTO_DEVICE_DECL_PREFIX void NABTO_DEVICE_API
        nabto_device_virtual_stream_close(NabtoDeviceVirtualStream* stream, NabtoDeviceFuture* future)

PARAMETERS

stream:
[in] The stream to close.
future:
[in] Future to resolve when closed.

RETURNS

  • NABTO_DEVICE_EC_OK: on success.