vtkProcessModuleConfiguration.h
Go to the documentation of this file.
1 /*=========================================================================
2 
3  Program: ParaView
4  Module: vtkProcessModuleConfiguration.h
5 
6  Copyright (c) Kitware, Inc.
7  All rights reserved.
8  See Copyright.txt or http://www.paraview.org/HTML/Copyright.html for details.
9 
10  This software is distributed WITHOUT ANY WARRANTY; without even
11  the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR
12  PURPOSE. See the above copyright notice for more information.
13 
14 =========================================================================*/
23 #ifndef vtkProcessModuleConfiguration_h
24 #define vtkProcessModuleConfiguration_h
25 
26 #include "vtkLogger.h" // for vtkLogger::Verbosity
27 #include "vtkObject.h"
28 #include "vtkProcessModule.h" // for vtkProcessModule::ProcessTypes
29 #include "vtkRemotingCoreModule.h" //needed for exports
30 
31 #include <string> // for std::string
32 #include <vector> // for std::vector
33 
34 class vtkCLIOptions;
35 
37 {
38 public:
40  void PrintSelf(ostream& os, vtkIndent indent) override;
41 
45  static vtkProcessModuleConfiguration* GetInstance();
46 
51  vtkGetMacro(ForceMPIInit, bool);
52 
57  vtkGetMacro(ForceNoMPIInit, bool);
58 
63  vtkGetMacro(UseMPISSend, bool);
64 
70  vtkGetMacro(SymmetricMPIMode, bool);
71 
76  vtkSetMacro(SymmetricMPIMode, bool);
77 
83  vtkGetMacro(LogStdErrVerbosity, vtkLogger::Verbosity);
84 
90  std::string GetCSLogFileName() const;
91 
96  vtkGetMacro(EnableStackTrace, bool);
97 
101  const std::vector<std::pair<std::string, vtkLogger::Verbosity>>& GetLogFiles() const
102  {
103  return this->LogFiles;
104  }
105 
111  bool PopulateOptions(vtkCLIOptions* options, vtkProcessModule::ProcessTypes processType);
112 
118  static std::string GetRankAnnotatedFileName(const std::string& fname);
119 
120 protected:
122  ~vtkProcessModuleConfiguration() override;
123 
124 private:
126  void operator=(const vtkProcessModuleConfiguration&) = delete;
127 
128  bool ForceMPIInit = false;
129  bool ForceNoMPIInit = false;
130  bool UseMPISSend = false;
131  bool SymmetricMPIMode = false;
132  bool EnableStackTrace = false;
133  vtkLogger::Verbosity LogStdErrVerbosity = vtkLogger::VERBOSITY_INVALID;
134  std::string CSLogFileName;
135  std::vector<std::pair<std::string, vtkLogger::Verbosity>> LogFiles;
137 };
138 
139 #endif
void PrintSelf(ostream &os, vtkIndent indent) VTK_OVERRIDE
command line options manager
Definition: vtkCLIOptions.h:58
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 &)