Roc Toolkit internal modules
Roc Toolkit: real-time audio streaming
Loading...
Searching...
No Matches
roc::netio::UdpConfig Struct Reference

UDP port parameters. More...

#include <roc_netio/target_libuv/roc_netio/udp_port.h>

Public Member Functions

bool operator== (const UdpConfig &other) const
 Check two configs for equality.
 

Public Attributes

address::SocketAddr bind_address
 Port will bind to this address. If IP is zero, INADDR_ANY is used, i.e. the socket is bound to all network interfaces. If port is zero, a random free port is selected.
 
char multicast_interface [64]
 If not empty, port will join multicast group on the interface with given address. May be "0.0.0.0" or "[::]" to join on all interfaces. Used only if receiving is started.
 
bool enable_reuseaddr
 If set, enable SO_REUSEADDR when binding socket to non-ephemeral port. If not set, SO_REUSEADDR is enabled only for multicast sockets when binding to non-ephemeral port.
 
bool enable_non_blocking
 If true, allow non-blocking writes directly in write() method. If non-blocking write can't be performed, port falls back to regular asynchronous write. Used only if sending is started.
 

Detailed Description

UDP port parameters.

Definition at line 32 of file udp_port.h.

Constructor & Destructor Documentation

◆ UdpConfig()

roc::netio::UdpConfig::UdpConfig ( )
inline

Definition at line 54 of file udp_port.h.

Member Function Documentation

◆ operator==()

bool roc::netio::UdpConfig::operator== ( const UdpConfig other) const
inline

Check two configs for equality.

Definition at line 61 of file udp_port.h.

Member Data Documentation

◆ bind_address

address::SocketAddr roc::netio::UdpConfig::bind_address

Port will bind to this address. If IP is zero, INADDR_ANY is used, i.e. the socket is bound to all network interfaces. If port is zero, a random free port is selected.

Definition at line 36 of file udp_port.h.

◆ enable_non_blocking

bool roc::netio::UdpConfig::enable_non_blocking

If true, allow non-blocking writes directly in write() method. If non-blocking write can't be performed, port falls back to regular asynchronous write. Used only if sending is started.

Definition at line 52 of file udp_port.h.

◆ enable_reuseaddr

bool roc::netio::UdpConfig::enable_reuseaddr

If set, enable SO_REUSEADDR when binding socket to non-ephemeral port. If not set, SO_REUSEADDR is enabled only for multicast sockets when binding to non-ephemeral port.

Definition at line 46 of file udp_port.h.

◆ multicast_interface

char roc::netio::UdpConfig::multicast_interface[64]

If not empty, port will join multicast group on the interface with given address. May be "0.0.0.0" or "[::]" to join on all interfaces. Used only if receiving is started.

Definition at line 41 of file udp_port.h.


The documentation for this struct was generated from the following file: