Roc Toolkit internal modules
Roc Toolkit: real-time audio streaming
Loading...
Searching...
No Matches
roc::core::StandardAllocation Class Reference

Allocation policy for objects (de)allocated using IAllocator. More...

#include <allocation_policy.h>

Inheritance diagram for roc::core::StandardAllocation:
roc::core::RefCounted< BasicControlEndpoint, core::StandardAllocation > roc::core::RefCounted< BasicPort, core::StandardAllocation > roc::core::RefCounted< ReceiverEndpoint, core::StandardAllocation > roc::core::RefCounted< ReceiverSession, core::StandardAllocation > roc::core::RefCounted< ReceiverSlot, core::StandardAllocation > roc::core::RefCounted< SenderSlot, core::StandardAllocation > roc::core::RefCounted< MediaDescription, core::StandardAllocation > roc::ctl::BasicControlEndpoint roc::netio::BasicPort roc::pipeline::ReceiverEndpoint roc::pipeline::ReceiverSession roc::pipeline::ReceiverSlot roc::pipeline::SenderSlot roc::sdp::MediaDescription roc::netio::TcpConnectionPort roc::netio::TcpServerPort roc::netio::UdpReceiverPort roc::netio::UdpSenderPort

Public Member Functions

 StandardAllocation ()
 Initialize in invalid state. Such instance wont be usable.
 
 StandardAllocation (IAllocator &allocator)
 Initialize with given allocator. Such instance will use allocator to destroy objects.
 
template<class T >
void destroy (T &object)
 Destroy object and deallocate its memory.
 

Protected Member Functions

IAllocatorallocator () const
 Get allocator.
 

Detailed Description

Allocation policy for objects (de)allocated using IAllocator.

Definition at line 22 of file allocation_policy.h.

Constructor & Destructor Documentation

◆ StandardAllocation() [1/2]

roc::core::StandardAllocation::StandardAllocation ( )
inline

Initialize in invalid state. Such instance wont be usable.

Definition at line 26 of file allocation_policy.h.

◆ StandardAllocation() [2/2]

roc::core::StandardAllocation::StandardAllocation ( IAllocator allocator)
inline

Initialize with given allocator. Such instance will use allocator to destroy objects.

Definition at line 32 of file allocation_policy.h.

Member Function Documentation

◆ allocator()

IAllocator & roc::core::StandardAllocation::allocator ( ) const
inlineprotected

Get allocator.

Definition at line 46 of file allocation_policy.h.

◆ destroy()

template<class T >
void roc::core::StandardAllocation::destroy ( T &  object)
inline

Destroy object and deallocate its memory.

Definition at line 37 of file allocation_policy.h.


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