List of all members | Public Member Functions
thor::Edge< V > Class Template Reference

Edge that contains two vertices (its endpoints or corners) More...

Public Member Functions

 Edge (V &corner0, V &corner1)
 Edge constructor More...
 
V & operator[] (std::size_t cornerIndex)
 Accesses a corner of the edge. More...
 
const V & operator[] (std::size_t cornerIndex) const
 Accesses a corner of the edge (const overload). More...
 

Detailed Description

template<typename V>
class thor::Edge< V >

Edge that contains two vertices (its endpoints or corners)

Template Parameters
VThe type of the vertices, for which the template thor::TriangulationTraits shall be specialized. If V is const-qualified, the corners cannot be changed through this edge.

Constructor & Destructor Documentation

template<typename V >
thor::Edge< V >::Edge ( V &  corner0,
V &  corner1 
)

Edge constructor

The vertices startPoint and endPoint form the two "corners" of the edge. They are only referenced and not copied.

Member Function Documentation

template<typename V >
V& thor::Edge< V >::operator[] ( std::size_t  cornerIndex)

Accesses a corner of the edge.

Parameters
cornerIndexThe index of the corner. Must be either 0 or 1.
Returns
Reference to the vertex at the specified corner.
template<typename V >
const V& thor::Edge< V >::operator[] ( std::size_t  cornerIndex) const

Accesses a corner of the edge (const overload).

Parameters
cornerIndexThe index of the corner. Must be either 0 or 1.
Returns
Const-reference to the vertex at the specified corner.

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