summaryrefslogtreecommitdiff
path: root/examples/C++NPv2/Logging_Event_Handler_Ex.cpp
diff options
context:
space:
mode:
authornobody <nobody@ae88bc3d-4319-0410-8dbf-d08b4c9d3795>2005-06-18 18:53:27 +0000
committernobody <nobody@ae88bc3d-4319-0410-8dbf-d08b4c9d3795>2005-06-18 18:53:27 +0000
commit152c0f5c127eac99b5c9097aa4db2b34e14e6dd0 (patch)
tree0d399a92623e98588cd34e4fe0c2cf7fed880173 /examples/C++NPv2/Logging_Event_Handler_Ex.cpp
parent7e7f4a5d3e77a42e648b7dd2e1b9cf23a3780955 (diff)
downloadATCD-MyACE.tar.gz
This commit was manufactured by cvs2svn to create branch 'MyACE'.MyACE
Diffstat (limited to 'examples/C++NPv2/Logging_Event_Handler_Ex.cpp')
-rw-r--r--examples/C++NPv2/Logging_Event_Handler_Ex.cpp41
1 files changed, 0 insertions, 41 deletions
diff --git a/examples/C++NPv2/Logging_Event_Handler_Ex.cpp b/examples/C++NPv2/Logging_Event_Handler_Ex.cpp
deleted file mode 100644
index 858e615e9d9..00000000000
--- a/examples/C++NPv2/Logging_Event_Handler_Ex.cpp
+++ /dev/null
@@ -1,41 +0,0 @@
-/*
-** $Id$
-**
-** Copyright 2002 Addison Wesley. All Rights Reserved.
-*/
-
-#include "Logging_Event_Handler_Ex.h"
-#include "ace/Timer_Queue.h"
-
-int Logging_Event_Handler_Ex::handle_input (ACE_HANDLE h) {
- time_of_last_log_record_ =
- reactor ()->timer_queue ()->gettimeofday ();
- return PARENT::handle_input (h);
-}
-
-int Logging_Event_Handler_Ex::open () {
- int result = PARENT::open ();
- if (result != -1) {
- ACE_Time_Value reschedule (max_client_timeout_.sec () / 4);
- result =
- reactor ()->schedule_timer
- (this,
- 0,
- max_client_timeout_, // Initial timeout.
- reschedule); // Subsequent timeouts.
- }
- return result;
-}
-
-int Logging_Event_Handler_Ex::handle_timeout
- (const ACE_Time_Value &now, const void *) {
- if (now - time_of_last_log_record_ >= max_client_timeout_)
- reactor ()->remove_handler (this, ACE_Event_Handler::READ_MASK);
- return 0;
-}
-
-int Logging_Event_Handler_Ex::handle_close (ACE_HANDLE,
- ACE_Reactor_Mask) {
- reactor ()->cancel_timer (this);
- return PARENT::handle_close ();
-}