1#ifndef DUNE_FEM_GRIDPART_COMMON_POLICIES_HH
2#define DUNE_FEM_GRIDPART_COMMON_POLICIES_HH
4#warning "This header should not be needed anymore. Remove it from the include list!"
10#include <dune/grid/common/gridview.hh>
12#include <dune/fem/gridpart/common/gridpart2gridview.hh>
23 template<
class Traits >
24 class GridPartPolicies;
30 namespace __GridPartPolicies
36 template<
class Traits >
37 std::true_type __hasGridView (
const Traits &,
const typename Traits::GridViewType * =
nullptr );
39 std::false_type __hasGridView ( ... );
41 template<
class Traits >
44 static const bool v =
decltype( __hasGridView( std::declval< Traits >() ) )::value;
52 template< class Traits, bool hasGridView = hasGridView< Traits >::v >
55 template<
class Traits >
56 class HasGridView< Traits, true >
59 typedef typename Traits::GridViewType GridViewType;
62 template<
class Traits >
63 class HasGridView< Traits, false >
65 typedef typename Traits::GridPartType GridPartType;
71 HasGridView () =
default;
74 operator GridPart2GridViewImpl< GridPartType > ()
const
76 return GridPart2GridViewImpl< GridPartType >( impl() );
80 const GridPartType &impl ()
const
82 return static_cast< const GridPartType &
>( *this );
95 template<
class Traits >
96 class GridPartPolicies
97 :
public __GridPartPolicies::HasGridView< Traits >
Grid view abstract base class.
Definition: gridview.hh:66
Dune namespace.
Definition: alignedallocator.hh:13