summaryrefslogtreecommitdiff
path: root/cpp/include/Ice/Application.h
diff options
context:
space:
mode:
Diffstat (limited to 'cpp/include/Ice/Application.h')
-rw-r--r--cpp/include/Ice/Application.h10
1 files changed, 10 insertions, 0 deletions
diff --git a/cpp/include/Ice/Application.h b/cpp/include/Ice/Application.h
index e983e050fe3..90ddaf7f413 100644
--- a/cpp/include/Ice/Application.h
+++ b/cpp/include/Ice/Application.h
@@ -83,10 +83,20 @@ public:
static void holdInterrupt();
static void releaseInterrupt();
+ //
+ // This method returns true if a signal handler was triggered,
+ // false otherwise. This can be used once Communicator::waitForShutdown()
+ // returns to test whether the shutdown was due to an interrupt (interrupted()
+ // returns true in that case) or because Communicator::shutdown() was called
+ // (interupted() returns false in that case).
+ //
+ static bool interrupted();
+
private:
static const char* _appName;
static CommunicatorPtr _communicator;
+ static bool _interrupted;
#ifdef _WIN32
friend BOOL WINAPI interruptHandler(DWORD);