summaryrefslogtreecommitdiff
path: root/docs/tutorials/015/Handler.h
diff options
context:
space:
mode:
authornobody <nobody@ae88bc3d-4319-0410-8dbf-d08b4c9d3795>1999-09-13 00:26:05 +0000
committernobody <nobody@ae88bc3d-4319-0410-8dbf-d08b4c9d3795>1999-09-13 00:26:05 +0000
commit7a042e4f8a987a50143415af690a878881d4b48f (patch)
tree338a92488326f0585d65743bd3d6ec0650fd6db1 /docs/tutorials/015/Handler.h
parent9b50028195a935518c2716dcdb94d5bb167a0af2 (diff)
downloadATCD-TAO-1_0_4.tar.gz
This commit was manufactured by cvs2svn to create tag 'TAO-1_0_4'.TAO-1_0_4
Diffstat (limited to 'docs/tutorials/015/Handler.h')
-rw-r--r--docs/tutorials/015/Handler.h61
1 files changed, 0 insertions, 61 deletions
diff --git a/docs/tutorials/015/Handler.h b/docs/tutorials/015/Handler.h
deleted file mode 100644
index 1a0f1a69e46..00000000000
--- a/docs/tutorials/015/Handler.h
+++ /dev/null
@@ -1,61 +0,0 @@
-// $Id$
-
-#ifndef HANDLER_H
-#define HANDLER_H
-
-#include "ace/Svc_Handler.h"
-
-#if !defined (ACE_LACKS_PRAGMA_ONCE)
-# pragma once
-#endif /* ACE_LACKS_PRAGMA_ONCE */
-
-#include "ace/SOCK_Stream.h"
-#include "Protocol_Stream.h"
-
-/* Just your basic event handler. We use ACE_Svc_Handler<> as a
- baseclass so that it can maintain the peer() and other details for
- us. We're not going to activate() this object, so we can get away
- with the NULL synch choice. */
-class Handler : public ACE_Svc_Handler <ACE_SOCK_STREAM, ACE_NULL_SYNCH>
-{
-public:
- Handler (void);
- ~Handler (void);
-
- // Called by the acceptor when we're created in response to a client
- // connection.
- int open (void *);
-
- // Called when it's time for us to be deleted. We take care of
- // removing ourselves from the reactor and shutting down the peer()
- // connectin.
- void destroy (void);
-
- // Called when it's time for us to go away. There are subtle
- // differences between destroy() and close() so don't try to use
- // either for all cases.
- int close (u_long);
-
-protected:
- // Respond to peer() activity.
- int handle_input (ACE_HANDLE);
-
- // This will be called when handle_input() returns a failure code.
- // That's our signal that it's time to begin the shutdown process.
- int handle_close (ACE_HANDLE,
- ACE_Reactor_Mask mask);
-private:
-
- // Like the Client, we have to abide by the protocol requirements.
- // We use a local Protocol_Stream object to take care of those
- // details. For us, I/O then just becomes a matter of interacting
- // with the stream.
- Protocol_Stream stream_;
-
- Protocol_Stream &stream (void)
- {
- return this->stream_;
- }
-};
-
-#endif /* HANDLER_H */