This file is indexed.

/usr/include/dune/localfunctions/utility/dglocalcoefficients.hh is in libdune-localfunctions-dev 2.2.1-2.

This file is owned by root:root, with mode 0o644.

The actual contents of the file can be viewed below.

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
#ifndef DUNE_DGLOCALCOEFFICIENTS_HH
#define DUNE_DGLOCALCOEFFICIENTS_HH

#include <cassert>
#include <vector>

#include <dune/geometry/topologyfactory.hh>
#include <dune/localfunctions/common/localkey.hh>

namespace Dune
{

  // DGLocalCoefficients
  // -------------------
  
  /**
   * @brief A class providing local coefficients for dg spaces
   **/
  class DGLocalCoefficients
  {
    typedef DGLocalCoefficients This;

  public:
    //! construct local keys for n basis functions
    DGLocalCoefficients ( const unsigned int n )
    : localKey_( n )
    {
      for( unsigned i = 0; i < n; ++i )
        localKey_[ i ] = LocalKey( 0, 0, i );
    }

    const LocalKey &localKey ( const unsigned int i ) const
    {
      assert( i < size() );
      return localKey_[ i ];
    }

    unsigned int size () const
    {
      return localKey_.size();
    }

  private:
    std::vector< LocalKey > localKey_;
  };



  // DGLocalCoefficientsFactory
  // --------------------------
  /** 
   * @brief A factory class for the dg local coefficients.
   **/
  template< class BasisCreator >
  struct DGLocalCoefficientsFactory;
  template< class BasisFactory >
  struct DGLocalCoefficientsFactoryTraits
  {
    static const unsigned int dimension = BasisFactory::dimension;
    typedef typename BasisFactory::Key Key;
    typedef DGLocalCoefficients LocalCoefficients;
    typedef const DGLocalCoefficients Object;
    typedef DGLocalCoefficientsFactory<BasisFactory> Factory;
  };

  template< class BasisFactory >
  struct DGLocalCoefficientsFactory :
    public TopologyFactory< DGLocalCoefficientsFactoryTraits<BasisFactory> >
  {
    typedef DGLocalCoefficientsFactoryTraits<BasisFactory> Traits;

    static const unsigned int dimension = Traits::dimension;
    typedef typename Traits::Key Key;
    typedef typename Traits::Object Object;

    template< class Topology >
    static Object *createObject ( const Key &key )
    {
      const typename BasisFactory::Object *basis
        = BasisFactory::template create< Topology >( key );
      Object *coefficients = new Object( basis->size() );
      BasisFactory::release( basis );
      return coefficients;
    }
  };

}

#endif // #ifndef DUNE_DGLOCALCOEFFICIENTS_HH