vtkProcessModuleConfiguration.h
Go to the documentation of this file.
1 // SPDX-FileCopyrightText: Copyright (c) Kitware Inc.
2 // SPDX-License-Identifier: BSD-3-Clause
11 #ifndef vtkProcessModuleConfiguration_h
12 #define vtkProcessModuleConfiguration_h
13 
14 #include "vtkLogger.h" // for vtkLogger::Verbosity
15 #include "vtkObject.h"
16 #include "vtkProcessModule.h" // for vtkProcessModule::ProcessTypes
17 #include "vtkRemotingCoreModule.h" //needed for exports
18 
19 #include <string> // for std::string
20 #include <vector> // for std::vector
21 
22 class vtkCLIOptions;
23 
25 {
26 public:
28  void PrintSelf(ostream& os, vtkIndent indent) override;
29 
33  static vtkProcessModuleConfiguration* GetInstance();
34 
39  vtkGetMacro(ForceMPIInit, bool);
40 
45  vtkGetMacro(ForceNoMPIInit, bool);
46 
51  vtkGetMacro(UseMPISSend, bool);
52 
58  vtkGetMacro(SymmetricMPIMode, bool);
59 
64  vtkSetMacro(SymmetricMPIMode, bool);
65 
69  vtkGetMacro(VirtualEnvironmentPath, std::string);
70 
76  vtkGetMacro(LogStdErrVerbosity, vtkLogger::Verbosity);
77 
83  std::string GetCSLogFileName() const;
84 
89  vtkGetMacro(EnableStackTrace, bool);
90 
94  const std::vector<std::pair<std::string, vtkLogger::Verbosity>>& GetLogFiles() const
95  {
96  return this->LogFiles;
97  }
98 
104  bool PopulateOptions(vtkCLIOptions* options, vtkProcessModule::ProcessTypes processType);
105 
111  static std::string GetRankAnnotatedFileName(const std::string& fname);
112 
113 protected:
115  ~vtkProcessModuleConfiguration() override;
116 
117 private:
119  void operator=(const vtkProcessModuleConfiguration&) = delete;
120 
121  bool ForceMPIInit = false;
122  bool ForceNoMPIInit = false;
123  bool UseMPISSend = false;
124  bool SymmetricMPIMode = false;
125  std::string VirtualEnvironmentPath;
126  bool EnableStackTrace = false;
127  vtkLogger::Verbosity LogStdErrVerbosity = vtkLogger::VERBOSITY_INVALID;
128  std::string CSLogFileName;
129  std::vector<std::pair<std::string, vtkLogger::Verbosity>> LogFiles;
131 };
132 
133 #endif
void PrintSelf(ostream &os, vtkIndent indent) VTK_OVERRIDE
command line options manager
Definition: vtkCLIOptions.h:46
const std::vector< std::pair< std::string, vtkLogger::Verbosity > > & GetLogFiles() const
Returns a vector of pairs for log files requested.
#define VTKREMOTINGCORE_EXPORT
runtime configuration for vtkProcessModule
static vtkObject * New()
void operator=(const vtkObjectBase &)