Pteros  2.0
Molecular modeling library for human beings!
pteros::Pteros_error Class Reference

Represents an error in the Pteros code. Used for all Pteros-related exceptions. More...

#include <pteros_error.h>

Public Member Functions

 Pteros_error (const Pteros_error &p)
 
 Pteros_error (std::string s)
 Constructs an exception object with text message.
 
template<class T >
Pteros_erroroperator<< (T data)
 Operator << allows constructing error strings on the fly like this: More...
 
void print () const
 Print error message.
 
std::string what () const
 Return error message as string.
 

Detailed Description

Represents an error in the Pteros code. Used for all Pteros-related exceptions.

Member Function Documentation

template<class T >
Pteros_error& pteros::Pteros_error::operator<< ( data)
inline

Operator << allows constructing error strings on the fly like this:

throw Pteros_error("Wrong number ") << 5
<< " should be between "
<< 7 << " and " << 10;

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