]> git.tdb.fi Git - libs/core.git/blobdiff - source/io/asset.cpp
Add new exception classes for some common errors
[libs/core.git] / source / io / asset.cpp
index 9284f97107f9e19a2eacfb121ddcd43c0c09e3b3..d605ff49573cb2e329513ea2d722023945de302b 100644 (file)
@@ -1,3 +1,4 @@
+#include <msp/core/except.h>
 #include "asset.h"
 
 using namespace std;
@@ -7,12 +8,12 @@ namespace IO {
 
 void Asset::set_block(bool)
 {
-       throw logic_error("Asset::set_block");
+       throw unsupported("Asset::set_block");
 }
 
 void Asset::set_inherit(bool)
 {
-       throw logic_error("Asset::set_inherit");
+       throw unsupported("Asset::set_inherit");
 }
 
 size_t Asset::do_write(const char *, size_t)
@@ -22,7 +23,7 @@ size_t Asset::do_write(const char *, size_t)
 
 const Handle &Asset::get_handle(Mode)
 {
-       throw logic_error("Asset::get_handle");
+       throw unsupported("Asset::get_handle");
 }
 
 } // namespace IO