Regina Calculation Engine
|
Represents an edge in the 1-skeleton of a 2-manifold triangulation. More...
#include <dim2/dim2edge.h>
Public Member Functions | |
~Dim2Edge () | |
Default destructor. More... | |
unsigned long | index () const |
Returns the index of this edge in the underlying triangulation. More... | |
unsigned | getNumberOfEmbeddings () const |
Returns the number of descriptors available through getEmbedding(). More... | |
const Dim2EdgeEmbedding & | getEmbedding (unsigned index) const |
Returns the requested descriptor detailing how this edge forms a part of a particular triangle in the triangulation. More... | |
Dim2Triangulation * | getTriangulation () const |
Returns the triangulation to which this edge belongs. More... | |
Dim2Component * | getComponent () const |
Returns the component of the triangulation to which this edge belongs. More... | |
Dim2BoundaryComponent * | getBoundaryComponent () const |
Returns the boundary component of the triangulation to which this edge belongs. More... | |
Dim2Vertex * | getVertex (int vertex) const |
Returns the vertex of the 2-manifold triangulation corresponding to the given vertex of this edge. More... | |
bool | isBoundary () const |
Determines if this edge lies entirely on the boundary of the triangulation. More... | |
void | writeTextShort (std::ostream &out) const |
Writes this object in short text format to the given output stream. More... | |
void | writeTextLong (std::ostream &out) const |
Writes this object in long text format to the given output stream. More... | |
long | markedIndex () const |
Returns the index at which this object is stored in an NMarkedVector. More... | |
Input and Output | |
std::string | str () const |
Returns the output from writeTextShort() as a string. More... | |
std::string | toString () const |
A deprecated alias for str(), which returns the output from writeTextShort() as a string. More... | |
std::string | detail () const |
Returns the output from writeTextLong() as a string. More... | |
std::string | toStringLong () const |
A deprecated alias for detail(), which returns the output from writeTextLong() as a string. More... | |
Static Public Attributes | |
static const NPerm3 | ordering [3] |
An array that maps edge numbers within a triangle to the canonical ordering of the individual triangle vertices that form each edge. More... | |
Friends | |
class | Dim2Triangulation |
Allow access to private members. More... | |
Represents an edge in the 1-skeleton of a 2-manifold triangulation.
Edges are highly temporary; once a triangulation changes, all its edge objects will be deleted and new ones will be created.
|
inline |
Default destructor.
|
inherited |
Returns the output from writeTextLong() as a string.
|
inline |
Returns the boundary component of the triangulation to which this edge belongs.
|
inline |
Returns the component of the triangulation to which this edge belongs.
|
inline |
Returns the requested descriptor detailing how this edge forms a part of a particular triangle in the triangulation.
Note that if this edge represents multiple edges of a particular triangle, then there will be multiple embedding descriptors available regarding that triangle.
index | the index of the requested descriptor. This should be between 0 and getNumberOfEmbeddings()-1 inclusive. |
|
inline |
Returns the number of descriptors available through getEmbedding().
Note that this number will never be greater than two.
|
inline |
Returns the triangulation to which this edge belongs.
|
inline |
Returns the vertex of the 2-manifold triangulation corresponding to the given vertex of this edge.
vertex | the vertex of this edge to examine. This should be either 0 or 1. |
|
inline |
Returns the index of this edge in the underlying triangulation.
This is identical to calling getTriangulation()->edgeIndex(this)
.
|
inline |
Determines if this edge lies entirely on the boundary of the triangulation.
true
if and only if this edge lies on the boundary.
|
inlineinherited |
Returns the index at which this object is stored in an NMarkedVector.
If this object does not belong to an NMarkedVector, the return value is undefined.
|
inherited |
Returns the output from writeTextShort() as a string.
__str__()
function.
|
inlineinherited |
A deprecated alias for str(), which returns the output from writeTextShort() as a string.
|
inlineinherited |
A deprecated alias for detail(), which returns the output from writeTextLong() as a string.
|
virtual |
Writes this object in long text format to the given output stream.
The output should provide the user with all the information they could want. The output should be human-readable, should not contain extremely long lines (so users can read the output in a terminal), and should end with a final newline.
The default implementation of this routine merely calls writeTextShort() and adds a newline.
out | the output stream to which to write. |
Reimplemented from regina::ShareableObject.
|
inlinevirtual |
Writes this object in short text format to the given output stream.
The output should be human-readable, should fit on a single line, and should not end with a newline.
out | the output stream to which to write. |
Implements regina::ShareableObject.
|
friend |
Allow access to private members.
|
static |
An array that maps edge numbers within a triangle to the canonical ordering of the individual triangle vertices that form each edge.
This means that the vertices of edge i in a triangle are, in canonical order, ordering[i][0,1]
. As an immediate consequence, we obtain ordering[i][2] == i
.
Regina defines canonical order to be increasing order. That is, ordering[i][0] < ordering[i][1]
.
This table does not describe the mapping from specific edges within a triangulation into individual triangles (for that, see Dim2Triangle::getEdgeMapping() instead). This table merely provides a neat and consistent way of listing the vertices of any given edge of a triangle.