Public Member Functions | List of all members
GeographicLib::GeographicErr Class Reference

Exception handling for GeographicLib. More...

#include <Constants.hpp>

Inheritance diagram for GeographicLib::GeographicErr:
Inheritance graph
[legend]

Public Member Functions

 GeographicErr (const std::string &msg)
 

Detailed Description

Exception handling for GeographicLib.

A class to handle exceptions. It's derived from std::runtime_error so it can be caught by the usual catch clauses.

Example of use:

// Example of using the GeographicLib::GeographicErr class
#include <iostream>
using namespace std;
using namespace GeographicLib;
int main() {
try {
throw GeographicErr("Test throwing an exception");
}
catch (const GeographicErr& e) {
cout << "Caught exception: " << e.what() << "\n";
}
}

Definition at line 389 of file Constants.hpp.

Constructor & Destructor Documentation

◆ GeographicErr()

GeographicLib::GeographicErr::GeographicErr ( const std::string &  msg)
inline

Constructor

Parameters
[in]msga string message, which is accessible in the catch clause via what().

Definition at line 398 of file Constants.hpp.


The documentation for this class was generated from the following file:
e
Array< double, 1, 3 > e(1./3., 0.5, 2.)
GeographicLib
Namespace for GeographicLib.
Definition: JacobiConformal.hpp:15
main
int main(int argc, char **argv)
Definition: cmake/example_cmake_find_gtsam/main.cpp:63
GeographicLib::GeographicErr
Exception handling for GeographicLib.
Definition: Constants.hpp:389
Constants.hpp
Header for GeographicLib::Constants class.
GeographicLib::GeographicErr::GeographicErr
GeographicErr(const std::string &msg)
Definition: Constants.hpp:398
std
Definition: BFloat16.h:88


gtsam
Author(s):
autogenerated on Sat Nov 16 2024 04:15:07