![]() |
GURLS++
2.0.00
C++ Implementation of GURLS Matlab Toolbox
|
OptString is an option containing a generic string.
#include <options.h>
Public Types | |
typedef std::string | ValueType |
Public Member Functions | |
virtual const std::type_info & | getDataID () |
Returns the identifier of the option type. | |
OptTypes | getType () const |
Returns the option type. | |
std::string & | getValue () |
Returns the string value. | |
const std::string & | getValue () const |
Returns the string value. | |
virtual bool | isA (OptTypes id) const |
Checks if the option has the given type. | |
virtual std::ostream & | operator<< (std::ostream &os) const |
Writes the option to a stream. | |
OptString & | operator= (const OptString &other) |
Copies the opt values from an existing OptString. | |
OptString & | operator= (const std::string &other) |
Copies the string value of the option from an existing string. | |
OptString () | |
Empty constructor. | |
OptString (const std::string &str) | |
Constructor from a char buffer. | |
OptString (const std::wstring &str) | |
Constructor from a wstring. | |
void | setValue (const std::string &newvalue) |
Copies the string value of the option from an existing string. | |
~OptString () | |
Destructor. | |
Static Public Member Functions | |
static OptString * | dynacast (GurlsOption *opt) |
Tries to cast a pointer to a generic option to a pointer to an OptString. | |
static const OptString * | dynacast (const GurlsOption *opt) |
Tries to cast a pointer to a generic option to a pointer to an OptString. | |
Protected Attributes | |
OptTypes | type |
Option type. | |
std::string | value |
String containing the option value. | |
Friends | |
GURLS_EXPORT std::ostream & | operator<< (std::ostream &os, const GurlsOption &opt) |
Writes an option to a stream. |
gurls::OptString::OptString | ( | const std::string & | str | ) |
Constructor from a string
Definition at line 451 of file options.cpp.
: GurlsOption(StringOption),value(str){}