3#ifndef DUNE_ALBERTA_ENTITYPOINTER_HH
4#define DUNE_ALBERTA_ENTITYPOINTER_HH
18 template<
int dim,
int dimworld >
27 template<
int codim,
class Gr
idImp >
32 friend class AlbertaGrid< GridImp::dimension, GridImp::dimensionworld >;
35 static const int dimension = GridImp::dimension;
36 static const int codimension = codim;
37 static const int mydimension = dimension - codimension;
38 static const int dimensionworld = GridImp::dimensionworld;
40 typedef typename GridImp::template Codim< codimension >::Entity Entity;
44 typedef typename EntityObject::ImplementationType EntityImp;
49 typedef typename EntityImp::ElementInfo ElementInfo;
53 const ElementInfo &elementInfo,
74 This &operator= ( const This &other );
78 bool
equals ( const This &other ) const;
94 const GridImp &
grid () const;
102 template< int codim, class GridImp >
105 const ElementInfo &elementInfo,
107 : entity_( EntityImp( grid, elementInfo, subEntity ) )
111 template<
int codim,
class Gr
idImp >
114 : entity_( EntityImp(
grid ) )
118 template<
int codim,
class Gr
idImp >
126 template<
int codim,
class Gr
idImp >
129 : entity_( other.entity_ )
135 template<
int codim,
class Gr
idImp >
136 inline AlbertaGridEntityPointer< codim, GridImp >::~AlbertaGridEntityPointer ()
142 template<
int codim,
class Gr
idImp >
143 inline typename AlbertaGridEntityPointer< codim, GridImp >::This &
144 AlbertaGridEntityPointer< codim, GridImp >::operator= (
const This &other )
146 entityImp().setEntity( other.entityImp() );
152 template<
int codim,
class Gr
idImp >
156 return entityImp().equals( other.
entityImp() );
160 template<
int codim,
class Gr
idImp >
161 inline typename AlbertaGridEntityPointer< codim, GridImp >::Entity &
168 template<
int codim,
class Gr
idImp >
171 return entityImp().level();
175 template<
int codim,
class Gr
idImp >
176 inline typename AlbertaGridEntityPointer< codim, GridImp >::EntityImp &
179 return GridImp::getRealImplementation( entity_ );
183 template<
int codim,
class Gr
idImp >
184 inline const typename AlbertaGridEntityPointer< codim, GridImp >::EntityImp &
187 return GridImp::getRealImplementation( entity_ );
191 template<
int codim,
class Gr
idImp >
194 return entityImp().grid();
EntityPointer implementation for AlbertaGrid.
Definition: entitypointer.hh:29
Entity & dereference() const
dereferencing
Definition: entitypointer.hh:162
const GridImp & grid() const
obtain a reference to the grid
Definition: entitypointer.hh:192
EntityImp & entityImp()
obtain reference to internal entity implementation
Definition: entitypointer.hh:177
AlbertaGridEntityPointer(const GridImp &grid, const ElementInfo &elementInfo, int subEntity)
make an EntityPointer that points to an element
Definition: entitypointer.hh:104
int level() const
ask for level of entities
Definition: entitypointer.hh:169
bool equals(const This &other) const
equality
Definition: entitypointer.hh:154
[ provides Dune::Grid ]
Definition: agrid.hh:140
Wrapper and interface classe for a static iterator (EntityPointer)
provides a wrapper for ALBERTA's el_info structure
Dune namespace.
Definition: alignment.hh:14