libMesh
Public Member Functions | Private Attributes | List of all members
libMesh::mesh_inserter_iterator< T > Struct Template Reference

A class for templated methods that expect output iterator arguments, which adds objects to the Mesh. More...

#include <mesh_inserter_iterator.h>

Inheritance diagram for libMesh::mesh_inserter_iterator< T >:
[legend]

Public Member Functions

 mesh_inserter_iterator (MeshBase &m)
 
void operator= (Elem *e)
 
void operator= (Node *n)
 
void operator= (Point *p)
 
mesh_inserter_iteratoroperator++ ()
 
mesh_inserter_iterator operator++ (int)
 
mesh_inserter_iteratoroperator* ()
 

Private Attributes

MeshBasemesh
 

Detailed Description

template<typename T>
struct libMesh::mesh_inserter_iterator< T >

A class for templated methods that expect output iterator arguments, which adds objects to the Mesh.

Although any mesh_inserter_iterator can add any object, we template it around object type so that type inference and iterator_traits will work.

Author
Roy Stogner
Date
2012 An output iterator for use with packed_range functions.

Definition at line 46 of file mesh_inserter_iterator.h.

Constructor & Destructor Documentation

template<typename T >
libMesh::mesh_inserter_iterator< T >::mesh_inserter_iterator ( MeshBase m)

Member Function Documentation

template<typename T >
mesh_inserter_iterator& libMesh::mesh_inserter_iterator< T >::operator* ( )

Definition at line 69 of file mesh_inserter_iterator.h.

69 { return *this; }
template<typename T >
mesh_inserter_iterator& libMesh::mesh_inserter_iterator< T >::operator++ ( )

Definition at line 57 of file mesh_inserter_iterator.h.

57  {
58  return *this;
59  }
template<typename T >
mesh_inserter_iterator libMesh::mesh_inserter_iterator< T >::operator++ ( int  )
template<typename T >
void libMesh::mesh_inserter_iterator< T >::operator= ( Elem e)

Definition at line 51 of file mesh_inserter_iterator.h.

References libMesh::MeshBase::add_elem(), and libMesh::mesh_inserter_iterator< T >::mesh.

51 { mesh.add_elem(e); }
virtual Elem * add_elem(Elem *e)=0
Add elem e to the end of the element array.
template<typename T >
void libMesh::mesh_inserter_iterator< T >::operator= ( Node n)

Definition at line 53 of file mesh_inserter_iterator.h.

References libMesh::MeshBase::insert_node(), and libMesh::mesh_inserter_iterator< T >::mesh.

53 { mesh.insert_node(n); }
virtual Node * insert_node(Node *n)=0
Insert Node n into the Mesh at a location consistent with n->id(), allocating extra storage if necess...
template<typename T >
void libMesh::mesh_inserter_iterator< T >::operator= ( Point p)

Definition at line 55 of file mesh_inserter_iterator.h.

References libMesh::MeshBase::add_point(), and libMesh::mesh_inserter_iterator< T >::mesh.

55 { mesh.add_point(*p); }
virtual Node * add_point(const Point &p, const dof_id_type id=DofObject::invalid_id, const processor_id_type proc_id=DofObject::invalid_processor_id)=0
Add a new Node at Point p to the end of the vertex array, with processor_id procid.

Member Data Documentation

template<typename T >
MeshBase& libMesh::mesh_inserter_iterator< T >::mesh
private

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