SUMO - Simulation of Urban MObility
|
#include <TplConvert.h>
Static Public Member Functions | |
static bool | _2bool (const E *const data) |
static bool | _2bool (const E *const data, unsigned length) |
static char * | _2charp (const E *const data) |
static char * | _2charp (const E *const data, int length) |
static int | _2int (const E *const data) |
static int | _2int (const E *const data, unsigned length) |
static long | _2long (const E *const data) |
static long | _2long (const E *const data, unsigned length) |
static std::string | _2str (const E *const data) |
static std::string | _2str (const E *const data, unsigned length) |
static SUMOReal | _2SUMOReal (const E *const data) |
static SUMOReal | _2SUMOReal (const E *const data, unsigned length) |
static unsigned | getLength (const E *const data) |
TplConvert Some methods that convert 0-terminated char-arrays of any type into other values (numerical/boolean) or into std::strings
Definition at line 51 of file TplConvert.h.
|
inlinestatic |
converts a 0-terminated char-type array into the SUMOReal value described by it returns true when the first char is one of the following: '1', 'x', 't', 'T' throws an EmptyData - exception if the given string is empty
Definition at line 96 of file TplConvert.h.
Referenced by SUMOSAXAttributesImpl_Xerces::getBool().
|
inlinestatic |
converts a char-type array into the SUMOReal value described by it considering the given length returns true when the first char is one of the following: '1', 'x', 't', 'T' throws an EmptyData - exception if the given string is empty
Definition at line 282 of file TplConvert.h.
|
inlinestatic |
converts a 0-terminated char-type array into a 0-terminated 0-terminated c-char-string throws an EmptyData - exception if the given string is empty
Definition at line 104 of file TplConvert.h.
References TplConvert< E >::getLength().
|
inlinestatic |
converts a char-type array into a 0-terminated 0-terminated c-char-string considering the given length throws an EmptyData - exception if the given string is empty
Definition at line 300 of file TplConvert.h.
|
inlinestatic |
converts a 0-terminated char-type array into the integer value described by it throws an EmptyData - exception if the given string is empty throws a NumberFormatException - exception when the string does not contain an integer
Definition at line 66 of file TplConvert.h.
Referenced by TplConvert< E >::_2SUMOReal(), SUMOSAXAttributesImpl_Xerces::getInt(), getVehicleEmissionTypeID(), parseSingleTime(), parseTimeLine(), RODFDetFlowLoader::read(), readO(), and readV().
|
inlinestatic |
converts a char-type array into the integer value described by it considering the given length throws an EmptyData - exception if the given string is empty throws a NumberFormatException - exception when the string does not contain an integer
Definition at line 141 of file TplConvert.h.
|
inlinestatic |
converts a 0-terminated char-type array into the long value described by it throws an EmptyData - exception if the given string is empty throws a NumberFormatException - exception when the string does not contain a long
Definition at line 76 of file TplConvert.h.
Referenced by SUMOSAXAttributesImpl_Xerces::getLong().
|
inlinestatic |
converts a char-type array into the long value described by it considering the given length throws an EmptyData - exception if the given string is empty throws a NumberFormatException - exception when the string does not contain a long
Definition at line 175 of file TplConvert.h.
|
inlinestatic |
converts a 0-terminated char-type array into std::string throws an EmptyData - exception if the given string is empty
Definition at line 56 of file TplConvert.h.
References TplConvert< E >::getLength().
Referenced by SUMOSAXAttributesImpl_Xerces::getString().
|
inlinestatic |
converts a char-type array into std::string considering the given length throws an EmptyData - exception if the given string is empty
Definition at line 113 of file TplConvert.h.
|
inlinestatic |
converts a 0-terminated char-type array into the SUMOReal value described by it throws an EmptyData - exception if the given string is empty throws a NumberFormatException - exception when the string does not contain a SUMOReal
Definition at line 86 of file TplConvert.h.
Referenced by SUMOSAXAttributesImpl_Xerces::getFloat(), NIImporter_VISUM::getNamedFloat(), getTurningDefaults(), RGBColor::parseColor(), parseTimeLine(), RODFDetFlowLoader::read(), readFactor(), readO(), and readV().
|
inlinestatic |
converts a char-type array into the SUMOReal value described by it considering the given length throws an EmptyData - exception if the given string is empty throws a NumberFormatException - exception when the string does not contain a SUMOReal
Definition at line 209 of file TplConvert.h.
References TplConvert< E >::_2int(), and SUMOReal.
|
inlinestatic |
returns the length of the string (the position of the 0-character)
Definition at line 315 of file TplConvert.h.
Referenced by TplConvert< E >::_2charp(), and TplConvert< E >::_2str().