a class containing an enumeration type that can be used by functions to signal successful operation or not
More...
#include "stir/Succeeded.h"
|
|
| Succeeded (const value &v=yes) |
|
bool | operator== (const Succeeded &v2) const |
|
bool | operator!= (const Succeeded &v2) const |
|
bool | succeeded () const |
| | convenience function returns if it is equal to Succeeded::yes
|
a class containing an enumeration type that can be used by functions to signal successful operation or not
Example:
Succeeded f() { do_something; return Succeeded::yes; }
void g() {
if (f() == Succeeded::no)
error(
"Error calling f"); }
void g2() {
if (!f().
succeeded()) error(
"Error calling f"); }
bool succeeded() const
convenience function returns if it is equal to Succeeded::yes
Definition Succeeded.h:57
void error(const char *const s,...)
Print error with format string a la printf and throw exception.
Definition error.cxx:42
The documentation for this class was generated from the following file:
- /home/kris/devel/STIRdistrib/STIR/src/include/stir/Succeeded.h