Wildmeshing Toolkit
wmtk::simplex::LinkIterable::Iterator Class Reference

#include <LinkIterable.hpp>

Collaboration diagram for wmtk::simplex::LinkIterable::Iterator:
[legend]

Public Member Functions

 Iterator (LinkIterable &container, const Tuple &t=Tuple())
 
Iteratoroperator++ ()
 
bool operator!= (const Iterator &other) const
 
IdSimplex operator* ()
 
const IdSimplex operator* () const
 

Private Member Functions

int64_t depth ()
 Compute the depth from the mesh and the simplex type. More...
 
void init ()
 Depending on the depth, the iterator must be initialized differently. More...
 
Iteratorstep_depth_3 ()
 Use breadth first search to find all d-simplices, and iterate through all cofaces in a d-simplex. More...
 
Tuple navigate_to_link (Tuple t)
 

Private Attributes

LinkIterablem_container
 
TopDimensionCofacesIterable::Iterator m_it
 
Tuple m_t
 
int8_t m_pt = 0
 
int8_t m_edge_counter = 0
 

Detailed Description

Definition at line 22 of file LinkIterable.hpp.

Constructor & Destructor Documentation

◆ Iterator()

wmtk::simplex::LinkIterable::Iterator::Iterator ( LinkIterable container,
const Tuple t = Tuple() 
)

Definition at line 20 of file LinkIterable.cpp.

References wmtk::get_primitive_type_id(), init(), wmtk::Tuple::is_null(), wmtk::logger(), m_container, wmtk::simplex::LinkIterable::m_mesh, wmtk::simplex::LinkIterable::m_simplex, m_t, wmtk::simplex::Simplex::primitive_type(), and wmtk::Mesh::top_cell_dimension().

Here is the call graph for this function:

Member Function Documentation

◆ depth()

int64_t wmtk::simplex::LinkIterable::Iterator::depth ( )
private

Compute the depth from the mesh and the simplex type.

The depth is "mesh top simplex dimension" - "simplex dimension".

Definition at line 82 of file LinkIterable.cpp.

References wmtk::get_primitive_type_id(), wmtk::simplex::Simplex::primitive_type(), and wmtk::Mesh::top_cell_dimension().

Here is the call graph for this function:

◆ init()

void wmtk::simplex::LinkIterable::Iterator::init ( )
private

Depending on the depth, the iterator must be initialized differently.

Definition at line 92 of file LinkIterable.cpp.

References wmtk::Mesh::get_id_simplex(), and wmtk::get_primitive_type_from_id().

Referenced by Iterator().

Here is the call graph for this function:
Here is the caller graph for this function:

◆ navigate_to_link()

Tuple wmtk::simplex::LinkIterable::Iterator::navigate_to_link ( Tuple  t)
private

Definition at line 139 of file LinkIterable.cpp.

References wmtk::get_primitive_type_from_id(), wmtk::get_primitive_type_id(), wmtk::Tuple::is_null(), wmtk::simplex::Simplex::primitive_type(), wmtk::Mesh::switch_tuple(), and wmtk::Mesh::top_cell_dimension().

Here is the call graph for this function:

◆ operator!=()

bool wmtk::simplex::LinkIterable::Iterator::operator!= ( const Iterator other) const

Definition at line 67 of file LinkIterable.cpp.

References m_pt, and m_t.

◆ operator*() [1/2]

IdSimplex wmtk::simplex::LinkIterable::Iterator::operator* ( )

Definition at line 72 of file LinkIterable.cpp.

References wmtk::get_primitive_type_from_id().

Here is the call graph for this function:

◆ operator*() [2/2]

const IdSimplex wmtk::simplex::LinkIterable::Iterator::operator* ( ) const

Definition at line 77 of file LinkIterable.cpp.

References wmtk::get_primitive_type_from_id().

Here is the call graph for this function:

◆ operator++()

LinkIterable::Iterator & wmtk::simplex::LinkIterable::Iterator::operator++ ( )

Definition at line 43 of file LinkIterable.cpp.

References wmtk::get_primitive_type_id(), wmtk::simplex::Simplex::primitive_type(), and wmtk::Mesh::top_cell_dimension().

Here is the call graph for this function:

◆ step_depth_3()

LinkIterable::Iterator & wmtk::simplex::LinkIterable::Iterator::step_depth_3 ( )
private

Use breadth first search to find all d-simplices, and iterate through all cofaces in a d-simplex.

Definition at line 104 of file LinkIterable.cpp.

References wmtk::Edge, wmtk::Mesh::get_id_simplex(), wmtk::get_primitive_type_from_id(), wmtk::Mesh::switch_tuples(), and wmtk::Vertex.

Here is the call graph for this function:

Member Data Documentation

◆ m_container

LinkIterable& wmtk::simplex::LinkIterable::Iterator::m_container
private

Definition at line 53 of file LinkIterable.hpp.

Referenced by Iterator().

◆ m_edge_counter

int8_t wmtk::simplex::LinkIterable::Iterator::m_edge_counter = 0
private

Definition at line 57 of file LinkIterable.hpp.

◆ m_it

TopDimensionCofacesIterable::Iterator wmtk::simplex::LinkIterable::Iterator::m_it
private

Definition at line 54 of file LinkIterable.hpp.

◆ m_pt

int8_t wmtk::simplex::LinkIterable::Iterator::m_pt = 0
private

Definition at line 56 of file LinkIterable.hpp.

Referenced by operator!=().

◆ m_t

Tuple wmtk::simplex::LinkIterable::Iterator::m_t
private

Definition at line 55 of file LinkIterable.hpp.

Referenced by Iterator(), and operator!=().


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