Microflow 3D  v1.0
CmdLineArgsParser.h
Go to the documentation of this file.
1 // ==============================================================================================
2 // Microflow 3D, http://www.microflow.pwr.edu.pl/
3 // Created by Roman Szafran on 25.03.19.
4 // Copyright (c) 2019 Wroclaw University of Science and Technology.
5 // Distributed under the Apache License, Version 2.0. You may obtain a copy of the License at
6 // http://www.apache.org/licenses/LICENSE-2.0 or see accompanying file license.txt.
7 // Redistributions of source code must retain the above copyright and license notice.
8 // ==============================================================================================
9 
10 #pragma once
11 
12 #include <iostream>
13 #include <cstring>
14 #include <memory>
15 #include <string>
16 
17 namespace MF {
18  namespace Parser {
19 
22  public:
23  CmdLineArgsParser() = default;
24 
25  ~CmdLineArgsParser() = default;
26 
27  static std::shared_ptr<MF::Parser::CmdLineArgsParser> New() {
28  auto CmdLineArgsParser_Ptr = std::make_shared<MF::Parser::CmdLineArgsParser>();
29  return CmdLineArgsParser_Ptr;
30  };
31 
32  void parseCmdLineArgs(int argc, char **argv, const char *&pathToProgramConfigFile, const char *&pathToCaseFolder, const char *&scope,
33  bool &verbose, bool &geometryOnly, int &CPU_ThreadsNr);
34 
35  private:
36  void usageInfo();
37  };
38  } /* namespace Parser */
39 } /* namespace MF */
40 
The object of CmdLineArgsParser class parses parameters and its values transferred through the comman...
void parseCmdLineArgs(int argc, char **argv, const char *&pathToProgramConfigFile, const char *&pathToCaseFolder, const char *&scope, bool &verbose, bool &geometryOnly, int &CPU_ThreadsNr)
static std::shared_ptr< MF::Parser::CmdLineArgsParser > New()