Geogram  Version 1.9.1-rc
A programming library of geometric algorithms
GEO::String::ConversionError Class Reference

Conversion exception. More...

#include <geogram/basic/string.h>

Inheritance diagram for GEO::String::ConversionError:

Public Member Functions

 ConversionError (const std::string &s, const std::string &type)
 Constructs a conversion exception. More...
 
const char * what () const GEO_NOEXCEPT override
 Gets the string identifying the exception.
 

Detailed Description

Conversion exception.

This exception is thrown by the conversion functions to_bool(), to_int() and to_double() when a string cannot be converted to the desired type.

Definition at line 306 of file string.h.

Constructor & Destructor Documentation

◆ ConversionError()

GEO::String::ConversionError::ConversionError ( const std::string &  s,
const std::string &  type 
)

Constructs a conversion exception.

Parameters
[in]sthe input string that could not be converted
[in]typethe expected destination type

The documentation for this class was generated from the following file: