TCLAP::VALUE_ARG_HELPER::ValueExtractor< T > Class Template Reference

This class is used to extract a value from an argument. More...

#include <ValueArg.h>

Collaboration diagram for TCLAP::VALUE_ARG_HELPER::ValueExtractor< T >:

Collaboration graph
[legend]
List of all members.

Private Member Functions

 ValueExtractor (T &value)
 Constructor.
int extractValue (const std::string &val)
 Method that will attempt to parse the input stream for a value of type T.

Private Attributes

T & _value
 Reference to the value where the result of the extraction will be put.

Friends

class ValueArg< T >

Detailed Description

template<class T>
class TCLAP::VALUE_ARG_HELPER::ValueExtractor< T >

This class is used to extract a value from an argument.

It is used because we need a special implementation to deal with std::string and making a specialiced function puts it in the T segment, thus generating link errors. Having a specialiced class makes the symbols weak. This is not pretty but I don't know how to make it work any other way.


Constructor & Destructor Documentation

template<class T>
TCLAP::VALUE_ARG_HELPER::ValueExtractor< T >::ValueExtractor ( T &  value  )  [inline, private]

Constructor.

Parameters:
value - Where the value extracted will be put.


Member Function Documentation

template<class T>
int TCLAP::VALUE_ARG_HELPER::ValueExtractor< T >::extractValue ( const std::string &  val  )  [inline, private]

Method that will attempt to parse the input stream for a value of type T.

Parameters:
val - Where the value parsed will be put.


Friends And Related Function Documentation

template<class T>
friend class ValueArg< T > [friend]


Member Data Documentation

template<class T>
T& TCLAP::VALUE_ARG_HELPER::ValueExtractor< T >::_value [private]

Reference to the value where the result of the extraction will be put.


The documentation for this class was generated from the following file:
Generated on Sun Mar 11 15:33:27 2007 for MetalWarriors by  doxygen 1.4.7