A simple C++ Vector class, used as replacement for std::vector. More...
#include <m2mvector.h>
Public Types | |
enum | { MIN_CAPACITY = 1 } |
typedef ObjectTemplate * | iterator |
typedef const ObjectTemplate * | const_iterator |
Public Member Functions | |
Vector (int init_size=MIN_CAPACITY) | |
Vector (const Vector &rhs) | |
const Vector & | operator= (const Vector &rhs) |
void | resize (int new_size) |
void | reserve (int new_capacity) |
ObjectTemplate & | operator[] (int idx) |
const ObjectTemplate & | operator[] (int idx) const |
bool | empty () const |
int | size () const |
int | capacity () const |
void | push_back (const ObjectTemplate &x) |
void | pop_back () |
void | clear () |
const ObjectTemplate & | back () const |
iterator | begin () |
const_iterator | begin () const |
iterator | end () |
const_iterator | end () const |
void | erase (int position) |
A simple C++ Vector class, used as replacement for std::vector.