Roc Toolkit internal modules
Roc Toolkit: real-time audio streaming
roc::netio::BasicPort Class Referenceabstract

Basic port interface. More...

#include <basic_port.h>

Inheritance diagram for roc::netio::BasicPort:
roc::core::RefCnt< BasicPort > roc::core::ListNode roc::core::NonCopyable< T > roc::core::NonCopyable< ListNode > roc::netio::UDPReceiverPort roc::netio::UDPSenderPort

Public Member Functions

 BasicPort (core::IAllocator &)
 Initialize. More...
 
virtual ~BasicPort ()
 Destroy. More...
 
virtual const packet::Addressaddress () const =0
 Get bind address. More...
 
virtual bool open ()=0
 Open port. More...
 
virtual void async_close ()=0
 Asynchronous close. More...
 
- Public Member Functions inherited from roc::core::RefCnt< BasicPort >
long getref () const
 Get reference counter. More...
 
void incref () const
 Increment reference counter. More...
 
void decref () const
 Decrement reference counter. More...
 
- Public Member Functions inherited from roc::core::ListNode
ListNodeDatalist_node_data () const
 Get list node data. More...
 

Friends

class core::RefCnt< BasicPort >
 

Detailed Description

Basic port interface.

Definition at line 24 of file basic_port.h.

Constructor & Destructor Documentation

◆ BasicPort()

roc::netio::BasicPort::BasicPort ( core::IAllocator )
explicit

Initialize.

◆ ~BasicPort()

virtual roc::netio::BasicPort::~BasicPort ( )
virtual

Destroy.

Member Function Documentation

◆ address()

virtual const packet::Address& roc::netio::BasicPort::address ( ) const
pure virtual

Get bind address.

Implemented in roc::netio::UDPSenderPort, and roc::netio::UDPReceiverPort.

◆ async_close()

virtual void roc::netio::BasicPort::async_close ( )
pure virtual

Asynchronous close.

Remarks
Should be called from the event loop thread.

Implemented in roc::netio::UDPSenderPort, and roc::netio::UDPReceiverPort.

◆ open()

virtual bool roc::netio::BasicPort::open ( )
pure virtual

Open port.

Remarks
Should be called from the event loop thread.

Implemented in roc::netio::UDPSenderPort, and roc::netio::UDPReceiverPort.


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