uvgRTP 4.0.0
An open-source library for RTP/SRTP media delivery
Loading...
Searching...
No Matches
context.hh
1#pragma once
2
3#include "util.hh"
4#include "uvgrtp/export.hh"
5#include "uvgrtp/definitions.hh"
6
7#include <map>
8#include <string>
9
10
11namespace uvgrtp {
12
13 class session;
14 class socketfactory;
15
19 class UVGRTP_EXPORT context {
20 public:
29
38
50 session* create_session(const char* address);
51
64 session* create_session(const char* local_address, const char* remote_address);
65
78
86 bool crypto_enabled() const;
87
88#if UVGRTP_EXTENDED_API
89
101 uvgrtp::session* create_session(std::pair<std::string, std::string> addresses);
102
114 uvgrtp::session *create_session(std::string address);
115
117 // Obsolete method, replaced by create_session(std::pair<std::string, std::string> addresses);
118 uvgrtp::session *create_session(std::string remote_addr, std::string local_addr);
120#endif
121
122
123 private:
124
125 class context_impl;
126 context_impl* pimpl_;
127 };
128}
129
130namespace uvg_rtp = uvgrtp;
Provides CNAME isolation and can be used to create uvgrtp::session objects.
Definition context.hh:19
Provides ZRTP synchronization and can be used to create uvgrtp::media_stream objects.
Definition session.hh:30
bool crypto_enabled() const
Has Crypto++ been included in uvgRTP library.
rtp_error_t destroy_session(uvgrtp::session *session)
Destroy RTP session and all of its media streams.
~context()
RTP context destructor.
session * create_session(const char *local_address, const char *remote_address)
Create a new RTP session between two IP addresses.
context()
RTP context constructor.
session * create_session(const char *address)
Create a new RTP session.
uvgrtp::session * create_session(std::string address)
Create a new RTP session.
uvgrtp::session * create_session(std::pair< std::string, std::string > addresses)
Create a new RTP session between two IP addresses.