Class TriangleFanImpl
java.lang.Object
cz.fidentis.analyst.data.mesh.impl.TriangleFanImpl
- All Implemented Interfaces:
TriangleFan
,Iterable<MeshTriangle>
The implementation of the triangle fan interface.
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionTriangle indices of the 1-ring neighborhood.Vertex indices of the 1-ring neighborhood.boolean
Returnstrue
if the triangle fan is boundary (i.e., is not enclosed).boolean
Returnstrue
if the triangle fan is enclosed (i.e., is not boundary).iterator()
Vertex 1 of the returned triangle always corresponds to the central vertex around which the triangle fan is constructed.Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
Methods inherited from interface java.lang.Iterable
forEach, spliterator
-
Constructor Details
-
TriangleFanImpl
Constructor.- Parameters:
facet
- Mesh facetvert
- Central vertex for the triangle fan- Throws:
IllegalArgumentException
- if some parameter is missing or wrong
-
-
Method Details
-
isEnclosed
public boolean isEnclosed()Returnstrue
if the triangle fan is enclosed (i.e., is not boundary).- Specified by:
isEnclosed
in interfaceTriangleFan
- Returns:
true
if the triangle fan is enclosed (i.e., is not boundary).
-
isBoundary
public boolean isBoundary()Returnstrue
if the triangle fan is boundary (i.e., is not enclosed).- Specified by:
isBoundary
in interfaceTriangleFan
- Returns:
true
if the triangle fan is enclosed (i.e., is not boundary).
-
getVertices
Vertex indices of the 1-ring neighborhood. If the triangle fan is enclosed then the first and last vertices are the same.- Specified by:
getVertices
in interfaceTriangleFan
- Returns:
- Vertex indices of the 1-ring neighborhood.
-
getTriangles
Triangle indices of the 1-ring neighborhood. The first triangle is related to the edge delimited by first and second vertex, etc. The number of triangles corresponds to the number of vertices minus one.- Specified by:
getTriangles
in interfaceTriangleFan
- Returns:
- Triangle indices of the 1-ring neighborhood.
-
iterator
Description copied from interface:TriangleFan
Vertex 1 of the returned triangle always corresponds to the central vertex around which the triangle fan is constructed.- Specified by:
iterator
in interfaceIterable<MeshTriangle>
- Specified by:
iterator
in interfaceTriangleFan
- Returns:
- A mesh triangle
-