Brain  1.0.0
A fast esoteric language!
ArgsHandler.h
1 /* This is the source code of Brain Programming Language.
2  * It is licensed under GNU GPL v. 3 or later.
3  * You should have received a copy of the license in this archive (see LICENSE).
4  *
5  * Copyright Brain, 2016.
6  */
7 
8 #ifndef ARGS_HANDLER_H
9 #define ARGS_HANDLER_H
10 
11 #include "ArgsOptions.h"
12 
13 #include <string>
14 
20 {
21 protected:
23  std::string _string_file;
25  std::string _file_name;
30  void handle(int argc, char *argv[]);
31 public:
32  ArgsHandler(int argc, char *argv[]) { handle(argc, argv); }
37  std::string get_string_file();
42  std::string get_file_name();
43 };
44 
45 #endif // ARGS_HANDLER_H
std::string _file_name
The name of the string file.
Definition: ArgsHandler.h:25
std::string get_string_file()
Returns the content of the source file passed to Brain as a string.
Definition: ArgsHandler.cpp:126
std::string get_file_name()
Returns the name of the file passed to Brain as a string.
Definition: ArgsHandler.cpp:132
void handle(int argc, char *argv[])
Called in the constructor to handle all the arguments passed to Brain.
Definition: ArgsHandler.cpp:22
std::string _string_file
The source file passed to Brain.
Definition: ArgsHandler.h:23
Consumes the arguments passed to brain and do whatever actions it&#39;s supposed to.
Definition: ArgsHandler.h:19