3 //==========================================================================
7 * @author Douglas C. Schmidt <d.schmidt@vanderbilt.edu>
9 //==========================================================================
11 #ifndef ACE_MANUAL_EVENT_H
12 #define ACE_MANUAL_EVENT_H
13 #include /**/ "ace/pre.h"
15 #include /**/ "ace/ACE_export.h"
17 #if !defined (ACE_LACKS_PRAGMA_ONCE)
19 #endif /* ACE_LACKS_PRAGMA_ONCE */
21 #include "ace/Event.h"
23 ACE_BEGIN_VERSIONED_NAMESPACE_DECL
26 * @class ACE_Manual_Event
28 * @brief Manual Events.
30 * Specialization of Event mechanism which wakes up all waiting
31 * thread on <signal>. All platforms support process-scope locking
32 * support. However, only Win32 platforms support global naming and
33 * system-scope locking support.
35 template <class TIME_POLICY
= ACE_System_Time_Policy
>
36 class ACE_Manual_Event_T
: public ACE_Event_T
<TIME_POLICY
>
39 /// Constructor which will create manual event
40 ACE_Manual_Event_T (int initial_state
= 0,
41 int type
= USYNC_THREAD
,
45 #if defined (ACE_HAS_WCHAR)
46 /// Constructor which will create manual event (wchar_t version)
47 ACE_Manual_Event_T (int initial_state
,
51 #endif /* ACE_HAS_WCHAR */
54 ~ACE_Manual_Event_T () = default;
56 /// Dump the state of an object.
59 /// Declare the dynamic allocation hooks
60 ACE_ALLOC_HOOK_DECLARE
;
63 class ACE_Manual_Event
:
64 public ACE_Manual_Event_T
<ACE_System_Time_Policy
>
67 /// Constructor which will create auto event
68 ACE_Manual_Event (int initial_state
= 0,
69 int type
= USYNC_THREAD
,
72 : ACE_Manual_Event_T
<ACE_System_Time_Policy
> (initial_state
, type
, name
, arg
)
75 #if defined (ACE_HAS_WCHAR)
76 /// Constructor which will create auto event (wchar_t version)
77 ACE_Manual_Event (int initial_state
,
81 : ACE_Manual_Event_T
<ACE_System_Time_Policy
> (initial_state
, type
, name
, arg
)
83 #endif /* ACE_HAS_WCHAR */
86 ~ACE_Manual_Event () override
= default;
89 ACE_END_VERSIONED_NAMESPACE_DECL
91 #include "ace/Manual_Event.cpp"
93 #include /**/ "ace/post.h"
94 #endif /* ACE_MANUAL_EVENT_H */