RTSP listener that matches incoming clients to pending launch sessions.
More...
|
| int | bind (net::af_e af, std::uint16_t port, boost::system::error_code &ec) |
| | Bind the underlying socket or graphics resource to its target.
|
| |
| void | clear (bool all=true) |
| | Clear launch sessions.
|
| |
| void | clear_by_cert (std::string_view cert) |
| | Clear by cert state.
|
| |
| void | handle_accept (const boost::system::error_code &ec) |
| | Accept a pending connection and arm the server for the next client.
|
| |
| void | handle_msg (tcp::socket &sock, launch_session_t &session, msg_t &&req) |
| | Dispatch a parsed RTSP request to its handler.
|
| |
| void | insert (const std::shared_ptr< stream::session_t > &session) |
| | Inserts the provided session into the set of sessions.
|
| |
|
void | iterate () |
| | Runs an iteration of the RTSP server loop.
|
| |
| void | map (const std::string_view &type, cmd_func_t cb) |
| | Register or visit handlers stored in the map.
|
| |
| void | remove (const std::shared_ptr< stream::session_t > &session) |
| | Removes the provided session from the set of sessions.
|
| |
| void | session_clear (uint32_t launch_session_id) |
| | Clear state for the oldest launch session.
|
| |
| int | session_count () |
| | Get the number of active sessions.
|
| |
| void | session_raise (std::shared_ptr< launch_session_t > launch_session) |
| | Launch a new streaming session.
|
| |
|
void | stop () |
| | Stop the RTSP server.
|
| |
RTSP listener that matches incoming clients to pending launch sessions.
◆ bind()
| int rtsp_stream::rtsp_server_t::bind |
( |
net::af_e | af, |
|
|
std::uint16_t | port, |
|
|
boost::system::error_code & | ec ) |
|
inline |
Bind the underlying socket or graphics resource to its target.
- Parameters
-
| af | Address family used for socket creation or binding. |
| port | TCP or UDP port number. |
| ec | Error code returned by the asynchronous operation. |
- Returns
- Network operation status.
◆ clear()
| void rtsp_stream::rtsp_server_t::clear |
( |
bool | all = true | ) |
|
|
inline |
Clear launch sessions.
- Parameters
-
| all | If true, clear all sessions. Otherwise, only clear timed out and stopped sessions. |
*Examples**
void clear(bool all=true)
Clear launch sessions.
Definition rtsp.cpp:651
◆ clear_by_cert()
| void rtsp_stream::rtsp_server_t::clear_by_cert |
( |
std::string_view | cert | ) |
|
|
inline |
Clear by cert state.
- Parameters
-
| cert | Certificate data or object used by the operation. |
◆ handle_accept()
| void rtsp_stream::rtsp_server_t::handle_accept |
( |
const boost::system::error_code & | ec | ) |
|
|
inline |
Accept a pending connection and arm the server for the next client.
- Parameters
-
| ec | Error code returned by the asynchronous operation. |
◆ handle_msg()
| void rtsp_stream::rtsp_server_t::handle_msg |
( |
tcp::socket & | sock, |
|
|
launch_session_t & | session, |
|
|
msg_t && | req ) |
|
inline |
Dispatch a parsed RTSP request to its handler.
- Parameters
-
| sock | Socket used to read or write the protocol message. |
| session | Active streaming or pairing session for the request. |
| req | Parsed RTSP request being handled. |
◆ insert()
| void rtsp_stream::rtsp_server_t::insert |
( |
const std::shared_ptr< stream::session_t > & | session | ) |
|
|
inline |
Inserts the provided session into the set of sessions.
- Parameters
-
| session | The session to insert. |
◆ map()
| void rtsp_stream::rtsp_server_t::map |
( |
const std::string_view & | type, |
|
|
cmd_func_t | cb ) |
|
inline |
Register or visit handlers stored in the map.
- Parameters
-
| type | Protocol, message, or resource type selector. |
| cb | Callback invoked for each matching message or session. |
◆ remove()
| void rtsp_stream::rtsp_server_t::remove |
( |
const std::shared_ptr< stream::session_t > & | session | ) |
|
|
inline |
Removes the provided session from the set of sessions.
- Parameters
-
| session | The session to remove. |
◆ session_clear()
| void rtsp_stream::rtsp_server_t::session_clear |
( |
uint32_t | launch_session_id | ) |
|
|
inline |
Clear state for the oldest launch session.
- Parameters
-
| launch_session_id | The ID of the session to clear. |
◆ session_count()
| int rtsp_stream::rtsp_server_t::session_count |
( |
| ) |
|
|
inline |
Get the number of active sessions.
- Returns
- Count of active sessions.
◆ session_raise()
| void rtsp_stream::rtsp_server_t::session_raise |
( |
std::shared_ptr< launch_session_t > | launch_session | ) |
|
|
inline |
Launch a new streaming session.
- Note
- If the client does not begin streaming within the ping_timeout, the session will be discarded.
- Parameters
-
| launch_session | Streaming session information. |
The documentation for this class was generated from the following file: