diff options
author | William R. Otte <wotte@dre.vanderbilt.edu> | 2006-07-24 15:50:30 +0000 |
---|---|---|
committer | William R. Otte <wotte@dre.vanderbilt.edu> | 2006-07-24 15:50:30 +0000 |
commit | c44379cc7d9c7aa113989237ab0f56db12aa5219 (patch) | |
tree | 66a84b20d47f2269d8bdc6e0323f338763424d3a /ACE/apps/Gateway/Gateway/Connection_Handler_Acceptor.h | |
parent | 3aff90f4a822fcf5d902bbfbcc9fa931d6191a8c (diff) | |
download | ATCD-c44379cc7d9c7aa113989237ab0f56db12aa5219.tar.gz |
Repo restructuring
Diffstat (limited to 'ACE/apps/Gateway/Gateway/Connection_Handler_Acceptor.h')
-rw-r--r-- | ACE/apps/Gateway/Gateway/Connection_Handler_Acceptor.h | 65 |
1 files changed, 65 insertions, 0 deletions
diff --git a/ACE/apps/Gateway/Gateway/Connection_Handler_Acceptor.h b/ACE/apps/Gateway/Gateway/Connection_Handler_Acceptor.h new file mode 100644 index 00000000000..777f58c4a5b --- /dev/null +++ b/ACE/apps/Gateway/Gateway/Connection_Handler_Acceptor.h @@ -0,0 +1,65 @@ +/* -*- C++ -*- */ +// $Id$ + +// ============================================================================ +// +// = LIBRARY +// gateway +// +// = FILENAME +// Connection_Handler_acceptor.h +// +// = AUTHOR +// Doug Schmidt +// +// ============================================================================ + +#ifndef _CONNECTION_HANDLER_ACCEPTOR +#define _CONNECTION_HANDLER_ACCEPTOR + +#include "ace/Acceptor.h" + +#if !defined (ACE_LACKS_PRAGMA_ONCE) +# pragma once +#endif /* ACE_LACKS_PRAGMA_ONCE */ + +#include "ace/SOCK_Acceptor.h" +#include "Connection_Handler.h" + +// Forward declaration +class Event_Channel; + +class Connection_Handler_Acceptor : public ACE_Acceptor<Connection_Handler, ACE_SOCK_ACCEPTOR> +{ + // = TITLE + // A concrete factory class that setups connections to peerds + // and produces a new Connection_Handler object to do the dirty + // work... +public: + Connection_Handler_Acceptor (Event_Channel &, + char connection_role); + // Constructor. + + virtual int make_svc_handler (Connection_Handler *&ch); + // Hook method for creating an appropriate <Connection_Handler>. + + virtual int accept_svc_handler (Connection_Handler *ch); + // Hook method for accepting a connection into the + // <Connection_Handler>. + +protected: + typedef ACE_Acceptor<Connection_Handler, ACE_SOCK_ACCEPTOR> + inherited; + // Make life easier later on. + + Event_Channel &event_channel_; + // Reference to the event channel. + + Connection_Config_Info connection_config_info_; + // Keeps track of what type of proxy we need to create. + + Connection_Handler_Factory connection_handler_factory_; + // Make the appropriate type of <Connection_Handler>. +}; + +#endif /* _CONNECTION_HANDLER_ACCEPTOR */ |