libodsstream
Library for mass spectrometry
Loading...
Searching...
No Matches
OdsException Class Reference

#include <odsexception.h>

Inheritance diagram for OdsException:

Public Member Functions

 OdsException (const QString &message) throw ()
 
 OdsException (const OdsException &other) throw ()
 
void raise () const override
 
virtual QException * clone () const override
 
virtual const QString & qwhat () const throw ()
 
const char * what () const noexcept override
 
virtual ~OdsException () throw ()
 

Private Attributes

std::string m_stdMessage
 
QString m_message
 

Detailed Description

Definition at line 26 of file odsexception.h.

Constructor & Destructor Documentation

◆ OdsException() [1/2]

OdsException::OdsException ( const QString &  message)
throw (
)
inline

Definition at line 29 of file odsexception.h.

30 {
31 qDebug() << message;
32 m_message = message;
33 m_stdMessage.assign(m_message.toStdString());
34 }
std::string m_stdMessage
QString m_message

References m_message, and m_stdMessage.

◆ OdsException() [2/2]

OdsException::OdsException ( const OdsException other)
throw (
)
inline

Definition at line 36 of file odsexception.h.

37 {
38 m_message = other.m_message;
39 m_stdMessage.assign(m_message.toStdString());
40 }

References m_message, and m_stdMessage.

◆ ~OdsException()

virtual OdsException::~OdsException ( )
throw (
)
inlinevirtual

Definition at line 64 of file odsexception.h.

65 {
66 }

Member Function Documentation

◆ clone()

virtual QException * OdsException::clone ( ) const
inlineoverridevirtual

Definition at line 47 of file odsexception.h.

48 {
49 return new OdsException(*this);
50 }

◆ qwhat()

virtual const QString & OdsException::qwhat ( ) const
throw (
)
inlinevirtual

Definition at line 53 of file odsexception.h.

54 {
55 return m_message;
56 }

References m_message.

Referenced by TsvReader::readCsvRow().

◆ raise()

void OdsException::raise ( ) const
inlineoverride

Definition at line 42 of file odsexception.h.

43 {
44 throw *this;
45 }

◆ what()

const char * OdsException::what ( ) const
inlineoverridenoexcept

Definition at line 59 of file odsexception.h.

60 {
61 return m_stdMessage.c_str();
62 }

References m_stdMessage.

Referenced by TsvReader::readCsvRow().

Member Data Documentation

◆ m_message

QString OdsException::m_message
private

Definition at line 70 of file odsexception.h.

Referenced by OdsException(), OdsException(), and qwhat().

◆ m_stdMessage

std::string OdsException::m_stdMessage
private

Definition at line 69 of file odsexception.h.

Referenced by OdsException(), OdsException(), and what().


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