summaryrefslogtreecommitdiff
path: root/cpp/include/IceUtil/ThreadException.h
diff options
context:
space:
mode:
Diffstat (limited to 'cpp/include/IceUtil/ThreadException.h')
-rw-r--r--cpp/include/IceUtil/ThreadException.h108
1 files changed, 108 insertions, 0 deletions
diff --git a/cpp/include/IceUtil/ThreadException.h b/cpp/include/IceUtil/ThreadException.h
new file mode 100644
index 00000000000..c64e20165db
--- /dev/null
+++ b/cpp/include/IceUtil/ThreadException.h
@@ -0,0 +1,108 @@
+// **********************************************************************
+//
+// Copyright (c) 2003-2011 ZeroC, Inc. All rights reserved.
+//
+// This copy of Ice is licensed to you under the terms described in the
+// ICE_LICENSE file included in this distribution.
+//
+// **********************************************************************
+
+#ifndef ICE_UTIL_THREAD_EXCEPTION_H
+#define ICE_UTIL_THREAD_EXCEPTION_H
+
+#include <IceUtil/Exception.h>
+#include <IceUtil/Time.h>
+
+namespace IceUtil
+{
+
+class ICE_UTIL_API ThreadSyscallException : public SyscallException
+{
+public:
+
+ ThreadSyscallException(const char*, int, int);
+ virtual std::string ice_name() const;
+ virtual Exception* ice_clone() const;
+ virtual void ice_throw() const;
+
+private:
+
+ static const char* _name;
+};
+
+class ICE_UTIL_API ThreadLockedException : public Exception
+{
+public:
+
+ ThreadLockedException(const char*, int);
+ virtual std::string ice_name() const;
+ virtual Exception* ice_clone() const;
+ virtual void ice_throw() const;
+
+private:
+
+ static const char* _name;
+};
+
+class ICE_UTIL_API ThreadStartedException : public Exception
+{
+public:
+
+ ThreadStartedException(const char*, int);
+ virtual std::string ice_name() const;
+ virtual Exception* ice_clone() const;
+ virtual void ice_throw() const;
+
+private:
+
+ static const char* _name;
+};
+
+class ICE_UTIL_API ThreadNotStartedException : public Exception
+{
+public:
+
+ ThreadNotStartedException(const char*, int);
+ virtual std::string ice_name() const;
+ virtual Exception* ice_clone() const;
+ virtual void ice_throw() const;
+
+private:
+
+ static const char* _name;
+};
+
+class ICE_UTIL_API BadThreadControlException : public Exception
+{
+public:
+
+ BadThreadControlException(const char*, int);
+ virtual std::string ice_name() const;
+ virtual Exception* ice_clone() const;
+ virtual void ice_throw() const;
+
+private:
+
+ static const char* _name;
+};
+
+class ICE_UTIL_API InvalidTimeoutException : public Exception
+{
+public:
+
+ InvalidTimeoutException(const char*, int, const Time&);
+ virtual std::string ice_name() const;
+ virtual void ice_print(std::ostream&) const;
+ virtual Exception* ice_clone() const;
+ virtual void ice_throw() const;
+
+private:
+
+ Time _timeout;
+ static const char* _name;
+};
+
+}
+
+#endif
+