Files
salmanoff/hcore/include/opts.h
T
hayodea 3b6ca14275 CmdOpts: merge -[i|a|e] into one -s option
We augmented the grammar to specify the type of device (intero,
extro or actuator) so we can now collapse the 3 dev spec cmd
line opts into 1 opt.
2025-01-07 14:05:23 -04:00

28 lines
554 B
C++

#ifndef OPTS_H
#define OPTS_H
#include <vector>
#include <string>
#include <getopt.h>
// Define a class to hold the options and parse arguments
class OptionParser
{
public:
OptionParser() : verbose(false), printUsage(false) {}
~OptionParser() = default;
void parseArguments(int argc, char *argv[]);
void dumpOptions() const;
std::string getUsage() const;
public:
std::string deviceSpecs;
std::vector<std::string> deviceSpecFiles;
bool verbose, printUsage;
static struct option longOptions[];
};
#endif // OPTS_H