drumstick 2.7.2
sequencererror.h
Go to the documentation of this file.
1/*
2 MIDI Sequencer C++ library
3 Copyright (C) 2006-2022, Pedro Lopez-Cabanillas <plcl@users.sf.net>
4
5 This library is free software; you can redistribute it and/or modify
6 it under the terms of the GNU General Public License as published by
7 the Free Software Foundation; either version 3 of the License, or
8 (at your option) any later version.
9
10 This library is distributed in the hope that it will be useful,
11 but WITHOUT ANY WARRANTY; without even the implied warranty of
12 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
13 GNU General Public License for more details.
14
15 You should have received a copy of the GNU General Public License
16 along with this program. If not, see <http://www.gnu.org/licenses/>.
17*/
18
19#ifndef SEQUENCERERROR_H
20#define SEQUENCERERROR_H
21
22#include <exception>
23#include <QString>
24#include "macros.h"
25
40namespace drumstick { namespace ALSA {
41
53class DRUMSTICK_EXPORT SequencerError : std::exception
54{
55public:
61 SequencerError(QString const& s, int rc);
62
67 virtual const char* what() const noexcept override;
68
73 QString qstrError() const;
74
79 int code() const;
80
85 const QString& location() const;
86
87private:
88 QString m_location;
89 int m_errCode;
90};
91
94}} // namespace drumstick::ALSA
95
96#endif // SEQUENCERERROR_H
Exception class for ALSA Sequencer errors.
Provides consistent interface to handle errors.
Drumstick visibility macros.
Drumstick common.
Definition: alsaclient.cpp:68