fstrm_tcp_writer is an interface for opening an fstrm_writer object that is backed by I/O on a TCP socket.
◆ fstrm_tcp_writer_options_init()
struct fstrm_tcp_writer_options * fstrm_tcp_writer_options_init |
( |
void | | ) |
|
Initialize an fstrm_tcp_writer_options object, which is needed to configure the socket address and socket port to be opened by the writer.
- Returns
- fstrm_tcp_writer_options object.
◆ fstrm_tcp_writer_options_destroy()
void fstrm_tcp_writer_options_destroy |
( |
struct fstrm_tcp_writer_options ** | twopt | ) |
|
Destroy an fstrm_tcp_writer_options object.
- Parameters
-
twopt | Pointer to fstrm_tcp_writer_options object. |
◆ fstrm_tcp_writer_options_set_socket_address()
void fstrm_tcp_writer_options_set_socket_address |
( |
struct fstrm_tcp_writer_options * | twopt, |
|
|
const char * | socket_address ) |
Set the socket_address option.
This is the IPv4 or IPv6 address in presentation format to be connected by the TCP socket.
- Parameters
-
twopt | fstrm_tcp_writer_options object. |
socket_address | The socket address. |
◆ fstrm_tcp_writer_options_set_socket_port()
void fstrm_tcp_writer_options_set_socket_port |
( |
struct fstrm_tcp_writer_options * | twopt, |
|
|
const char * | socket_port ) |
Set the socket_port option.
This is the TCP port number to be connected by the TCP socket.
- Parameters
-
twopt | fstrm_tcp_writer_options object. |
socket_port | The TCP socket port number provided as a character string. (When converted, the maximum allowed unsigned integer is 65535.) |
◆ fstrm_tcp_writer_init()
struct fstrm_writer * fstrm_tcp_writer_init |
( |
const struct fstrm_tcp_writer_options * | twopt, |
|
|
const struct fstrm_writer_options * | wopt ) |
Initialize the fstrm_writer object.
Note that the TCP socket will not actually be opened until a subsequent call to fstrm_writer_open().
- Parameters
-
twopt | fstrm_tcp_writer_options object. Must be non-NULL, and have the socket_address and socket_port options set. |
wopt | fstrm_writer_options object. May be NULL, in which chase default values will be used. |
- Returns
- fstrm_writer object.
- Return values
-