1#ifndef DUNE_MULTIDOMAINGRID_INTERSECTIONITERATOR_HH 
    2#define DUNE_MULTIDOMAINGRID_INTERSECTIONITERATOR_HH 
    4#include <dune/grid/common/intersectioniterator.hh> 
    6#include <dune/grid/multidomaingrid/hostgridaccessor.hh> 
    8#include <dune/grid/multidomaingrid/subdomaingrid/intersectioniterator.hh> 
    9#include "intersection.hh" 
   15template<
typename Gr
idImp, 
typename HostIntersectionIterator_>
 
   16class IntersectionIteratorWrapper {
 
   18  template<
class, 
class, 
class>
 
   19  friend class Dune::IntersectionIterator;
 
   21  template<
class, 
class>
 
   22  friend class Dune::Intersection;
 
   24  template<
typename,
typename,
typename>
 
   25  friend class subdomain::IntersectionIteratorWrapper;
 
   28  friend class LevelGridView;
 
   31  friend class LeafGridView;
 
   33  using HostIntersectionIterator = HostIntersectionIterator_;
 
   34  using HostIntersection         = 
typename HostIntersectionIterator::Intersection;
 
   35  using IntersectionWrapper      = Dune::mdgrid::IntersectionWrapper<GridImp,HostIntersection>;
 
   36  using Intersection             = Dune::Intersection<GridImp,IntersectionWrapper>;
 
   40  IntersectionIteratorWrapper() = 
default;
 
   42  explicit IntersectionIteratorWrapper(
const HostIntersectionIterator& hostIterator)
 
   43    : _hostIterator(hostIterator)
 
   46  explicit IntersectionIteratorWrapper(HostIntersectionIterator&& hostIterator)
 
   47    : _hostIterator(std::move(hostIterator))
 
   52  const HostIntersectionIterator& hostIntersectionIterator()
 const {
 
   56  bool equals(
const IntersectionIteratorWrapper& rhs)
 const {
 
   57    return _hostIterator == rhs._hostIterator;
 
   64  Intersection dereference()
 const {
 
   65    return {IntersectionWrapper(*_hostIterator)};
 
   68  HostIntersectionIterator _hostIterator;