tlx
CmdlineParser::ArgumentBytes64 Struct Referencefinal

specialization of argument for SI/IEC suffixes byte size options or parameters More...

Inheritance diagram for CmdlineParser::ArgumentBytes64:
CmdlineParser::Argument

Public Member Functions

 ArgumentBytes64 (char key, const std::string &longkey, const std::string &keytype, const std::string &desc, bool required, uint64_t &dest)
 contructor filling most attributes More...
 
const char * type_name () const final
 return formatted type name to user More...
 
bool process (int &argc, const char *const *&argv) final
 parse byte size using SI/IEC parser. More...
 
void print_value (std::ostream &os) const final
 format value to ostream More...
 
- Public Member Functions inherited from CmdlineParser::Argument
 Argument (char key, const std::string &longkey, const std::string &keytype, const std::string &desc, bool required)
 contructor filling most attributes More...
 
virtual ~Argument ()=default
 empty virtual destructor More...
 
std::string param_text () const
 return 'longkey [keytype]' More...
 
std::string option_text () const
 return '-s, –longkey [keytype]' More...
 

Public Attributes

uint64_t & dest_
 
- Public Attributes inherited from CmdlineParser::Argument
char key_
 single letter short option, or 0 is none More...
 
std::string longkey_
 long option key or name for parameters More...
 
std::string keytype_
 option type description, e.g. "<#>" to indicate numbers More...
 
std::string desc_
 longer description, which will be wrapped More...
 
bool required_
 required, process() fails if the option/parameter is not found. More...
 
bool found_
 found during processing of command line More...
 
bool repeated_
 repeated argument, i.e. std::vector<std::string> More...
 

Detailed Description

specialization of argument for SI/IEC suffixes byte size options or parameters

Definition at line 307 of file cmdline_parser.cpp.

Constructor & Destructor Documentation

ArgumentBytes64 ( char  key,
const std::string &  longkey,
const std::string &  keytype,
const std::string &  desc,
bool  required,
uint64_t &  dest 
)
inline

contructor filling most attributes

Definition at line 311 of file cmdline_parser.cpp.

Member Function Documentation

void print_value ( std::ostream &  os) const
inlinefinalvirtual

format value to ostream

Implements CmdlineParser::Argument.

Definition at line 331 of file cmdline_parser.cpp.

bool process ( int &  argc,
const char *const *&  argv 
)
inlinefinalvirtual

parse byte size using SI/IEC parser.

Implements CmdlineParser::Argument.

Definition at line 319 of file cmdline_parser.cpp.

const char* type_name ( ) const
inlinefinalvirtual

return formatted type name to user

Implements CmdlineParser::Argument.

Definition at line 316 of file cmdline_parser.cpp.

Member Data Documentation

uint64_t& dest_

Definition at line 308 of file cmdline_parser.cpp.


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