Fulcrum/Common.h
Calin Culianu 3f49dce1db Added some small goodies
- Util::RunInThread to run a lambda in a thread
- App exit handling cleanup
- EXMgr uses an id for clients now
- EXMgr keeps track of lagging clients
- EXMgr more aggressive with reconnects if no valid exclients
- Nits and refactorings and misc. cleanup
2019-04-27 12:38:50 +03:00

33 lines
603 B
C++

#ifndef EXCEPTIONS_H
#define EXCEPTIONS_H
#include <exception>
#include <QString>
class Exception : public std::runtime_error
{
public:
Exception(const QString & what = "Error") : std::runtime_error(what.toUtf8()) {}
~Exception(); ///< for vtable
};
class InternalError : public Exception
{
public:
using Exception::Exception;
};
class BadArgs : public Exception
{
public:
using Exception::Exception;
};
#define APPNAME "ShuffleUpServer"
#define VERSION "1.0"
#ifdef QT_DEBUG
# define VERSION_EXTRA "(Debug)"
#else
# define VERSION_EXTRA "(Release)"
#endif
#endif // EXCEPTIONS_H