- Main Page
- Modules
- Classes

- Class List
- Class Hierarchy
- Class Members

# IpeBuffer Class Reference
[Ipe Base]

A memory buffer. More...

List of all members.

## Public Member Functions

- IpeBuffer ()
- ~IpeBuffer ()
- IpeBuffer (const IpeBuffer &rhs)
- IpeBuffer & operator= (const IpeBuffer &rhs)
- IpeBuffer (int size)
- IpeBuffer (const char *data, int size)
- char & operator[] (int index)
- const char & operator[] (int index) const
- int size () const
- char * data ()
- const char * data () const

## Detailed Description

A memory buffer.

Implements sharing semantics using reference counting.

## Constructor & Destructor Documentation

IpeBuffer::IpeBuffer | ( |  | ) |

Create empty buffer.

IpeBuffer::~IpeBuffer | ( |  | ) |

Destructor.

IpeBuffer::IpeBuffer | ( | const IpeBuffer & | rhs | ) |

Copy constructor. Constant time, buffer is shared.

IpeBuffer::IpeBuffer | ( | int | size | ) | `[explicit]`

Create buffer of specified size.

IpeBuffer::IpeBuffer | ( | const char * | data,
|  | int | size |
| ) |  |  | `[explicit]`

Create buffer by copying the data.

## Member Function Documentation

IpeBuffer & IpeBuffer::operator= | ( | const IpeBuffer & | rhs | ) |

Assignment operator (constant-time).

char& IpeBuffer::operator[] | ( | int | index | ) | `[inline]`

Character access.

const char& IpeBuffer::operator[] | ( | int | index | ) | const`[inline]`

Character access (const version).

int IpeBuffer::size | ( |  | ) | const`[inline]`

Return size of buffer;.

char* IpeBuffer::data | ( |  | ) | `[inline]`

Return pointer to buffer data.

const char* IpeBuffer::data | ( |  | ) | const`[inline]`

Return pointer to buffer data (const version).

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

- ipebase.h
- ipebase.cpp