From 8cef4bbfd612f1cc619924d15ecd1c072fc160ba Mon Sep 17 00:00:00 2001 From: schmidt Date: Wed, 16 Jun 1999 19:23:42 +0000 Subject: . --- ChangeLog-99b | 8 ++++++++ README | 1 + ace/SOCK_Acceptor.h | 17 ++++++++++++----- ace/SOCK_Connector.h | 14 ++++++++++---- 4 files changed, 31 insertions(+), 9 deletions(-) diff --git a/ChangeLog-99b b/ChangeLog-99b index f4da7a0c77f..f2cbf9559ea 100644 --- a/ChangeLog-99b +++ b/ChangeLog-99b @@ -1,3 +1,11 @@ +Wed Jun 16 14:19:37 1999 Douglas C. Schmidt + + * ace/SOCK_{Acceptor,Connector}.h: Updated the documentation to + explain the "asymmetry" between the ACE_SOCK_Acceptor (which + inherits from ACE_SOCK) and the ACE_SOCK_Connector (which does + not). Thanks to Narayanan Vidya + for motivating this. + Wed Jun 16 13:15:22 1999 Steve Huston * ace/Containers_T.i: Fixed compile errors; ACE_Double_Linked_List_ diff --git a/README b/README index 6a418d130ac..a1242e0c86d 100644 --- a/README +++ b/README @@ -867,6 +867,7 @@ Rick Weisner Dennis C. De Mars V. Lakshmanan Hata Yoshiaki +Narayanan Vidya I would particularly like to thank Paul Stephenson, who worked with me at Ericsson and is now at ObjectSpace. Paul devised the recursive diff --git a/ace/SOCK_Acceptor.h b/ace/SOCK_Acceptor.h index e7c301de34a..18cd3005431 100644 --- a/ace/SOCK_Acceptor.h +++ b/ace/SOCK_Acceptor.h @@ -28,9 +28,16 @@ class ACE_Export ACE_SOCK_Acceptor : public ACE_SOCK { // = TITLE - // Defines a factory that creates new s passively. + // Defines a factory that creates new s passively. + // + // = DESCRIPTION + // The has its own "passive-mode" socket. + // This serves as a factory to create so-called "data-mode" + // sockets, which are what the encapsulates. + // Therefore, by inheriting from , + // gets its very own socket. public: - // = Initialization methods. + // = Initialization and termination methods. ACE_SOCK_Acceptor (void); // Default constructor. @@ -41,9 +48,6 @@ public: int protocol = 0); // Initiate a passive mode socket. - ~ACE_SOCK_Acceptor (void); - // Default dtor. - int open (const ACE_Addr &local_sap, int reuse_addr = 0, int protocol_family = PF_INET, @@ -51,6 +55,9 @@ public: int protocol = 0); // Initiate a passive mode socket. + ~ACE_SOCK_Acceptor (void); + // Default dtor. + // = Passive connection methods. int accept (ACE_SOCK_Stream &new_stream, ACE_Addr *remote_addr = 0, diff --git a/ace/SOCK_Connector.h b/ace/SOCK_Connector.h index e6abeb6a0e9..ac5a96e8911 100644 --- a/ace/SOCK_Connector.h +++ b/ace/SOCK_Connector.h @@ -28,13 +28,19 @@ class ACE_Export ACE_SOCK_Connector { // = TITLE - // Defines an active connection factory for the socket wrappers. + // Defines a factory that creates new s actively. // // = DESCRIPTION - // Objects of this class do not store state so they can be used - // reentrantly in multi-threaded programs... + // The doesn't have a socket of its own, + // i.e., it simply "borrows" the one from the ACE_SOCK_Stream + // that's being connected. The reason for this is that the + // underlying socket API doesn't use a "factory" socket to connect + // "data-mode" sockets. Therefore, there's no need to inherit + // from . A nice side-effect of + // this is that 's do not store state so they + // can be used reentrantly in multi-threaded programs. public: - // = Initialization routines. + // = Initialization and termination methods. ACE_SOCK_Connector (void); // Default constructor. -- cgit v1.2.1