#include <SwitchArg.h>
Inheritance diagram for TCLAP::SwitchArg:


Public Member Functions | |
| SwitchArg (const std::string &flag, const std::string &name, const std::string &desc, bool def=false, Visitor *v=NULL) | |
| SwitchArg constructor. | |
| SwitchArg (const std::string &flag, const std::string &name, const std::string &desc, CmdLineInterface &parser, bool def=false, Visitor *v=NULL) | |
| SwitchArg constructor. | |
| virtual bool | processArg (int *i, std::vector< std::string > &args) |
| Handles the processing of the argument. | |
| bool | combinedSwitchesMatch (std::string &combined) |
| Checks a string to see if any of the chars in the string match the flag for this Switch. | |
| bool | getValue () |
| Returns bool, whether or not the switch has been set. | |
| virtual void | reset () |
| Clears the Arg object and allows it to be reused by new command lines. | |
Protected Attributes | |
| bool | _value |
| The value of the switch. | |
| bool | _default |
| Used to support the reset() method so that ValueArg can be reset to their constructed value. | |
If the switch is set on the command line, then the getValue method will return the opposite of the default value for the switch.
Definition at line 39 of file SwitchArg.h.
|
||||||||||||||||||||||||
|
SwitchArg constructor.
Definition at line 124 of file SwitchArg.h. |
|
||||||||||||||||||||||||||||
|
SwitchArg constructor.
Definition at line 134 of file SwitchArg.h. References TCLAP::CmdLineInterface::add(). |
Here is the call graph for this function:

|
|
Checks a string to see if any of the chars in the string match the flag for this Switch.
Definition at line 149 of file SwitchArg.h. Referenced by processArg(), and TCLAP::MultiSwitchArg::processArg(). |
|
|
Returns bool, whether or not the switch has been set.
Reimplemented in TCLAP::MultiSwitchArg. Definition at line 147 of file SwitchArg.h. |
|
||||||||||||
|
Handles the processing of the argument. This re-implements the Arg version of this method to set the _value of the argument appropriately.
Implements TCLAP::Arg. Reimplemented in TCLAP::MultiSwitchArg. Definition at line 185 of file SwitchArg.h. References TCLAP::Arg::_checkWithVisitor(), _value, TCLAP::Arg::argMatches(), combinedSwitchesMatch(), and TCLAP::Arg::toString(). |
Here is the call graph for this function:

|
|
Clears the Arg object and allows it to be reused by new command lines.
Reimplemented from TCLAP::Arg. Reimplemented in TCLAP::MultiSwitchArg. Definition at line 217 of file SwitchArg.h. References _value. |
|
|
Used to support the reset() method so that ValueArg can be reset to their constructed value.
Reimplemented in TCLAP::MultiSwitchArg. Definition at line 52 of file SwitchArg.h. |
|
|
The value of the switch.
Reimplemented in TCLAP::MultiSwitchArg. Definition at line 46 of file SwitchArg.h. Referenced by processArg(), and reset(). |
1.3.9.1