|
carputils
Doxygen code documentation for the python framework controlling openCARP
|
Class defining YAML conform string conversion methods. More...
Public Member Functions | |
| def | __init__ (self) |
| Method to initialize the CMLConverterYAML object. More... | |
Static Public Member Functions | |
| def | to_bool (s) |
| Tries to convert a given string to a boolean. More... | |
| def | to_none (s) |
| Tries to convert a given string to None. More... | |
| def | convert (s) |
| Convert a given string, the type is auto-detected. More... | |
Static Public Member Functions inherited from carputils.cml.cmlconverter.CMLConverter | |
| def | is_valid_string (s) |
| Checks whether the given string is a valid string or not. More... | |
| def | is_identifier (s) |
| Checks whether the given string is a valid identifier or not. More... | |
| def | make_identifier (s, substitute='_') |
| Tries to convert the given string to a valid identifier. More... | |
| def | to_int (s) |
| Tries to convert a given string to an integer. More... | |
| def | to_float (s) |
| Tries to convert a given string to a float. More... | |
| def | to_string (s) |
| Tries to convert a given string to a string. More... | |
Static Public Attributes | |
| dictionary | BOOL_DICT = {'true': True, 'yes': True, 'false': False, 'no': False} |
| Dictionary holding all strings which are converted to True/False. More... | |
| tuple | NONE_LIST = ('none', 'null', 'nil') |
| Tuple holding all strings which are converted to None. More... | |
Class defining YAML conform string conversion methods.
| def carputils.cml.cmlconverter.CMLConverterYAML.__init__ | ( | self | ) |
Method to initialize the CMLConverterYAML object.
Reimplemented from carputils.cml.cmlconverter.CMLConverter.
|
static |
Convert a given string, the type is auto-detected.
| s | The string to be converted |
Reimplemented from carputils.cml.cmlconverter.CMLConverter.
|
static |
Tries to convert a given string to a boolean.
| s | The string to be converted |
|
static |
Tries to convert a given string to None.
| s | The string to be converted |
|
static |
Dictionary holding all strings which are converted to True/False.
|
static |
Tuple holding all strings which are converted to None.