Hyperiso 1.0.3
Modular flavour-physics calculations, Wilson coefficients and statistical inference
Loading...
Searching...
No Matches
Argument Class Reference

#include <ArgsParser.h>

Public Member Functions

 Argument (const std::string &longName, const std::string &shortName, const std::string &helpText, ArgType type, bool isRequired, bool allowsMultiple, std::optional< std::string > defaultValue, bool isPositional)
 
void addValidator (std::shared_ptr< IValidator > validator)
 
ArgType getType () const
 
bool validate (const std::string &value) const
 
std::string getLongName () const
 
std::string getShortName () const
 
std::string getHelpText () const
 
bool isRequiredArg () const
 
bool allowsMultipleValues () const
 
bool isPositionalArg () const
 
std::optional< std::string > getDefaultValue () const
 

Detailed Description

Definition at line 110 of file ArgsParser.h.

Constructor & Destructor Documentation

◆ Argument()

Argument::Argument ( const std::string &  longName,
const std::string &  shortName,
const std::string &  helpText,
ArgType  type,
bool  isRequired,
bool  allowsMultiple,
std::optional< std::string >  defaultValue,
bool  isPositional 
)

Definition at line 10 of file ArgsParser.cpp.

Member Function Documentation

◆ addValidator()

void Argument::addValidator ( std::shared_ptr< IValidator validator)

Definition at line 17 of file ArgsParser.cpp.

◆ allowsMultipleValues()

bool Argument::allowsMultipleValues ( ) const

Definition at line 50 of file ArgsParser.cpp.

◆ getDefaultValue()

std::optional< std::string > Argument::getDefaultValue ( ) const

Definition at line 58 of file ArgsParser.cpp.

◆ getHelpText()

std::string Argument::getHelpText ( ) const

Definition at line 42 of file ArgsParser.cpp.

◆ getLongName()

std::string Argument::getLongName ( ) const

Definition at line 34 of file ArgsParser.cpp.

◆ getShortName()

std::string Argument::getShortName ( ) const

Definition at line 38 of file ArgsParser.cpp.

◆ getType()

ArgType Argument::getType ( ) const

Definition at line 21 of file ArgsParser.cpp.

◆ isPositionalArg()

bool Argument::isPositionalArg ( ) const

Definition at line 54 of file ArgsParser.cpp.

◆ isRequiredArg()

bool Argument::isRequiredArg ( ) const

Definition at line 46 of file ArgsParser.cpp.

◆ validate()

bool Argument::validate ( const std::string &  value) const

Definition at line 25 of file ArgsParser.cpp.


The documentation for this class was generated from the following files: