Node_AllIncCells< Mesh > Class Template Reference

Node in a simplicial mesh that stores iterators to all incident cells. More...

#include <Node_AllIncCells.h>

Inheritance diagram for Node_AllIncCells< Mesh >:
Node_VertSelfId< Mesh >

List of all members.

Public Types

enum  { N = base_type::N }
 

The space dimension.


typedef Mesh mesh_type
 The simplicial mesh.
typedef mesh_type::cell_iterator cell_iterator
 An iterator to a cell.
typedef
mesh_type::cell_const_iterator 
cell_const_iterator
 An iterator to a const cell.
typedef base_type::node_iterator node_iterator
 An iterator to a node.
typedef
base_type::node_const_iterator 
node_const_iterator
 An iterator to a const node.
typedef base_type::number_type number_type
 The number type.
typedef base_type::vertex_type vertex_type
 A vertex (a Cartesian point).
typedef
cell_iterator_container::iterator 
cell_iter_iterator
 An iterator for incident cell iterators.
typedef
cell_iterator_container::const_iterator 
cell_iter_const_iterator
 A const iterator for incident cell iterators.
typedef ads::IndirectIterator
< typename
cell_iterator_container::iterator > 
cell_inc_to_node_iterator
 An iterator for incident cells.
typedef ads::IndirectIterator
< typename
cell_iterator_container::const_iterator > 
cell_inc_to_node_const_iterator
 A const iterator for incident cells.

Public Member Functions

Constructors and Destructor.

 Node_AllIncCells ()
 Default constructor. Uninitialized vertex, and null identifier and iterators.
 Node_AllIncCells (const vertex_type &vertex, const int identifier=-1)
 Construct from a vertex and an identifier.
void build (const vertex_type &vertex, const int identifier=-1, const node_iterator self=0)
 Build from a vertex and an identifier.
 Node_AllIncCells (const Node_AllIncCells &x)
 Copy constructor.
 ~Node_AllIncCells ()
 Destructor.
Assignment operators.

Node_AllIncCellsoperator= (const Node_AllIncCells &x)
 Assignment operator.
Accessors.

const vertex_typevertex () const
 Return the vertex.
int identifier () const
 Return the identifier of this node.
node_const_iterator self () const
 Return a const iterator to itself.
cell_const_iterator cell () const
 Return a const iterator to an incident cell.
int cells_size () const
 Return the number of incident cells.
cell_inc_to_node_const_iterator cells_begin () const
 Return the begining of the incident cells.
cell_inc_to_node_const_iterator cells_end () const
 Return the end of the incident cells.
cell_iter_const_iterator cell_iters_begin () const
 Return the begining of the incident cells iterators.
cell_iter_const_iterator cell_iters_end () const
 Return the end of the incident cell iterators.
bool is_on_boundary () const
 Return true if the node is on the boundary.
Manipulators.

void set_vertex (const vertex_type &vertex)
 Set the vertex.
void set_identifier (const int identifier) const
 Set the identifier.
node_iterator self ()
 Return an iterator to itself.
void set_self (const node_iterator self)
 Set the iterator to the derived vertex.
cell_iterator cell ()
 Return an iterator to an incident cell.
void add_cell (const cell_iterator c)
 Add an adjacent cell.
template<typename CellIterInIter >
void add_cells (CellIterInIter begin, CellIterInIter end)
 Add a range of adjacent cells.
void remove_cell (const cell_iterator c)
 Remove an incident cell.
cell_inc_to_node_iterator cells_begin ()
 Return the begining of the incident cells.
cell_inc_to_node_iterator cells_end ()
 Return the end of the incident cells.
cell_iter_iterator cell_iters_begin ()
 Return the begining of the incident cell iterators.
cell_iter_iterator cell_iters_end ()
 Return the end of the incident cell iterators.
void replace (node_iterator x)
 Replace this node with the specified one.
Equality.

bool operator== (const Node_AllIncCells &x) const
 Return true if this is equal to x.
bool operator!= (const Node_AllIncCells &x) const
 Return true if this is not equal to x.
File I/O.

void put (std::ostream &out) const
 Write the vertex point, identifier, and the iterators.

Detailed Description

template<class Mesh>
class Node_AllIncCells< Mesh >

Node in a simplicial mesh that stores iterators to all incident cells.

Parameters:
Mesh is the simplicial mesh.

The base class has the vertex, an iterator to itself, and an identifier. This class stores iterators to all incident cells.


Member Function Documentation

template<class Mesh >
int Node_AllIncCells< Mesh >::identifier (  )  const [inline]

Return the identifier of this node.

Typically, the identifier is in the range [0...num_vertices). and a value of -1 indicates that the identifier has not been calculated.

Reimplemented from Node_VertSelfId< Mesh >.

Referenced by Node_AllIncCells< Mesh >::~Node_AllIncCells().

template<class Mesh >
bool Node_AllIncCells< Mesh >::is_on_boundary (  )  const [inline]

Return true if the node is on the boundary.

The node is on the boundary if there are any incident boundary faces. To determine this, we examine each of the incident cells.

template<class Mesh >
void Node_AllIncCells< Mesh >::replace ( node_iterator  x  )  [inline]

Replace this node with the specified one.

This amounts to changing the simplex-vertex incidences.

template<class Mesh >
void Node_AllIncCells< Mesh >::set_identifier ( const int  identifier  )  const [inline]

Set the identifier.

Note:
This member function is const because the identifier is mutable. It is intended to be modified as the mesh changes.

Reimplemented from Node_VertSelfId< Mesh >.


The documentation for this class was generated from the following file:
Generated on Thu Jun 30 02:14:58 2016 for Computational Geometry Package by  doxygen 1.6.3