vcg::vector_occ< VALUE_TYPE > Class Template Reference

#include <vector_occ.h>

List of all members.

Public Member Functions

template<class ATTR_TYPE >
void Disable ()
 Note: once an attribute is disabled, its data is lost (the memory freed).
template<class ATTR_TYPE >
void Enable ()
 this function enable the use of an optional attribute (see...)
template<class ATTR_TYPE >
bool IsEnabled () const
 Note: once an attribute is disabled, its data is lost (the memory freed).
VALUE_TYPE * Pointer2begin ()
void pop_back ()
void push_back (const VALUE_TYPE &v)
void reserve (const unsigned int &size)
void resize (const unsigned int &size)
 vector_occ ()
 ~vector_occ ()

Public Attributes

std::list< CATBase< ThisType > * > attributes

Private Types

typedef vector_occ< VALUE_TYPE > ThisType
typedef std::vector< VALUE_TYPE > TT

Private Member Functions

void Update ()

Static Private Member Functions

static int & ID ()

Private Attributes

int id
VALUE_TYPE * old_start

Detailed Description

template<class VALUE_TYPE>
class vcg::vector_occ< VALUE_TYPE >

This class represent a vector_occ. A vector_occ is derived by a std::vector. The characteristic of a vector_occ is that you can add (at run time) new attributes to the container::value_type elements contained in the vector. (see the example..) The position in memory of a traced vector is kept by the Container Allocation Table, which is a (unique) list of vector_occ positions.

Definition at line 44 of file vector_occ.h.


Member Typedef Documentation

template<class VALUE_TYPE >
typedef vector_occ<VALUE_TYPE> vcg::vector_occ< VALUE_TYPE >::ThisType [private]

Definition at line 45 of file vector_occ.h.

template<class VALUE_TYPE >
typedef std::vector<VALUE_TYPE> vcg::vector_occ< VALUE_TYPE >::TT [private]

Definition at line 46 of file vector_occ.h.


Constructor & Destructor Documentation

template<class VALUE_TYPE >
vcg::vector_occ< VALUE_TYPE >::vector_occ (  )  [inline]

Definition at line 49 of file vector_occ.h.

template<class VALUE_TYPE >
vcg::vector_occ< VALUE_TYPE >::~vector_occ (  )  [inline]

Definition at line 152 of file vector_occ.h.


Member Function Documentation

template<class VALUE_TYPE >
template<class ATTR_TYPE >
void vcg::vector_occ< VALUE_TYPE >::Disable (  )  [inline]

Note: once an attribute is disabled, its data is lost (the memory freed).

this function disable the use of an optional attribute (see...)

Definition at line 86 of file vector_occ.h.

template<class VALUE_TYPE >
template<class ATTR_TYPE >
void vcg::vector_occ< VALUE_TYPE >::Enable (  )  [inline]

this function enable the use of an optional attribute (see...)

Definition at line 65 of file vector_occ.h.

template<class VALUE_TYPE >
static int& vcg::vector_occ< VALUE_TYPE >::ID (  )  [inline, static, private]

Definition at line 101 of file vector_occ.h.

template<class VALUE_TYPE >
template<class ATTR_TYPE >
bool vcg::vector_occ< VALUE_TYPE >::IsEnabled (  )  const [inline]

Note: once an attribute is disabled, its data is lost (the memory freed).

this function returns true if the attribute in the template parameter is enabled

Definition at line 74 of file vector_occ.h.

template<class VALUE_TYPE >
VALUE_TYPE* vcg::vector_occ< VALUE_TYPE >::Pointer2begin (  )  [inline]

Definition at line 52 of file vector_occ.h.

template<class VALUE_TYPE >
void vcg::vector_occ< VALUE_TYPE >::pop_back (  )  [inline]

Definition at line 117 of file vector_occ.h.

template<class VALUE_TYPE >
void vcg::vector_occ< VALUE_TYPE >::push_back ( const VALUE_TYPE &  v  )  [inline]

Definition at line 108 of file vector_occ.h.

template<class VALUE_TYPE >
void vcg::vector_occ< VALUE_TYPE >::reserve ( const unsigned int &  size  )  [inline]

Definition at line 133 of file vector_occ.h.

template<class VALUE_TYPE >
void vcg::vector_occ< VALUE_TYPE >::resize ( const unsigned int &  size  )  [inline]

Definition at line 123 of file vector_occ.h.

template<class VALUE_TYPE >
void vcg::vector_occ< VALUE_TYPE >::Update (  )  [inline, private]

Definition at line 140 of file vector_occ.h.


Member Data Documentation

template<class VALUE_TYPE >
std::list< CATBase<ThisType>* > vcg::vector_occ< VALUE_TYPE >::attributes

Definition at line 55 of file vector_occ.h.

template<class VALUE_TYPE >
int vcg::vector_occ< VALUE_TYPE >::id [private]

Definition at line 100 of file vector_occ.h.

template<class VALUE_TYPE >
VALUE_TYPE* vcg::vector_occ< VALUE_TYPE >::old_start [private]

Definition at line 99 of file vector_occ.h.


The documentation for this class was generated from the following file:
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Defines


vcglib
Author(s): Christian Bersch
autogenerated on Fri Jan 11 09:23:08 2013