#include <Buffer.h>
Public Member Functions | |
T * | begin () |
Returns a pointer to the beginning of the buffer. | |
const T * | begin () const |
Returns a pointer to the beginning of the buffer. | |
Buffer (std::size_t size) | |
T * | end () |
Returns a pointer to end of the buffer. | |
const T * | end () const |
Returns a pointer to the end of the buffer. | |
T & | operator[] (std::size_t index) |
const T & | operator[] (std::size_t index) const |
std::size_t | size () const |
Returns the size of the buffer. | |
~Buffer () | |
Destroys the Buffer. | |
Private Member Functions | |
Buffer () | |
Buffer (const Buffer &) | |
Buffer & | operator= (const Buffer &) |
Private Attributes | |
T * | _ptr |
std::size_t | _size |
A very simple buffer class that allocates a buffer of a given type and size in the constructor and deallocates the buffer in the destructor.
This class is useful everywhere where a temporary buffer is needed.
Poco::Buffer< T >::Buffer | ( | std::size_t | size | ) | [inline] |
Poco::Buffer< T >::~Buffer | ( | ) | [inline] |
Poco::Buffer< T >::Buffer | ( | ) | [private] |
Poco::Buffer< T >::Buffer | ( | const Buffer< T > & | ) | [private] |
T* Poco::Buffer< T >::begin | ( | ) | [inline] |
const T* Poco::Buffer< T >::begin | ( | ) | const [inline] |
T* Poco::Buffer< T >::end | ( | ) | [inline] |
const T* Poco::Buffer< T >::end | ( | ) | const [inline] |
Buffer& Poco::Buffer< T >::operator= | ( | const Buffer< T > & | ) | [private] |
T& Poco::Buffer< T >::operator[] | ( | std::size_t | index | ) | [inline] |
const T& Poco::Buffer< T >::operator[] | ( | std::size_t | index | ) | const [inline] |
std::size_t Poco::Buffer< T >::size | ( | ) | const [inline] |
T* Poco::Buffer< T >::_ptr [private] |
std::size_t Poco::Buffer< T >::_size [private] |