1#ifndef DUNE_MULTIDOMAINGRID_SUBDOMAINGRID_ENTITY_HH
2#define DUNE_MULTIDOMAINGRID_SUBDOMAINGRID_ENTITY_HH
6#include <dune/grid/common/entity.hh>
7#include <dune/grid/common/gridenums.hh>
13template<
typename,
typename>
18template<
int codim,
int dim,
typename Gr
idImp>
21template<
typename,
typename,
typename>
24template<
typename Gr
idImp>
27template<
typename MDGr
id>
36template<
typename HostES>
40 typedef HostES HostEntitySeed;
45 template<
typename,
typename>
46 friend class ::Dune::mdgrid::MultiDomainGrid;
48 template<
int,
int,
typename>
53 static const std::size_t
codimension = HostEntitySeed::codimension;
76template<
int codim,
int dim,
typename Gr
idImp>
78 :
public EntityDefaultImplementation<codim,dim,GridImp,EntityWrapper>
83 using MultiDomainEntity =
typename GridImp::MultiDomainGrid::Traits::template Codim<codim>::Entity;
84 using HostEntity =
typename GridImp::HostGrid::Traits::template Codim<codim>::Entity;
89 using Geometry =
typename GridImp::template Codim<codim>::Geometry;
97 , _multiDomainEntity(e)
102 , _multiDomainEntity(std::move(e))
132 const GridImp* _grid;
138 return _multiDomainEntity;
142 return grid()._grid.hostEntity(_multiDomainEntity);
154template<
int codim,
int dim,
typename Gr
idImp>
164 template<
typename,
typename>
167 template<
int,
int,
typename,
template<
int,
int,
typename>
class>
178template<
int dim,
typename Gr
idImp>
188 template<
typename,
typename>
191 template<
int,
int,
typename,
template<
int,
int,
typename>
class>
219 typename GridImp::template Codim<cc>::Entity
subEntity(
int i)
const {
223 typename GridImp::template Codim<0>::Entity
father()
const {
262 typename GridImp::LevelGridView::IndexSet,
263 typename GridImp::MultiDomainGrid::LevelGridView::IntersectionIterator
265 grid().levelGridView(this->
level()).indexSet(),
273 typename GridImp::LevelGridView::IndexSet,
274 typename GridImp::MultiDomainGrid::LevelGridView::IntersectionIterator
276 grid().levelGridView(this->
level()).indexSet(),
284 typename GridImp::LeafGridView::IndexSet,
285 typename GridImp::MultiDomainGrid::LeafGridView::IntersectionIterator
287 grid().leafGridView().indexSet(),
295 typename GridImp::LeafGridView::IndexSet,
296 typename GridImp::MultiDomainGrid::LeafGridView::IntersectionIterator
298 grid().leafGridView().indexSet(),
313 for(
const auto& is : intersections(
grid().levelGridView(this->
level()),*
this))
320 for(
const auto& is : intersections(
grid().leafGridView(),*
this))
Definition: multidomaingrid.hh:8
@ other
Definition: multidomaingrid/multidomaingrid.hh:1292
A meta grid for dividing an existing DUNE grid into subdomains that can be accessed as a grid in thei...
Definition: multidomaingrid/multidomaingrid.hh:241
Definition: subdomaingrid/entity.hh:157
friend class Entity
Definition: subdomaingrid/entity.hh:168
Definition: subdomaingrid/intersectioniterator.hh:19
Definition: subdomaingrid/hierarchiciterator.hh:17
Definition: subdomaingrid.hh:203
Definition: subdomaingrid/gridview.hh:19
Definition: subdomaingrid/gridview.hh:69
Definition: subdomaingrid/entity.hh:38
bool isValid() const
Definition: subdomaingrid/entity.hh:67
const HostEntitySeed & hostEntitySeed() const
Definition: subdomaingrid/entity.hh:62
static const std::size_t codimension
Definition: subdomaingrid/entity.hh:53
HostEntitySeed _hostEntitySeed
Definition: subdomaingrid/entity.hh:72
EntitySeedWrapper()
Definition: subdomaingrid/entity.hh:55
EntitySeedWrapper(const HostEntitySeed &hostEntitySeed)
Definition: subdomaingrid/entity.hh:58
Definition: subdomaingrid/entity.hh:79
typename GridImp::template Codim< codim >::Geometry Geometry
Definition: subdomaingrid/entity.hh:89
const GridImp & grid() const
Definition: subdomaingrid/entity.hh:145
typename GridImp::HostGrid::Traits::template Codim< codim >::Entity HostEntity
Definition: subdomaingrid/entity.hh:84
bool equals(const EntityWrapperBase &other) const
Definition: subdomaingrid/entity.hh:125
EntitySeed seed() const
Definition: subdomaingrid/entity.hh:121
const HostEntity & hostEntity() const
Definition: subdomaingrid/entity.hh:141
PartitionType partitionType() const
Definition: subdomaingrid/entity.hh:109
int level() const
Definition: subdomaingrid/entity.hh:105
typename GridImp::MultiDomainGrid::Traits::template Codim< codim >::Entity MultiDomainEntity
Definition: subdomaingrid/entity.hh:83
unsigned int subEntities(unsigned int codimSubEntitiy) const
Definition: subdomaingrid/entity.hh:113
const MultiDomainEntity & multiDomainEntity() const
Definition: subdomaingrid/entity.hh:137
Geometry geometry() const
Definition: subdomaingrid/entity.hh:117
EntitySeedWrapper< typename HostEntity::EntitySeed > EntitySeed
Definition: subdomaingrid/entity.hh:88
EntityWrapperBase(const GridImp *grid, const MultiDomainEntity &e)
Definition: subdomaingrid/entity.hh:95
EntityWrapperBase(const GridImp *grid, MultiDomainEntity &&e)
Definition: subdomaingrid/entity.hh:100
EntityWrapperBase()
Definition: subdomaingrid/entity.hh:91
bool isNew() const
Definition: subdomaingrid/entity.hh:303
GridImp::template Codim< cc >::Entity subEntity(int i) const
Definition: subdomaingrid/entity.hh:219
LevelIntersectionIterator ilevelend() const
Definition: subdomaingrid/entity.hh:270
LeafIntersectionIterator ileafend() const
Definition: subdomaingrid/entity.hh:292
bool mightVanish() const
Definition: subdomaingrid/entity.hh:307
typename GridImp::template Codim< 0 >::LocalGeometry LocalGeometry
Definition: subdomaingrid/entity.hh:206
bool hasBoundaryIntersections() const
Definition: subdomaingrid/entity.hh:311
GridImp::template Codim< 0 >::Entity father() const
Definition: subdomaingrid/entity.hh:223
LocalGeometry geometryInFather() const
Definition: subdomaingrid/entity.hh:239
typename GridImp::Traits::HierarchicIterator HierarchicIterator
Definition: subdomaingrid/entity.hh:209
unsigned int subEntities(unsigned int codim) const
Definition: subdomaingrid/entity.hh:214
typename GridImp::Traits::LeafIntersectionIterator LeafIntersectionIterator
Definition: subdomaingrid/entity.hh:207
bool isLeaf() const
Definition: subdomaingrid/entity.hh:231
LevelIntersectionIterator ilevelbegin() const
Definition: subdomaingrid/entity.hh:259
HierarchicIterator hbegin(int maxLevel) const
Definition: subdomaingrid/entity.hh:243
bool isRegular() const
Definition: subdomaingrid/entity.hh:235
bool hasFather() const
Definition: subdomaingrid/entity.hh:227
HierarchicIterator hend(int maxLevel) const
Definition: subdomaingrid/entity.hh:251
typename GridImp::Traits::LevelIntersectionIterator LevelIntersectionIterator
Definition: subdomaingrid/entity.hh:208
LeafIntersectionIterator ileafbegin() const
Definition: subdomaingrid/entity.hh:281