[7297] Fixed profession spells sorting in trainer spell list at client.
[getmangos.git] / dep / ACE_wrappers / ace / UPIPE_Acceptor.h
blob0fd33226ed3f5401235c4acb12007201399230ff
1 // -*- C++ -*-
3 //=============================================================================
4 /**
5 * @file UPIPE_Acceptor.h
7 * $Id: UPIPE_Acceptor.h 80826 2008-03-04 14:51:23Z wotte $
9 * @author Gerhard Lenzer
10 * @author Douglas C. Schmidt
12 //=============================================================================
15 #ifndef ACE_UPIPE_ACCEPTOR_H
16 #define ACE_UPIPE_ACCEPTOR_H
17 #include /**/ "ace/pre.h"
19 #include "ace/UPIPE_Stream.h"
21 #if !defined (ACE_LACKS_PRAGMA_ONCE)
22 # pragma once
23 #endif /* ACE_LACKS_PRAGMA_ONCE */
25 #if defined (ACE_HAS_THREADS)
27 #include "ace/SPIPE_Acceptor.h"
28 #include "ace/Thread_Manager.h"
30 ACE_BEGIN_VERSIONED_NAMESPACE_DECL
32 /**
33 * @class ACE_UPIPE_Acceptor
35 * @brief Defines the format and interface for the listener side of the
36 * ACE_UPIPE_Stream.
38 class ACE_Export ACE_UPIPE_Acceptor : public ACE_SPIPE_Acceptor
40 public:
41 // = Initialization and termination.
42 /// Default constructor.
43 ACE_UPIPE_Acceptor (void);
45 /// Initialize passive endpoint.
46 ACE_UPIPE_Acceptor (const ACE_UPIPE_Addr &local_sap,
47 int reuse_addr = 0);
49 /// Initialize passive endpoint.
50 int open (const ACE_UPIPE_Addr &local_sap,
51 int reuse_addr = 0);
53 /// Close down and release resources.
54 ~ACE_UPIPE_Acceptor (void);
56 /// Close down and release resources.
57 int close (void);
59 /// Close down and release resources and remove the underlying SPIPE
60 /// rendezvous point.
61 int remove (void);
63 // = Passive connection acceptance method.
64 /**
65 * Accept a new data transfer connection. A @a timeout of 0 means
66 * block forever, a @a timeout of {0, 0} means poll. @a restart == 1
67 * means "restart if interrupted."
69 int accept (ACE_UPIPE_Stream &server_stream,
70 ACE_UPIPE_Addr *remote_addr = 0,
71 ACE_Time_Value *timeout = 0,
72 int restart = 1,
73 int reset_new_handle = 0);
75 /// Dump the state of an object.
76 void dump (void) const;
78 /// Declare the dynamic allocation hooks.
79 ACE_ALLOC_HOOK_DECLARE;
81 private:
82 /// Manage threads.
83 ACE_Thread_Manager tm;
85 /// To confirm connection establishment.
86 ACE_Message_Block mb_;
89 ACE_END_VERSIONED_NAMESPACE_DECL
91 #if defined (__ACE_INLINE__)
92 #include "ace/UPIPE_Acceptor.inl"
93 #endif /* __ACE_INLINE__ */
95 #endif /* ACE_HAS_THREADS */
97 #include /**/ "ace/post.h"
99 #endif /* ACE_UPIPE_ACCEPTOR_H */