CAPD DynSys Library 5.2.0
capd::auxil::argflags Class Reference

This is a helper class which defines specific flags indicating various types of command-line arguments and the state of interpreting them. More...

#include <capd/auxil/arg.h>

Public Types

enum  names {
  obligatory = 0x01 , hasdefault = 0x02 , filled = 0x04 , breakinterpreting = 0x08 ,
  toomany = 0x10 , missingvalue = 0x20 , readerror = 0x40 , ignorevalue = 0x80
}
 A list of specific names for the flags. More...
 

Public Member Functions

 argflags ()
 The constructor. All flags are initially cleared (unset). More...
 
 ~argflags ()
 The destructor. More...
 
void set (int flag)
 Sets the given flag. More...
 
void unset (int flag)
 Unsets (clears) the given flag. More...
 
bool get (int flag) const
 Returns true if any of the given flags is set or false otherwise. More...
 

Detailed Description

This is a helper class which defines specific flags indicating various types of command-line arguments and the state of interpreting them.

Member Enumeration Documentation

◆ names

A list of specific names for the flags.

Enumerator
obligatory 
hasdefault 
filled 
breakinterpreting 
toomany 
missingvalue 
readerror 
ignorevalue 

Constructor & Destructor Documentation

◆ argflags()

capd::auxil::argflags::argflags ( )
inline

The constructor. All flags are initially cleared (unset).

◆ ~argflags()

capd::auxil::argflags::~argflags ( )
inline

The destructor.

Member Function Documentation

◆ get()

bool capd::auxil::argflags::get ( int  flag) const
inline

Returns true if any of the given flags is set or false otherwise.

◆ set()

void capd::auxil::argflags::set ( int  flag)
inline

Sets the given flag.

◆ unset()

void capd::auxil::argflags::unset ( int  flag)
inline

Unsets (clears) the given flag.