BEM++  2.0
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Groups Pages
Public Member Functions | Private Member Functions | Private Attributes | Friends | List of all members
Bempp::ConcreteEntity< 0, DuneEntity > Class Template Reference

Wrapper of a Dune entity of type DuneEntity and codimension 0. More...

#include </home/wojtek/Projects/BEM/bempp-sven/bempp/lib/grid/concrete_entity_decl.hpp>

Inheritance diagram for Bempp::ConcreteEntity< 0, DuneEntity >:
Bempp::Entity< 0 >

Public Member Functions

 ConcreteEntity (const DomainIndex &domain_index)
 Constructor of an empty entity.
 
 ConcreteEntity (const DuneEntity *dune_entity, const DomainIndex &domain_index)
 Constructor from a pointer to DuneEntity. More...
 
const DuneEntity & duneEntity () const
 Read-only access to the underlying Dune entity object.
 
virtual size_t level () const
 Entity level
 
virtual const Geometrygeometry () const
 Reference to the geometry of this entity. More...
 
virtual GeometryType type () const
 Type of the reference element. More...
 
virtual std::auto_ptr
< EntityPointer< 0 > > 
father () const
 Inter-level access to father entity on the next-coarser grid. More...
 
virtual bool hasFather () const
 True if entity has a father entity which can be accessed using the father() method.
 
virtual bool isLeaf () const
 True if the entity is contained in the leaf grid.
 
virtual bool isRegular () const
 True if the element is of regular type in red/green type refinement. More...
 
virtual std::auto_ptr
< EntityIterator< 0 > > 
sonIterator (int maxlevel) const
 Inter-level access to elements that resulted from (recursive) subdivision of this element. More...
 
virtual bool isNew () const
 True if the entity has been created during the last call to adapt().
 
virtual bool mightVanish () const
 True if the entity might disappear during the next call to adapt(). More...
 
virtual int domain () const
 Entity level
 
- Public Member Functions inherited from Bempp::Entity< 0 >
virtual ~Entity ()
 Destructor.
 
template<int codimSub>
size_t subEntityCount () const
 Number of subentities of codimension codimSub.
 
template<int codimSub>
std::auto_ptr< EntityIterator
< codimSub > > 
subEntityIterator () const
 Iterator over subentities of codimension codimSub. More...
 
template<>
std::auto_ptr< EntityIterator< 1 > > subEntityIterator () const
 
template<>
std::auto_ptr< EntityIterator< 2 > > subEntityIterator () const
 
template<>
std::auto_ptr< EntityIterator< 3 > > subEntityIterator () const
 
template<>
size_t subEntityCount () const
 

Private Member Functions

 dune_static_assert ((int) DuneEntity::codimension==(int) codimension,"ConcreteEntity: codimension mismatch")
 
void setDuneEntity (const DuneEntity *dune_entity)
 
virtual std::auto_ptr
< EntityIterator< 1 > > 
subEntityCodim1Iterator () const
 Iterator over subentities of codimension 1.
 
virtual std::auto_ptr
< EntityIterator< 2 > > 
subEntityCodim2Iterator () const
 Iterator over subentities of codimension 2.
 
virtual std::auto_ptr
< EntityIterator< 3 > > 
subEntityCodim3Iterator () const
 Iterator over subentities of codimension 3.
 
template<int codimSub>
boost::disable_if_c<(codimSub
<=DuneEntity::dimension),
std::auto_ptr< EntityIterator
< codimSub > > >::type 
subEntityCodimNIterator () const
 
template<int codimSub>
boost::enable_if_c<(codimSub
<=DuneEntity::dimension),
std::auto_ptr< EntityIterator
< codimSub > > >::type 
subEntityCodimNIterator () const
 
virtual size_t subEntityCodim1Count () const
 Number of subentities of codimension 1.
 
virtual size_t subEntityCodim2Count () const
 Number of subentities of codimension 1.
 
virtual size_t subEntityCodim3Count () const
 Number of subentities of codimension 1.
 

Private Attributes

const DuneEntity * m_dune_entity
 
const DomainIndexm_domain_index
 
ConcreteGeometry< typename
DuneEntity::Geometry > 
m_geometry
 

Friends

template<typename >
class ConcreteEntityPointer
 
template<typename , typename >
class ConcreteRangeEntityIterator
 
template<typename , int >
class ConcreteSubentityIterator
 

Additional Inherited Members

- Public Types inherited from Bempp::Entity< 0 >
enum  { codimension = 0 }
 Entity codimension.
 

Detailed Description

template<typename DuneEntity>
class Bempp::ConcreteEntity< 0, DuneEntity >

Wrapper of a Dune entity of type DuneEntity and codimension 0.

Constructor & Destructor Documentation

template<typename DuneEntity >
Bempp::ConcreteEntity< 0, DuneEntity >::ConcreteEntity ( const DuneEntity *  dune_entity,
const DomainIndex domain_index 
)
inline

Constructor from a pointer to DuneEntity.

Note
This object does not acquire ownership of *dune_entity.

Member Function Documentation

template<typename DuneEntity >
std::auto_ptr< EntityPointer< 0 > > Bempp::ConcreteEntity< 0, DuneEntity >::father ( ) const
virtual

Inter-level access to father entity on the next-coarser grid.

The given entity resulted directly from a subdivision of its father entity. For macro (level-0) elements a null auto_ptr is returned.

Implements Bempp::Entity< 0 >.

template<typename DuneEntity >
virtual const Geometry& Bempp::ConcreteEntity< 0, DuneEntity >::geometry ( ) const
inlinevirtual

Reference to the geometry of this entity.

This object gives, among other things, the map from a reference element to world coordinates.

Note
Be careful when storing such references. If the state of any object is changed, e.g. an iterator is advanced, there is no guarantee that the reference remains valid.

Implements Bempp::Entity< 0 >.

template<typename DuneEntity >
virtual bool Bempp::ConcreteEntity< 0, DuneEntity >::isRegular ( ) const
inlinevirtual

True if the element is of regular type in red/green type refinement.

In bisection or hanging node refinement this is always true.

Implements Bempp::Entity< 0 >.

template<typename DuneEntity >
virtual bool Bempp::ConcreteEntity< 0, DuneEntity >::mightVanish ( ) const
inlinevirtual

True if the entity might disappear during the next call to adapt().

If the method returns false, the entity is guaranteed to still be present after adaptation.

Implements Bempp::Entity< 0 >.

template<typename DuneEntity >
std::auto_ptr< EntityIterator< 0 > > Bempp::ConcreteEntity< 0, DuneEntity >::sonIterator ( int  maxlevel) const
virtual

Inter-level access to elements that resulted from (recursive) subdivision of this element.

Parameters
[in]maxlevelIterator does not stop at elements with level greater than maxlevel.
Returns
Iterator to the first son (level is not greater than maxlevel)

Implements Bempp::Entity< 0 >.

template<typename DuneEntity >
virtual GeometryType Bempp::ConcreteEntity< 0, DuneEntity >::type ( ) const
inlinevirtual

Type of the reference element.

The type can be used to access the Dune::GenericReferenceElement.

Implements Bempp::Entity< 0 >.


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