Panzer  Version of the Day
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Groups Pages
Panzer_ResponseBase.hpp
Go to the documentation of this file.
1 // @HEADER
2 // *****************************************************************************
3 // Panzer: A partial differential equation assembly
4 // engine for strongly coupled complex multiphysics systems
5 //
6 // Copyright 2011 NTESS and the Panzer contributors.
7 // SPDX-License-Identifier: BSD-3-Clause
8 // *****************************************************************************
9 // @HEADER
10 
11 #ifndef __Panzer_ResponseBase_hpp__
12 #define __Panzer_ResponseBase_hpp__
13 
14 #include <string>
15 
17 
18 namespace panzer {
19 
20 // *** Derive, do not modify this interface ***
21 
28 public:
29 
35  ResponseBase(const std::string & responseName) :
36  responseName_(responseName) {}
37 
38  virtual ~ResponseBase() {}
39 
42  std::string getName() const { return responseName_; }
43 
47  std::string getLookupName() const { return buildLookupName(responseName_); }
48 
52  static std::string buildLookupName(const std::string & responseName)
53  { return "RESPONSE_"+responseName; }
54 
56  virtual void ghostToGlobal(int)
57  { scatterResponse(); }
58 
59  virtual void initializeData()
60  { initializeResponse(); }
61 
63  virtual void scatterResponse() = 0;
64 
65  virtual void initializeResponse() = 0;
66 
67 private:
68 
69  std::string responseName_;
70 
71  // hide these methods
72  ResponseBase();
73  ResponseBase(const ResponseBase &);
74 };
75 
76 }
77 
78 #endif
static std::string buildLookupName(const std::string &responseName)
ResponseBase(const std::string &responseName)
std::string getName() const
virtual void ghostToGlobal(int)
Inherited from GlobalEvaluationData,.
virtual void scatterResponse()=0
Prepare the response for access by the user (do global communication)
virtual void initializeResponse()=0
std::string getLookupName() const