Om  1.0.0
A universal framework for multimedia simulation
Public Member Functions | List of all members
om::sound::base::SharedSoundBuffer Class Reference

A class that represents a temporary handle to a shared SoundBuffer. More...

#include <omSoundSharedSoundBuffer.h>

Public Member Functions

 SharedSoundBuffer (const SharedSoundBuffer &other)
 Declare the copy constructor private so that instances of this class cannot be copied. More...
 
 ~SharedSoundBuffer ()
 Destroy this handle to a shared sound buffer, releasing it back to its pool. More...
 
SharedSoundBufferoperator= (const SharedSoundBuffer &other)
 Declare the assignment operator private so that instances of this class cannot be copied. More...
 
SoundBuffergetBuffer ()
 Return a reference to the underlying sound buffer that is being shared. More...
 
const SoundBuffergetBuffer () const
 Return a reference to the underlying sound buffer that is being shared. More...
 

Detailed Description

A class that represents a temporary handle to a shared SoundBuffer.

When this class is created, it obtains a handle to a shared sound buffer and locks that buffer from being used elsewhere. Once this object goes out of scope and is destructed, it releases its handle to that SoundBuffer, allowing its reuse.

Therefore, it is an illegal operation to retain a pointer to the shared SoundBuffer and use it after the associated SharedSoundBuffer instance has been destructed.

Constructor & Destructor Documentation

om::sound::base::SharedSoundBuffer::SharedSoundBuffer ( const SharedSoundBuffer other)
inline

Declare the copy constructor private so that instances of this class cannot be copied.

om::sound::base::SharedSoundBuffer::~SharedSoundBuffer ( )
inline

Destroy this handle to a shared sound buffer, releasing it back to its pool.

Member Function Documentation

SharedSoundBuffer& om::sound::base::SharedSoundBuffer::operator= ( const SharedSoundBuffer other)
inline

Declare the assignment operator private so that instances of this class cannot be copied.

SoundBuffer& om::sound::base::SharedSoundBuffer::getBuffer ( )
inline

Return a reference to the underlying sound buffer that is being shared.

const SoundBuffer& om::sound::base::SharedSoundBuffer::getBuffer ( ) const
inline

Return a reference to the underlying sound buffer that is being shared.


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