MySQL 8.4.3
Source Code Documentation
CmdOption Struct Reference

CmdOption stores information about command line options. More...

#include <arg_handler.h>

Public Types

using ActionFunc = std::function< void(const std::string &)>
 
using AtEndActionFunc = std::function< void(const std::string &)>
 
using OptionNames = std::vector< std::string >
 

Public Member Functions

 CmdOption (OptionNames names_, std::string description_, CmdOptionValueReq value_req_, const std::string metavar_, ActionFunc action_, AtEndActionFunc at_end_action_=[](const std::string &) {})
 

Public Attributes

OptionNames names
 
std::string description
 
CmdOptionValueReq value_req
 
std::string value
 
std::string metavar
 
ActionFunc action
 
AtEndActionFunc at_end_action
 
bool required {false}
 

Detailed Description

CmdOption stores information about command line options.

The CmdOption structure stores information about command line options.

Member Typedef Documentation

◆ ActionFunc

using CmdOption::ActionFunc = std::function<void(const std::string &)>

◆ AtEndActionFunc

using CmdOption::AtEndActionFunc = std::function<void(const std::string &)>

◆ OptionNames

using CmdOption::OptionNames = std::vector<std::string>

Constructor & Destructor Documentation

◆ CmdOption()

CmdOption::CmdOption ( OptionNames  names_,
std::string  description_,
CmdOptionValueReq  value_req_,
const std::string  metavar_,
ActionFunc  action_,
AtEndActionFunc  at_end_action_ = [](const std::string &) {} 
)
inline

Member Data Documentation

◆ action

ActionFunc CmdOption::action

◆ at_end_action

AtEndActionFunc CmdOption::at_end_action

◆ description

std::string CmdOption::description

◆ metavar

std::string CmdOption::metavar

◆ names

OptionNames CmdOption::names

◆ required

bool CmdOption::required {false}

◆ value

std::string CmdOption::value

◆ value_req

CmdOptionValueReq CmdOption::value_req

The documentation for this struct was generated from the following file: