MueLu Version of the Day
Loading...
Searching...
No Matches
MueLu_PFactory_decl.hpp
Go to the documentation of this file.
1// @HEADER
2// *****************************************************************************
3// MueLu: A package for multigrid based preconditioning
4//
5// Copyright 2012 NTESS and the MueLu contributors.
6// SPDX-License-Identifier: BSD-3-Clause
7// *****************************************************************************
8// @HEADER
9
10#ifndef MUELU_PFACTORY_DEF_HPP
11#define MUELU_PFACTORY_DEF_HPP
12
13#include "MueLu_ConfigDefs.hpp"
16
17#include "MueLu_Level_fwd.hpp"
18
19namespace MueLu {
20
29 protected:
30 bool restrictionMode_; //< true, if PFactory is used for generating the restriction operator
31
32 public:
34
35
38 : restrictionMode_(false) {}
39
41 virtual ~PFactory() {}
43
45
46
50 virtual void BuildP(Level &fineLevel, Level &coarseLevel) const = 0;
52
54
55
58 void setRestrictionMode(bool bRestrictionMode = false) {
59 restrictionMode_ = bRestrictionMode;
60 }
61
64
66
67}; // class PFactory
68
69} // namespace MueLu
70
71#define MUELU_PFACTORY_SHORT
72#endif // MUELU_PFACTORY_DEF_HPP
Class that holds all level-specific information.
Factory that provides an interface for a concrete implementation of a prolongation operator.
virtual ~PFactory()
Destructor.
bool isRestrictionModeSet()
returns restrictionMode flag
void setRestrictionMode(bool bRestrictionMode=false)
virtual void BuildP(Level &fineLevel, Level &coarseLevel) const =0
Abstract Build method.
Base class for factories that use two levels (fineLevel and coarseLevel).
Namespace for MueLu classes and methods.