Roc Toolkit internal modules
Roc Toolkit: real-time audio streaming
Loading...
Searching...
No Matches
connection_data.h
Go to the documentation of this file.
1/*
2 * Copyright (c) 2019 Roc Streaming authors
3 *
4 * This Source Code Form is subject to the terms of the Mozilla Public
5 * License, v. 2.0. If a copy of the MPL was not distributed with this
6 * file, You can obtain one at http://mozilla.org/MPL/2.0/.
7 */
8
9//! @file roc_sdp/connection_data.h
10//! @brief Connection field in a SDP.
11
12#ifndef ROC_SDP_CONNECTION_DATA_H_
13#define ROC_SDP_CONNECTION_DATA_H_
14
16#include "roc_core/attributes.h"
17#include "roc_core/list_node.h"
18#include "roc_core/log.h"
21
22namespace roc {
23namespace sdp {
24
25//! SDP connection data field.
27public:
28 //! Initialize empty connection data.
30
31 //! Clear all fields.
32 void clear();
33
34 //! Check and set connection address from a string.
36 set_connection_address(address::AddrFamily addrtype, const char* str, size_t str_len);
37
38 //! The SocketAddr of the ConnectionData.
40
41private:
42 address::SocketAddr connection_address_;
43};
44
45} // namespace sdp
46} // namespace roc
47
48#endif // ROC_SDP_CONNECTION_DATA_H_
Compiler attributes.
#define ROC_ATTR_NODISCARD
Emit warning if function result is not checked.
Definition attributes.h:31
SDP connection data field.
bool set_connection_address(address::AddrFamily addrtype, const char *str, size_t str_len)
Check and set connection address from a string.
const address::SocketAddr & connection_address() const
The SocketAddr of the ConnectionData.
ConnectionData()
Initialize empty connection data.
void clear()
Clear all fields.
Linked list node.
Logging.
AddrFamily
Address family.
Definition addr_family.h:19
Root namespace.
Socket address.
String buffer.
String builder.