CuteHMI - CuteHMI (CuteHMI.2)
cutehmi::ExceptionMixin< DERIVED > Class Template Reference

Exception mixin. More...

#include <cutehmi/ExceptionMixin.hpp>

Inheritance diagram for cutehmi::ExceptionMixin< DERIVED >:
cutehmi::Exception QException

Public Member Functions

 ExceptionMixin (const QString &what)
 
void raise () const noexcept(false) override
 
Exceptionclone () const override
 
- Public Member Functions inherited from cutehmi::Exception
 Exception (const QString &what)
 
const char * what () const noexcept override
 
- Public Member Functions inherited from QException
virtual ~QException ()
 

Detailed Description

template<class DERIVED>
class cutehmi::ExceptionMixin< DERIVED >

Exception mixin.

This class template can be used to automatically reimplement raise() and clone() methods for DERIVED class. This is internally achieved through static polymorphism technique.

Constructor & Destructor Documentation

◆ ExceptionMixin()

template<class DERIVED >
cutehmi::ExceptionMixin< DERIVED >::ExceptionMixin ( const QString what)
explicit

Member Function Documentation

◆ clone()

template<class DERIVED >
Exception * cutehmi::ExceptionMixin< DERIVED >::clone
overridevirtual

Reimplemented from cutehmi::Exception.

◆ raise()

template<class DERIVED >
void cutehmi::ExceptionMixin< DERIVED >::raise
overridevirtualnoexcept

Reimplemented from cutehmi::Exception.