Visual Computing Library
|
The View class is a simple class that stores and exposes two iterators begin and end. More...
#include <vclib/types/view.h>
Public Types | |
using | iterator = It |
using | const_iterator = It |
Public Member Functions | |
View (It begin, It end) | |
auto | begin () const |
auto | end () const |
Protected Attributes | |
It | mBegin |
It | mEnd |
The View class is a simple class that stores and exposes two iterators begin and end.
It is useful for classes that expose multiple containers, and they do not expose the classic member functions begin()/end(). In these cases, it is possible to expose the view of a selected container by returning a View object initialized with the begin/end iterators.
For example, a Mesh can expose Vertex and Face containers. The mesh exposes the member functions: