Struct Args

Struct Documentation

struct Args

Structure to hold command line parameters for the GUI.

Public Functions

inline bool GetHelp() const
inline const std::string &GetHost() const
inline uint16_t GetPort() const
bool Parse(int argc, char *argv[])

Parses command line arguments and fills the params structure.

Parameters:
  • argc – size of argv

  • argv – command line arguments

Returns:

true if all arguments are valid and parsed successfully

Returns:

false if there are invalid arguments or if malloc fails

std::string ToString() const

Debugging function to print the parsed parameters.

Parameters:

params – Params structure containing the parsed command line arguments.

Returns:

std::string A string representation of the parsed parameters.

Friends

inline friend std::ostream &operator<<(std::ostream &os, const Args &args)