Regina 7.3 Calculation Engine
Public Member Functions | List of all members
regina::ReginaException Class Reference

A base class for all of the exceptions that are thrown by Regina's native mathematical code. More...

#include <utilities/exception.h>

Inheritance diagram for regina::ReginaException:
regina::FailedPrecondition regina::FileError regina::InvalidArgument regina::InvalidInput regina::NoSolution regina::NotImplemented regina::SnapPeaIsNull regina::UnsolvedCase

Public Member Functions

 ReginaException (const std::string &msg)
 Creates a new exception with the given error message. More...
 
 ReginaException (const char *msg)
 Creates a new exception with the given error message. More...
 
 ReginaException (const ReginaException &) noexcept=default
 Creates a new copy of the given exception. More...
 
ReginaExceptionoperator= (const ReginaException &) noexcept=default
 Sets this to be a copy of the given exception. More...
 

Detailed Description

A base class for all of the exceptions that are thrown by Regina's native mathematical code.

This does not include SnapPeaFatalError and SnapPeaMemoryFull, which represent critical errors thrown from within the SnapPea kernel; it also does not include SnapshotWriteError, which is part of the generic (non-mathematical) snapshotting machinery.

Details of the error can be accessed through the inherited member function what().

Constructor & Destructor Documentation

◆ ReginaException() [1/3]

regina::ReginaException::ReginaException ( const std::string &  msg)
inline

Creates a new exception with the given error message.

This constructor may throw std::bad_alloc.

Parameters
msga human-readable description of the error.

◆ ReginaException() [2/3]

regina::ReginaException::ReginaException ( const char *  msg)
inline

Creates a new exception with the given error message.

This constructor may throw std::bad_alloc.

Parameters
msga human-readable description of the error.

◆ ReginaException() [3/3]

regina::ReginaException::ReginaException ( const ReginaException )
defaultnoexcept

Creates a new copy of the given exception.

Member Function Documentation

◆ operator=()

ReginaException & regina::ReginaException::operator= ( const ReginaException )
defaultnoexcept

Sets this to be a copy of the given exception.

Returns
a reference to this exception.

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

Copyright © 1999-2023, The Regina development team
This software is released under the GNU General Public License, with some additional permissions; see the source code for details.
For further information, or to submit a bug or other problem, please contact Ben Burton (bab@maths.uq.edu.au).