Base Framework
Public Types | Public Member Functions | List of all members
ArgumentParser::Argument Class Reference

Inherits Polymorphic.

Inherited by ArgumentParser::NamedArgument, and ArgumentParser::OrphanArgument.

Public Types

enum  Flag { EXPLICIT = 1, LATER = 2, EARLIER = 4, DEFAULT = 8 }
 

Public Member Functions

 Argument (unsigned int _flags=0) noexcept
 
bool isExplicit () const noexcept
 
bool isEarlier () const noexcept
 
bool isLater () const noexcept
 
unsigned int getFlags () const noexcept
 
void setFlags (unsigned int flags) noexcept
 
- Public Member Functions inherited from Polymorphic
 Polymorphic () noexcept
 
virtual ~Polymorphic () noexcept
 

Member Enumeration Documentation

◆ Flag

Argument flags.

Enumerator
EXPLICIT 

The value was specified.

LATER 

Argument is given later.

EARLIER 

Argument is given earlier.

DEFAULT 

Default value.

Constructor & Destructor Documentation

◆ Argument()

ArgumentParser::Argument::Argument ( unsigned int  _flags = 0)
inlinenoexcept

Initializes the argument with the specified flags.

Member Function Documentation

◆ getFlags()

unsigned int ArgumentParser::Argument::getFlags ( ) const
inlinenoexcept

Returns the flags.

◆ isEarlier()

bool ArgumentParser::Argument::isEarlier ( ) const
inlinenoexcept

Returns true if the argument is a repetition of an earlier argument.

◆ isExplicit()

bool ArgumentParser::Argument::isExplicit ( ) const
inlinenoexcept

Returns true if the value was specified.

◆ isLater()

bool ArgumentParser::Argument::isLater ( ) const
inlinenoexcept

Returns true if the argument is repeted again later.

◆ setFlags()

void ArgumentParser::Argument::setFlags ( unsigned int  flags)
inlinenoexcept

Sets the flags.