6#ifndef DUNE_GRID_IO_FILE_VTK_VOLUMEITERATORS_HH
7#define DUNE_GRID_IO_FILE_VTK_VOLUMEITERATORS_HH
9#include <dune/grid/common/gridenums.hh>
11#include <dune/grid/io/file/vtk/corner.hh>
12#include <dune/grid/io/file/vtk/corneriterator.hh>
13#include <dune/grid/io/file/vtk/functionwriter.hh>
14#include <dune/grid/io/file/vtk/pointiterator.hh>
23 class ConformingVolumeIteratorFactory {
26 typedef typename GV::IndexSet IndexSet;
27 const IndexSet& indexSet()
const {
return gv.indexSet(); }
28 friend class ConformingConnectivityWriter<
29 ConformingVolumeIteratorFactory<GV> >;
32 static const unsigned dimCell = GV::dimension;
34 typedef typename GV::template Codim<0>::Entity Cell;
35 typedef typename GV::template Codim<0>::
36 template Partition<InteriorBorder_Partition>::Iterator CellIterator;
38 typedef VTK::Corner<Cell> Corner;
39 typedef VTK::CornerIterator<CellIterator> CornerIterator;
41 typedef VTK::Corner<Cell> Point;
42 typedef VTK::PointIterator<CellIterator,
43 typename GV::IndexSet> PointIterator;
45 typedef ConformingConnectivityWriter<ConformingVolumeIteratorFactory<GV>
47 typedef typename GV::Communication Communication;
49 explicit ConformingVolumeIteratorFactory(
const GV& gv_)
53 CellIterator beginCells()
const {
54 return gv.template begin<0, InteriorBorder_Partition>();
56 CellIterator endCells()
const {
57 return gv.template end<0, InteriorBorder_Partition>();
60 CornerIterator beginCorners()
const {
61 return CornerIterator(beginCells(), endCells());
63 CornerIterator endCorners()
const {
64 return CornerIterator(endCells());
67 PointIterator beginPoints()
const {
68 return PointIterator(beginCells(), endCells(), gv.indexSet());
70 PointIterator endPoints()
const {
71 return PointIterator(endCells());
74 ConnectivityWriter makeConnectivity()
const {
75 return ConnectivityWriter(*
this);
77 const Communication& comm()
const {
83 class NonConformingVolumeIteratorFactory {
87 static const unsigned dimCell = GV::dimension;
89 typedef typename GV::template Codim<0>::Entity Cell;
90 typedef typename GV::template Codim<0>::
91 template Partition<InteriorBorder_Partition>::Iterator CellIterator;
93 typedef VTK::Corner<Cell> Corner;
94 typedef VTK::CornerIterator<CellIterator> CornerIterator;
97 typedef CornerIterator PointIterator;
99 typedef NonConformingConnectivityWriter<Cell> ConnectivityWriter;
100 typedef typename GV::Communication Communication;
102 explicit NonConformingVolumeIteratorFactory(
const GV& gv_)
106 CellIterator beginCells()
const {
107 return gv.template begin<0, InteriorBorder_Partition>();
109 CellIterator endCells()
const {
110 return gv.template end<0, InteriorBorder_Partition>();
113 CornerIterator beginCorners()
const {
114 return CornerIterator(beginCells(), endCells());
116 CornerIterator endCorners()
const {
117 return CornerIterator(endCells());
120 PointIterator beginPoints()
const {
return beginCorners(); }
121 PointIterator endPoints()
const {
return endCorners(); }
123 ConnectivityWriter makeConnectivity()
const {
124 return ConnectivityWriter();
126 const Communication& comm()
const {
Dune namespace.
Definition: alignedallocator.hh:13