MueLu Version of the Day
Loading...
Searching...
No Matches
MueLu_FacadeClassBase_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 PACKAGES_MUELU_SRC_INTERFACE_FACADECLASSES_MUELU_FACADECLASSBASE_DECL_HPP_
11#define PACKAGES_MUELU_SRC_INTERFACE_FACADECLASSES_MUELU_FACADECLASSBASE_DECL_HPP_
12
13#include "MueLu_BaseClass.hpp"
14
15namespace MueLu {
16
17template <class Scalar = DefaultScalar,
20 class Node = DefaultNode>
22 : public virtual BaseClass {
23#undef MUELU_FACADECLASSBASE_SHORT
25
26 public:
28
29
32
34 virtual ~FacadeClassBase() {}
35
37
42 virtual Teuchos::RCP<Teuchos::ParameterList> SetParameterList(const Teuchos::ParameterList& paramList) = 0;
43
44 protected:
47 std::string ReplaceString(std::string& subject, const std::string& search, const std::string& replace) {
48 size_t pos = 0;
49 while ((pos = subject.find(search, pos)) != std::string::npos) {
50 subject.replace(pos, search.length(), replace);
51 pos += replace.length();
52 }
53 return subject;
54 }
55};
56
57} // namespace MueLu
58
59#define MUELU_FACADECLASSBASE_SHORT
60
61#endif /* PACKAGES_MUELU_SRC_INTERFACE_FACADECLASSES_MUELU_FACADECLASSBASE_DECL_HPP_ */
MueLu::DefaultLocalOrdinal LocalOrdinal
MueLu::DefaultScalar Scalar
MueLu::DefaultGlobalOrdinal GlobalOrdinal
MueLu::DefaultNode Node
Base class for MueLu classes.
std::string ReplaceString(std::string &subject, const std::string &search, const std::string &replace)
Replace all occurrences of search string "search" by the string in "replace" given the string "subjec...
virtual Teuchos::RCP< Teuchos::ParameterList > SetParameterList(const Teuchos::ParameterList &paramList)=0
Set parameter list for FacadeClass (abstract member).
Namespace for MueLu classes and methods.
Tpetra::KokkosClassic::DefaultNode::DefaultNodeType DefaultNode
Tpetra::Details::DefaultTypes::scalar_type DefaultScalar