5#ifndef DUNE_GEOGRID_INTERSECTIONITERATOR_HH
6#define DUNE_GEOGRID_INTERSECTIONITERATOR_HH
8#include <dune/grid/geometrygrid/intersection.hh>
19 template<
class Gr
id,
class HostIntersectionIterator >
20 class IntersectionIterator
22 typedef typename std::remove_const< Grid >::type::Traits Traits;
24 typedef GeoGrid::Intersection< Grid, typename HostIntersectionIterator::Intersection > IntersectionImpl;
26 typedef typename Traits::template Codim< 0 >::Geometry ElementGeometry;
27 typedef typename Traits::template Codim< 0 >::GeometryImpl ElementGeometryImpl;
32 IntersectionIterator()
35 template<
class Entity >
36 IntersectionIterator (
const Entity &inside,
37 const HostIntersectionIterator &hostIterator )
38 : hostIterator_( hostIterator )
39 , insideGeo_( inside.geometry().impl() )
42 IntersectionIterator (
const IntersectionIterator &other )
43 : hostIterator_( other.hostIterator_ )
44 , insideGeo_( other.insideGeo_ )
47 IntersectionIterator ( IntersectionIterator&& other )
48 : hostIterator_(
std::move( other.hostIterator_ ) )
49 , insideGeo_(
std::move( other.insideGeo_ ) )
52 IntersectionIterator &operator= (
const IntersectionIterator &other )
54 hostIterator_ = other.hostIterator_;
55 insideGeo_ = other.insideGeo_;
59 IntersectionIterator &operator= ( IntersectionIterator&& other )
61 hostIterator_ = std::move( other.hostIterator_ );
62 insideGeo_ = std::move( other.insideGeo_ );
66 bool equals (
const IntersectionIterator &other )
const
68 return (hostIterator_ == other.hostIterator_);
76 Intersection dereference ()
const
78 return IntersectionImpl( *hostIterator_, insideGeo_ );
83 HostIntersectionIterator hostIterator_;
84 ElementGeometryImpl insideGeo_;
constexpr auto equals(T1 &&t1, T2 &&t2)
Equality comparison.
Definition: hybridutilities.hh:402
Dune namespace.
Definition: alignedallocator.hh:13