Peano
Loading...
Searching...
No Matches
peano4::datamanagement::VertexHeapDataEnumerator< Vertex > Class Template Reference

Enumerator over copies of the vertices of a cell. More...

#include <VertexHeapDataEnumerator.h>

Collaboration diagram for peano4::datamanagement::VertexHeapDataEnumerator< Vertex >:

Public Member Functions

 VertexHeapDataEnumerator (const VertexEnumerator< Vertex > &vertices)
 Copy the 2^d vertices the enumerator points to.
 
Vertex & operator() (int i)
 Access the copy of vertex i.
 
const Vertex & operator() (int i) const
 

Private Attributes

std::vector< Vertex > _vertices
 

Detailed Description

template<class Vertex>
class peano4::datamanagement::VertexHeapDataEnumerator< Vertex >

Enumerator over copies of the vertices of a cell.

Vertex counterpart of peano4::datamanagement::FaceHeapDataEnumerator: The enumerator takes a peano4::datamanagement::VertexEnumerator, which holds pointers to the 2^d vertices of a cell on Peano's stacks, and copies the vertices. It owns these copies and offers the same access operator as the VertexEnumerator, so code which runs after the traversal has left the cell, e.g. a spawned task, can use it.

The enumerator only refers to the actual vertex data if copying a vertex is shallow, i.e. if the data is managed via smart pointers. Otherwise, the enumerator works on deep copies, and writes are lost. See peano4::datamanagement::FaceHeapDataEnumerator for details.

Definition at line 38 of file VertexHeapDataEnumerator.h.

Constructor & Destructor Documentation

◆ VertexHeapDataEnumerator()

template<class Vertex >
peano4::datamanagement::VertexHeapDataEnumerator< Vertex >::VertexHeapDataEnumerator ( const VertexEnumerator< Vertex > &  vertices)

Copy the 2^d vertices the enumerator points to.

Member Function Documentation

◆ operator()() [1/2]

template<class Vertex >
Vertex & peano4::datamanagement::VertexHeapDataEnumerator< Vertex >::operator() ( int  i)

Access the copy of vertex i.

Vertices are enumerated as in peano4::datamanagement::VertexEnumerator.

◆ operator()() [2/2]

template<class Vertex >
const Vertex & peano4::datamanagement::VertexHeapDataEnumerator< Vertex >::operator() ( int  i) const

Field Documentation

◆ _vertices

template<class Vertex >
std::vector<Vertex> peano4::datamanagement::VertexHeapDataEnumerator< Vertex >::_vertices
private

Definition at line 40 of file VertexHeapDataEnumerator.h.


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