Public Member Functions | Protected Attributes | List of all members
ecl::XorHandler Class Reference

TClap class indirectly used by CmdLine for handling xor'd arguments. More...

#include <xor_handler.hpp>

Public Member Functions

void add (std::vector< Arg * > &ors)
 
int check (const Arg *a)
 
bool contains (const Arg *a)
 
std::vector< std::vector< Arg * > > & getXorList ()
 
void printLongUsage (std::ostream &os)
 
std::string shortUsage ()
 
 XorHandler ()
 

Protected Attributes

std::vector< std::vector< Arg * > > _orList
 

Detailed Description

TClap class indirectly used by CmdLine for handling xor'd arguments.

This class handles lists of Arg's that are to be XOR'd on the command line. This is used by CmdLine and you shouldn't ever use it.

Definition at line 34 of file xor_handler.hpp.

Constructor & Destructor Documentation

◆ XorHandler()

ecl::XorHandler::XorHandler ( )
inline

Constructor. Does nothing.

Definition at line 50 of file xor_handler.hpp.

Member Function Documentation

◆ add()

void ecl::XorHandler::add ( std::vector< Arg * > &  ors)
inline

Add a list of Arg*'s that will be orred together.

Parameters
ors- list of Arg* that will be xor'd.

Definition at line 91 of file xor_handler.hpp.

◆ check()

int ecl::XorHandler::check ( const Arg a)
inline

Checks whether the specified Arg is in one of the xor lists and if it does match one, returns the size of the xor list that the Arg matched. If the Arg matches, then it also sets the rest of the Arg's in the list. You shouldn't use this.

Parameters
a- The Arg to be checked.

Definition at line 96 of file xor_handler.hpp.

◆ contains()

bool ecl::XorHandler::contains ( const Arg a)
inline

Simply checks whether the Arg is contained in one of the arg lists.

Parameters
a- The Arg to be checked.

Definition at line 127 of file xor_handler.hpp.

◆ getXorList()

std::vector< std::vector< Arg * > > & ecl::XorHandler::getXorList ( )
inline

Definition at line 139 of file xor_handler.hpp.

◆ printLongUsage()

void ecl::XorHandler::printLongUsage ( std::ostream &  os)

Prints the XOR specific long usage.

Parameters
os- Stream to print to.

◆ shortUsage()

std::string ecl::XorHandler::shortUsage ( )

Returns the XOR specific short usage.

Member Data Documentation

◆ _orList

std::vector< std::vector<Arg*> > ecl::XorHandler::_orList
protected

The list of of lists of Arg's to be or'd together.

Definition at line 43 of file xor_handler.hpp.


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


ecl_command_line
Author(s): Daniel Stonier
autogenerated on Sun Aug 2 2020 03:12:03