This file is indexed.

/usr/include/dolfin/fem/AssemblerBase.h is in libdolfin-dev 1.4.0+dfsg-4.

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
 90
 91
 92
 93
 94
 95
 96
 97
 98
 99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
// Copyright (C) 2007-2009 Anders Logg
//
// This file is part of DOLFIN.
//
// DOLFIN is free software: you can redistribute it and/or modify
// it under the terms of the GNU Lesser General Public License as published by
// the Free Software Foundation, either version 3 of the License, or
// (at your option) any later version.
//
// DOLFIN is distributed in the hope that it will be useful,
// but WITHOUT ANY WARRANTY; without even the implied warranty of
// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
// GNU Lesser General Public License for more details.
//
// You should have received a copy of the GNU Lesser General Public License
// along with DOLFIN. If not, see <http://www.gnu.org/licenses/>.
//
// Modified by Garth N. Wells, 2007-2008.
// Modified by Ola Skavhaug, 2008.
//
// First added:  2007-01-17
// Last changed: 2013-09-19

#ifndef __ASSEMBLER_BASE_H
#define __ASSEMBLER_BASE_H

#include <string>
#include <utility>
#include <vector>
#include <dolfin/common/types.h>
#include <dolfin/log/log.h>

namespace dolfin
{

  // Forward declarations
  class GenericTensor;
  class Form;

  /// This class provides type compatible with boolean used for announcing
  /// deprecation warning for deprecated bool member variable

  // TODO: Remove when not needed.
  class bool_deprecated
  {
  public:

    bool_deprecated(const bool& value, const std::string& what,
                    const std::string& ver_deprecated,
                    const std::string& ver_removed,
                    const std::string& reason)
      : _value(value), _what(what),
        _ver_deprecated(ver_deprecated),
        _ver_removed(ver_removed), _reason(reason)
    { }

    bool_deprecated(const bool_deprecated& that)
      : _value(that._value), _what(that._what),
        _ver_deprecated(that._ver_deprecated),
        _ver_removed(that._ver_removed), _reason(that._reason)
    { }

    ~bool_deprecated() { }

    bool_deprecated& operator=(const bool_deprecated& that)
    { 
      _value          = that._value;
      _what           = that._what;
      _ver_deprecated = that._ver_deprecated;
      _ver_removed    = that._ver_removed;
      _reason         = that._reason;
      return *this;
    }

    bool_deprecated& operator=(const bool& value)
    {
      deprecation(_what,
                  _ver_deprecated,
                  _ver_removed,
                  _reason);
      _value = value;
      return *this;
    }

    operator bool() const { return _value; }

  private:

    bool _value;

    std::string _what;
    std::string _ver_deprecated;
    std::string _ver_removed;
    std::string _reason;

  };

  /// This class provides some common functions used in
  /// assembler classes.

  class AssemblerBase
  {
  public:

    // Check form
    AssemblerBase() :
      reset_sparsity(true, "Parameter reset_sparsity of assembler",
                     "1.4", "1.5", "Parameter reset_sparsity of assembler"
                     " is no longer used. Tensor is reset iff empty()."),
      add_values(false),
      finalize_tensor(true),
      keep_diagonal(false) {}

    /// reset_sparsity (bool)
    ///     Deprecated. Sparsity pattern of the tensor is reset
    ///     iff the tensor is empty().
    bool_deprecated reset_sparsity;

    /// add_values (bool)
    ///     Default value is false.
    ///     This controls whether values are added to the given
    ///     tensor or if it is zeroed prior to assembly.
    bool add_values;

    /// finalize_tensor (bool)
    ///     Default value is true.
    ///     This controls whether the assembler finalizes the
    ///     given tensor after assembly is completed by calling
    ///     A.apply().
    bool finalize_tensor;

    /// keep_diagonal (bool)
    ///     Default value is false.
    ///     This controls whether the assembler enures that a diagonal
    ///     entry exists in an assembled matrix. It may be removed
    ///     if the matrix is finalised.
    bool keep_diagonal;

    // Initialize global tensor
    void init_global_tensor(GenericTensor& A, const Form& a);

  protected:

    // Check form
    static void check(const Form& a);

    // Pretty-printing for progress bar
    static std::string progress_message(std::size_t rank, std::string integral_type);

  };

}

#endif