diff options
author | Christian Glöckner <cgloeckner@freenet.de> | 2016-03-29 15:36:53 +0200 |
---|---|---|
committer | André Nusser <andre.nusser@googlemail.com> | 2016-03-31 17:35:47 +0200 |
commit | bc4e506e48785ce448f18098b96c0d7333abb801 (patch) | |
tree | 1f282fe53493fe0292ef51a791c8f61283e44542 /src/drumkit.h | |
parent | 1a8361a1f6a1bf442d474cf5baf2e9a09f511777 (diff) |
API Refactoring for class Drumkit
Diffstat (limited to 'src/drumkit.h')
-rw-r--r-- | src/drumkit.h | 45 |
1 files changed, 22 insertions, 23 deletions
diff --git a/src/drumkit.h b/src/drumkit.h index 24fce99..1ceef3e 100644 --- a/src/drumkit.h +++ b/src/drumkit.h @@ -24,8 +24,7 @@ * along with DrumGizmo; if not, write to the Free Software * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA. */ -#ifndef __DRUMGIZMO_DRUMKIT_H__ -#define __DRUMGIZMO_DRUMKIT_H__ +#pragma once #include <map> #include <string> @@ -35,36 +34,36 @@ #include "versionstr.h" class DrumKitParser; -class DrumKit { - friend class DrumKitParser; +class DrumKit +{ + friend class DrumKitParser; + public: - DrumKit(); - ~DrumKit(); + DrumKit(); + ~DrumKit(); + + std::string getFile() const; - std::string file(); + std::string getName() const; + std::string getDescription() const; - std::string name(); - std::string description(); - - Instruments instruments; - Channels channels; - - void clear(); + Instruments instruments; + Channels channels; - bool isValid(); + void clear(); - size_t samplerate(); + bool isValid() const; + + size_t getSamplerate() const; private: - void *magic{nullptr}; + void* magic{nullptr}; - std::string _file; + std::string _file; - std::string _name; - std::string _description; + std::string _name; + std::string _description; size_t _samplerate{0}; - VersionStr _version; + VersionStr _version; }; - -#endif/*__DRUMGIZMO_DRUMKIT_H__*/ |