From 90a6675a8eda8f77d504275b982c469b8e2ca2ce Mon Sep 17 00:00:00 2001 From: Alexander Sulfrian Date: Wed, 27 Jan 2010 03:39:23 +0100 Subject: renamed MissingSongTagException to MissingTagException and added tag parameter --- src/base/song.hpp | 17 ++++++++++++++--- 1 file changed, 14 insertions(+), 3 deletions(-) (limited to 'src/base/song.hpp') diff --git a/src/base/song.hpp b/src/base/song.hpp index 6009cfa9..d831a91e 100644 --- a/src/base/song.hpp +++ b/src/base/song.hpp @@ -37,11 +37,22 @@ namespace usdx { - class MissingSongTagException : public BaseException + class MissingTagException : public BaseException { + private: + /** + * TODO: Maybe refactor this to separate sub-classes. + */ + const std::string tag; + public: - MissingSongTagException(std::string message) : BaseException(message) {}; - ~MissingSongTagException () throw () {}; + MissingTagException(const std::string tag, + const std::string message) : + BaseException(message), tag(tag) {}; + + ~MissingTagException () throw () {}; + + virtual const std::string& get_tag() const { return tag; }; }; class Song -- cgit v1.2.3