adchpp::Buffer Class Reference

Reference-counted buffer. More...

#include <Buffer.h>

Inheritance diagram for adchpp::Buffer:
Inheritance graph
[legend]
Collaboration diagram for adchpp::Buffer:
Collaboration graph
[legend]

List of all members.

Classes

struct  Clear

Public Member Functions

template<typename InputIterator >
void append (InputIterator start, InputIterator end)
 Buffer (const size_t size)
 Buffer (const void *ptr, const size_t size)
 Buffer (const std::string &str)
uint8_t * data ()
const uint8_t * data () const
void erase_first (size_t n)
 Erase the first n bytes.
 operator ByteVector & ()
 operator const ByteVector & () const
void resize (size_t new_size)
size_t size () const
virtual ~Buffer ()

Static Public Member Functions

static size_t getDefaultBufferSize ()
static void setDefaultBufferSize (size_t newSize)

Private Member Functions

ByteVectorbuf ()
const ByteVectorbuf () const

Private Attributes

ByteVectorbufp

Static Private Attributes

static size_t defaultBufferSize = 128
static ADCHPP_DLL SimplePool
< ByteVector, Clear
pool

Detailed Description

Reference-counted buffer.

Definition at line 30 of file Buffer.h.


Constructor & Destructor Documentation

adchpp::Buffer::Buffer ( const std::string &  str  )  [inline]

Definition at line 35 of file Buffer.h.

References append().

Here is the call graph for this function:

adchpp::Buffer::Buffer ( const void *  ptr,
const size_t  size 
) [inline]

Definition at line 36 of file Buffer.h.

References append().

Here is the call graph for this function:

adchpp::Buffer::Buffer ( const size_t  size  )  [inline]

Definition at line 37 of file Buffer.h.

References resize().

Here is the call graph for this function:

virtual adchpp::Buffer::~Buffer (  )  [inline, virtual]

Definition at line 56 of file Buffer.h.

References bufp, pool, and adchpp::SimplePool< T, Clear >::put().

Here is the call graph for this function:


Member Function Documentation

template<typename InputIterator >
void adchpp::Buffer::append ( InputIterator  start,
InputIterator  end 
) [inline]

Definition at line 51 of file Buffer.h.

References buf().

Referenced by Buffer().

Here is the call graph for this function:

Here is the caller graph for this function:

ByteVector& adchpp::Buffer::buf (  )  [inline, private]

Definition at line 61 of file Buffer.h.

References bufp.

const ByteVector& adchpp::Buffer::buf (  )  const [inline, private]

Definition at line 60 of file Buffer.h.

References bufp.

Referenced by append(), data(), erase_first(), operator ByteVector &(), operator const ByteVector &(), resize(), and size().

Here is the caller graph for this function:

uint8_t* adchpp::Buffer::data (  )  [inline]

Definition at line 45 of file Buffer.h.

References buf().

Here is the call graph for this function:

const uint8_t* adchpp::Buffer::data (  )  const [inline]

Definition at line 44 of file Buffer.h.

References buf().

Here is the call graph for this function:

void adchpp::Buffer::erase_first ( size_t  n  )  [inline]

Erase the first n bytes.

Definition at line 48 of file Buffer.h.

References buf().

Here is the call graph for this function:

static size_t adchpp::Buffer::getDefaultBufferSize (  )  [inline, static]

Definition at line 54 of file Buffer.h.

References defaultBufferSize.

Referenced by adchpp::Buffer::Clear::operator()().

Here is the caller graph for this function:

adchpp::Buffer::operator ByteVector & (  )  [inline]

Definition at line 40 of file Buffer.h.

References buf().

Here is the call graph for this function:

adchpp::Buffer::operator const ByteVector & (  )  const [inline]

Definition at line 39 of file Buffer.h.

References buf().

Here is the call graph for this function:

void adchpp::Buffer::resize ( size_t  new_size  )  [inline]

Definition at line 42 of file Buffer.h.

References buf().

Referenced by Buffer().

Here is the call graph for this function:

Here is the caller graph for this function:

static void adchpp::Buffer::setDefaultBufferSize ( size_t  newSize  )  [inline, static]

Definition at line 53 of file Buffer.h.

References defaultBufferSize.

size_t adchpp::Buffer::size (  )  const [inline]

Definition at line 43 of file Buffer.h.

References buf().

Here is the call graph for this function:


Member Data Documentation

Definition at line 63 of file Buffer.h.

Referenced by buf(), and ~Buffer().

size_t adchpp::Buffer::defaultBufferSize = 128 [static, private]

Definition at line 58 of file Buffer.h.

Referenced by getDefaultBufferSize(), and setDefaultBufferSize().

Definition at line 69 of file Buffer.h.

Referenced by ~Buffer().

Generated on Sat Nov 27 23:38:31 2010 for adchpp by  doxygen 1.6.3