|
Visual Computing Library
devel
|
Allows to access directly to a custom component. More...
#include <vclib/mesh/containers/base/custom_component_vector_handle.h>
Classes | |
| class | ConstIterator |
| class | Iterator |
Public Member Functions | |
| T & | at (uint i) |
| const T & | at (uint i) const |
| T & | back () |
| const T & | back () const |
| Iterator | begin () |
| ConstIterator | begin () const |
| CustomComponentVectorHandle (std::vector< std::any > &cc) | |
| Iterator | end () |
| ConstIterator | end () const |
| T & | front () |
| const T & | front () const |
| T & | operator[] (uint i) |
| const T & | operator[] (uint i) const |
| uint | size () const |
Private Attributes | |
| std::vector< std::reference_wrapper< T > > | mVec |
Allows to access directly to a custom component.
The class allows to access a custom component stored in a Contaner of Elements without having to use the Container itself and avoiding copies, and it can be used as a normal std::vector. The class stores references to the custom components, therefore it allows to modify them.
It is meant to be created by a Container, that constructs it from the vector of custom components and then returns it to the user.
| T | The type of the custom component. |