aboutsummaryrefslogtreecommitdiffstats
path: root/src/exception.hpp
diff options
context:
space:
mode:
authorVincent Richard <[email protected]>2004-11-14 14:31:23 +0000
committerVincent Richard <[email protected]>2004-11-14 14:31:23 +0000
commitde09abb036a54b4214f0092a57e057481adb9530 (patch)
treea055ed14d4bed03553a27fb18b7a79c4c73f55c6 /src/exception.hpp
parentAdded support for generating documentation (Doxygen) + written AUTHORS file. (diff)
downloadvmime-de09abb036a54b4214f0092a57e057481adb9530.tar.gz
vmime-de09abb036a54b4214f0092a57e057481adb9530.zip
Prevent from renaming 'INBOX' folder in IMAP (illegal_operation exception).
Diffstat (limited to 'src/exception.hpp')
-rw-r--r--src/exception.hpp16
1 files changed, 16 insertions, 0 deletions
diff --git a/src/exception.hpp b/src/exception.hpp
index 815fd1d4..41e113ac 100644
--- a/src/exception.hpp
+++ b/src/exception.hpp
@@ -415,6 +415,22 @@ public:
};
+/** Illegal operation: cannot run this operation on the object.
+ */
+
+class illegal_operation : public messaging_exception
+{
+public:
+
+ illegal_operation(const string& msg = "")
+ : messaging_exception(msg.empty()
+ ? "Illegal operation."
+ : "Illegal operation: " + msg + "."
+ ) {}
+ ~illegal_operation() throw() {}
+};
+
+
/** Command error: operation failed (this is specific to the underlying protocol).
*/