diff options
author | Ossama Othman <ossama-othman@users.noreply.github.com> | 2005-10-28 23:55:10 +0000 |
---|---|---|
committer | Ossama Othman <ossama-othman@users.noreply.github.com> | 2005-10-28 23:55:10 +0000 |
commit | e32a736ff14f2758a139bdb782db5ce9bab41a44 (patch) | |
tree | 72b3ef7a314c64d03b5b4aced6c03ae96dd6a362 | |
parent | 0db151e9845b5f6b7c775e1465db708d86fde66d (diff) | |
download | ATCD-e32a736ff14f2758a139bdb782db5ce9bab41a44.tar.gz |
ChangeLogTag:Fri Oct 28 00:01:06 2005 Ossama Othman <ossama@dre.vanderbilt.edu>
130 files changed, 1076 insertions, 474 deletions
diff --git a/ChangeLog b/ChangeLog index de3c7ef71e4..ef066463579 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,4 +1,4 @@ -Fri Oct 28 16:07:45 2005 <ossama@dre.vanderbilt.edu> +Fri Oct 28 16:07:45 2005 Ossama Othman <ossama@dre.vanderbilt.edu> * ace/SSL/SSL_Context.cpp (ACE_SSL_locking_callback): (ACE_SSL_thread_id): @@ -915,7 +915,135 @@ Fri Oct 28 00:01:06 2005 Ossama Othman <ossama@dre.vanderbilt.edu> * ace/TSS_T.inl: * ace/TTY_IO.cpp: * ace/TTY_IO.h: + * ace/Task.cpp: + * ace/Task.h: + * ace/Task.inl: + * ace/Task_Ex_T.cpp: + * ace/Task_Ex_T.h: + * ace/Task_Ex_T.inl: + * ace/Task_T.cpp: + * ace/Task_T.h: + * ace/Task_T.inl: + * ace/Template_Instantiations.cpp: + * ace/Test_and_Set.cpp: + * ace/Test_and_Set.h: + * ace/Thread.cpp: + * ace/Thread.h: + * ace/Thread.inl: + * ace/Thread_Adapter.cpp: * ace/Thread_Adapter.h: + * ace/Thread_Adapter.inl: + * ace/Thread_Control.cpp: + * ace/Thread_Control.h: + * ace/Thread_Control.inl: + * ace/Thread_Exit.cpp: + * ace/Thread_Exit.h: + * ace/Thread_Hook.cpp: + * ace/Thread_Hook.h: + * ace/Thread_Manager.cpp: + * ace/Thread_Manager.h: + * ace/Thread_Manager.inl: + * ace/Thread_Mutex.cpp: + * ace/Thread_Mutex.h: + * ace/Thread_Mutex.inl: + * ace/Thread_Semaphore.cpp: + * ace/Thread_Semaphore.h: + * ace/Thread_Semaphore.inl: + * ace/Time_Request_Reply.cpp: + * ace/Time_Request_Reply.h: + * ace/Time_Value.cpp: + * ace/Time_Value.h: + * ace/Time_Value.inl: + * ace/Timeprobe.cpp: + * ace/Timeprobe.h: + * ace/Timeprobe.inl: + * ace/Timeprobe_T.cpp: + * ace/Timeprobe_T.h: + * ace/Timer_Hash.cpp: + * ace/Timer_Hash.h: + * ace/Timer_Heap.cpp: + * ace/Timer_Heap.h: + * ace/Timer_Heap_T.cpp: + * ace/Timer_Heap_T.h: + * ace/Timer_List.cpp: + * ace/Timer_List.h: + * ace/Timer_Queue.cpp: + * ace/Timer_Queue.h: + * ace/Timer_Queue_Adapters.cpp: + * ace/Timer_Queue_Adapters.h: + * ace/Timer_Queue_Adapters.inl: + * ace/Timer_Queue_T.cpp: + * ace/Timer_Queue_T.h: + * ace/Timer_Queue_T.inl: + * ace/Timer_Queuefwd.h: + * ace/Timer_Wheel.cpp: + * ace/Timer_Wheel.h: + * ace/Timer_Wheel_T.cpp: + * ace/Timer_Wheel_T.h: + * ace/TkReactor.cpp: + * ace/TkReactor.h: + * ace/Token.cpp: + * ace/Token.h: + * ace/Token.inl: + * ace/Token_Collection.cpp: + * ace/Token_Collection.h: + * ace/Token_Collection.inl: + * ace/Token_Invariants.cpp: + * ace/Token_Invariants.h: + * ace/Token_Manager.cpp: + * ace/Token_Manager.h: + * ace/Token_Manager.inl: + * ace/Token_Request_Reply.cpp: + * ace/Token_Request_Reply.h: + * ace/Token_Request_Reply.inl: + * ace/Trace.cpp: + * ace/Trace.h: + * ace/Typed_SV_Message.cpp: + * ace/Typed_SV_Message.h: + * ace/Typed_SV_Message.inl: + * ace/Typed_SV_Message_Queue.cpp: + * ace/Typed_SV_Message_Queue.h: + * ace/Typed_SV_Message_Queue.inl: + * ace/UNIX_Addr.cpp: + * ace/UNIX_Addr.h: + * ace/UNIX_Addr.inl: + * ace/UPIPE_Acceptor.cpp: + * ace/UPIPE_Acceptor.h: + * ace/UPIPE_Acceptor.inl: + * ace/UPIPE_Addr.h: + * ace/UPIPE_Connector.cpp: + * ace/UPIPE_Connector.h: + * ace/UPIPE_Connector.inl: + * ace/UPIPE_Stream.cpp: + * ace/UPIPE_Stream.h: + * ace/UPIPE_Stream.inl: + * ace/UUID.cpp: + * ace/UUID.h: + * ace/UUID.inl: + * ace/Unbounded_Queue.cpp: + * ace/Unbounded_Queue.h: + * ace/Unbounded_Queue.inl: + * ace/Unbounded_Set.cpp: + * ace/Unbounded_Set.h: + * ace/Unbounded_Set.inl: + * ace/Value_Ptr.h: + * ace/Vector_T.cpp: + * ace/Vector_T.h: + * ace/Vector_T.inl: + * ace/WFMO_Reactor.cpp: + * ace/WFMO_Reactor.h: + * ace/WFMO_Reactor.inl: + * ace/WIN32_Asynch_IO.cpp: + * ace/WIN32_Asynch_IO.h: + * ace/WIN32_Proactor.cpp: + * ace/WIN32_Proactor.h: + * ace/XML_Svc_Conf.cpp: + * ace/XML_Svc_Conf.h: + * ace/XTI_ATM_Mcast.cpp: + * ace/XTI_ATM_Mcast.h: + * ace/XTI_ATM_Mcast.inl: + * ace/XtReactor.cpp: + * ace/XtReactor.h: * ace/ace.mpc: * ace/ace_wchar.h: * ace/ace_wchar.inl: diff --git a/ace/Task.cpp b/ace/Task.cpp index 293bbb187f0..f92df9a2005 100644 --- a/ace/Task.cpp +++ b/ace/Task.cpp @@ -13,6 +13,8 @@ ACE_RCSID (ace, "$Id$") +ACE_BEGIN_VERSIONED_NAMESPACE_DECL + ACE_Task_Base::ACE_Task_Base (ACE_Thread_Manager *thr_man) : thr_count_ (0), thr_mgr_ (thr_man), @@ -272,3 +274,5 @@ ACE_Task_Base::svc_run (void *args) #endif return status; } + +ACE_END_VERSIONED_NAMESPACE_DECL diff --git a/ace/Task.h b/ace/Task.h index 9460673d06e..94bed7d1c0c 100644 --- a/ace/Task.h +++ b/ace/Task.h @@ -1,4 +1,4 @@ -/* -*- C++ -*- */ +// -*- C++ -*- //============================================================================= /** @@ -22,6 +22,8 @@ #include "ace/Thread_Manager.h" +ACE_BEGIN_VERSIONED_NAMESPACE_DECL + /** * @class ACE_Task_Flags * @@ -32,9 +34,8 @@ * code defined here, so we don't have to worry about multiple * definitions. */ -class ACE_Export ACE_Task_Flags +namespace ACE_Task_Flags { -public: enum { /// Identifies a Task as being the "reader" in a Module. @@ -277,6 +278,8 @@ private: ACE_Task_Base (const ACE_Task_Base &); }; +ACE_END_VERSIONED_NAMESPACE_DECL + #if defined (__ACE_INLINE__) #include "ace/Task.inl" #endif /* __ACE_INLINE__ */ diff --git a/ace/Task.inl b/ace/Task.inl index c903afffbc2..7099c994e4b 100644 --- a/ace/Task.inl +++ b/ace/Task.inl @@ -2,6 +2,7 @@ // // $Id$ +ACE_BEGIN_VERSIONED_NAMESPACE_DECL ACE_INLINE ACE_Thread_Manager * ACE_Task_Base::thr_mgr (void) const @@ -76,3 +77,4 @@ ACE_Task_Base::grp_id (int identifier) this->thr_mgr ()->set_grp (this, identifier); } +ACE_END_VERSIONED_NAMESPACE_DECL diff --git a/ace/Task_Ex_T.cpp b/ace/Task_Ex_T.cpp index a265355c22e..0c5871657dd 100644 --- a/ace/Task_Ex_T.cpp +++ b/ace/Task_Ex_T.cpp @@ -1,8 +1,7 @@ -// Task_Ex_T.cpp // $Id$ -#ifndef ACE_TASK_EX_T_C -#define ACE_TASK_EX_T_C +#ifndef ACE_TASK_EX_T_CPP +#define ACE_TASK_EX_T_CPP #include "ace/Task_Ex_T.h" @@ -17,7 +16,8 @@ #include "ace/Task_Ex_T.inl" #endif /* __ACE_INLINE__ */ -ACE_RCSID(ace, Task_Ex_T, "$Id$") + +ACE_BEGIN_VERSIONED_NAMESPACE_DECL template <ACE_SYNCH_DECL, class ACE_MESSAGE_TYPE> void ACE_Task_Ex<ACE_SYNCH_USE, ACE_MESSAGE_TYPE>::dump (void) const @@ -109,4 +109,6 @@ ACE_Task_Ex<ACE_SYNCH_USE, ACE_MESSAGE_TYPE>::module (void) const return this->mod_; } -#endif /* ACE_TASK_EX_T_C */ +ACE_END_VERSIONED_NAMESPACE_DECL + +#endif /* ACE_TASK_EX_T_CPP */ diff --git a/ace/Task_Ex_T.h b/ace/Task_Ex_T.h index 9777a90ff03..79102e4be8f 100644 --- a/ace/Task_Ex_T.h +++ b/ace/Task_Ex_T.h @@ -1,4 +1,4 @@ -/* -*- C++ -*- */ +// -*- C++ -*- //============================================================================= /** @@ -23,6 +23,8 @@ #include "ace/Synch_Traits.h" #include "ace/Task.h" +ACE_BEGIN_VERSIONED_NAMESPACE_DECL + // Forward decls... template <ACE_SYNCH_DECL> class ACE_Module; @@ -182,6 +184,8 @@ private: ACE_UNIMPLEMENTED_FUNC (ACE_Task_Ex (const ACE_Task_Ex<ACE_SYNCH_USE, ACE_MESSAGE_TYPE> &)) }; +ACE_END_VERSIONED_NAMESPACE_DECL + #if defined (__ACE_INLINE__) #include "ace/Task_Ex_T.inl" #endif /* __ACE_INLINE__ */ diff --git a/ace/Task_Ex_T.inl b/ace/Task_Ex_T.inl index fb68b7f874e..b49f4bf53f1 100644 --- a/ace/Task_Ex_T.inl +++ b/ace/Task_Ex_T.inl @@ -1,13 +1,14 @@ -/* -*- C++ -*- */ +// -*- C++ -*- +// // $Id$ -// Task_Ex_T.i - #include "ace/os_include/os_assert.h" +ACE_BEGIN_VERSIONED_NAMESPACE_DECL + template <ACE_SYNCH_DECL, class ACE_MESSAGE_TYPE> ACE_INLINE void -ACE_Task_Ex<ACE_SYNCH_USE,ACE_MESSAGE_TYPE>::water_marks (ACE_IO_Cntl_Msg::ACE_IO_Cntl_Cmds cmd, - size_t wm_size) +ACE_Task_Ex<ACE_SYNCH_USE,ACE_MESSAGE_TYPE>::water_marks (ACE_IO_Cntl_Msg::ACE_IO_Cntl_Cmds cmd, + size_t wm_size) { ACE_TRACE ("ACE_Task_Ex<ACE_SYNCH_USE,ACE_MESSAGE_TYPE>::water_marks"); if (cmd == ACE_IO_Cntl_Msg::SET_LWM) @@ -16,14 +17,14 @@ ACE_Task_Ex<ACE_SYNCH_USE,ACE_MESSAGE_TYPE>::water_marks (ACE_IO_Cntl_Msg::ACE_I this->msg_queue_->high_water_mark (wm_size); } -template <ACE_SYNCH_DECL, class ACE_MESSAGE_TYPE> ACE_INLINE int +template <ACE_SYNCH_DECL, class ACE_MESSAGE_TYPE> ACE_INLINE int ACE_Task_Ex<ACE_SYNCH_USE,ACE_MESSAGE_TYPE>::getq (ACE_MESSAGE_TYPE *&mb, ACE_Time_Value *tv) { ACE_TRACE ("ACE_Task_Ex<ACE_SYNCH_USE,ACE_MESSAGE_TYPE>::getq"); return this->msg_queue_->dequeue_head (mb, tv); } -template <ACE_SYNCH_DECL, class ACE_MESSAGE_TYPE> ACE_INLINE int +template <ACE_SYNCH_DECL, class ACE_MESSAGE_TYPE> ACE_INLINE int ACE_Task_Ex<ACE_SYNCH_USE,ACE_MESSAGE_TYPE>::can_put (ACE_MESSAGE_TYPE *) { ACE_TRACE ("ACE_Task_Ex<ACE_SYNCH_USE,ACE_MESSAGE_TYPE>::can_put"); @@ -100,10 +101,12 @@ ACE_Task_Ex<ACE_SYNCH_USE,ACE_MESSAGE_TYPE>::next (ACE_Task<ACE_SYNCH_USE> *q) // Transfer msg to the next ACE_Task_Ex. template <ACE_SYNCH_DECL, class ACE_MESSAGE_TYPE> ACE_INLINE int -ACE_Task_Ex<ACE_SYNCH_USE,ACE_MESSAGE_TYPE>::put_next (ACE_MESSAGE_TYPE *msg, ACE_Time_Value *tv) +ACE_Task_Ex<ACE_SYNCH_USE,ACE_MESSAGE_TYPE>::put_next ( + ACE_MESSAGE_TYPE * /* msg */, + ACE_Time_Value * /* tv */) { ACE_TRACE ("ACE_Task_Ex<ACE_SYNCH_USE,ACE_MESSAGE_TYPE>::put_next"); - ACE_UNUSED_ARG (msg); - ACE_UNUSED_ARG (tv); return -1; // this->next_ == 0 ? -1 : this->next_->put (msg, tv); } + +ACE_END_VERSIONED_NAMESPACE_DECL diff --git a/ace/Task_T.cpp b/ace/Task_T.cpp index e35297792cb..f0c97e74193 100644 --- a/ace/Task_T.cpp +++ b/ace/Task_T.cpp @@ -1,8 +1,7 @@ -// Task.cpp // $Id$ -#ifndef ACE_TASK_T_C -#define ACE_TASK_T_C +#ifndef ACE_TASK_T_CPP +#define ACE_TASK_T_CPP #include "ace/Task_T.h" @@ -17,7 +16,7 @@ #include "ace/Task_T.inl" #endif /* __ACE_INLINE__ */ -ACE_RCSID(ace, Task_T, "$Id$") +ACE_BEGIN_VERSIONED_NAMESPACE_DECL template <ACE_SYNCH_DECL> void ACE_Task<ACE_SYNCH_USE>::dump (void) const @@ -104,4 +103,6 @@ ACE_Task<ACE_SYNCH_USE>::module (void) const return this->mod_; } -#endif /* ACE_TASK_T_C */ +ACE_END_VERSIONED_NAMESPACE_DECL + +#endif /* ACE_TASK_T_CPP */ diff --git a/ace/Task_T.h b/ace/Task_T.h index 52c0f6b2218..3ccccff87a4 100644 --- a/ace/Task_T.h +++ b/ace/Task_T.h @@ -1,4 +1,4 @@ -/* -*- C++ -*- */ +// -*- C++ -*- //============================================================================= /** @@ -23,6 +23,8 @@ #include "ace/Synch_Traits.h" #include "ace/Task.h" +ACE_BEGIN_VERSIONED_NAMESPACE_DECL + // Forward decls... template <ACE_SYNCH_DECL> class ACE_Module; @@ -167,6 +169,8 @@ template class ACE_Export ACE_Task<ACE_MT_SYNCH>; template class ACE_Export ACE_Task<ACE_NULL_SYNCH>; #endif /* ACE_HAS_EXPLICIT_TEMPLATE_INSTANTIATION_EXPORT */ +ACE_END_VERSIONED_NAMESPACE_DECL + #if defined (__ACE_INLINE__) #include "ace/Task_T.inl" #endif /* __ACE_INLINE__ */ diff --git a/ace/Task_T.inl b/ace/Task_T.inl index e4694062fc4..77d7c0d789e 100644 --- a/ace/Task_T.inl +++ b/ace/Task_T.inl @@ -1,13 +1,14 @@ -/* -*- C++ -*- */ +// -*- C++ -*- +// // $Id$ -// Task_T.i - #include "ace/os_include/os_assert.h" +ACE_BEGIN_VERSIONED_NAMESPACE_DECL + template <ACE_SYNCH_DECL> ACE_INLINE void -ACE_Task<ACE_SYNCH_USE>::water_marks (ACE_IO_Cntl_Msg::ACE_IO_Cntl_Cmds cmd, - size_t wm_size) +ACE_Task<ACE_SYNCH_USE>::water_marks (ACE_IO_Cntl_Msg::ACE_IO_Cntl_Cmds cmd, + size_t wm_size) { ACE_TRACE ("ACE_Task<ACE_SYNCH_USE>::water_marks"); if (cmd == ACE_IO_Cntl_Msg::SET_LWM) @@ -16,14 +17,14 @@ ACE_Task<ACE_SYNCH_USE>::water_marks (ACE_IO_Cntl_Msg::ACE_IO_Cntl_Cmds cmd, this->msg_queue_->high_water_mark (wm_size); } -template <ACE_SYNCH_DECL> ACE_INLINE int +template <ACE_SYNCH_DECL> ACE_INLINE int ACE_Task<ACE_SYNCH_USE>::getq (ACE_Message_Block *&mb, ACE_Time_Value *tv) { ACE_TRACE ("ACE_Task<ACE_SYNCH_USE>::getq"); return this->msg_queue_->dequeue_head (mb, tv); } -template <ACE_SYNCH_DECL> ACE_INLINE int +template <ACE_SYNCH_DECL> ACE_INLINE int ACE_Task<ACE_SYNCH_USE>::can_put (ACE_Message_Block *) { ACE_TRACE ("ACE_Task<ACE_SYNCH_USE>::can_put"); @@ -103,3 +104,5 @@ ACE_Task<ACE_SYNCH_USE>::put_next (ACE_Message_Block *msg, ACE_Time_Value *tv) ACE_TRACE ("ACE_Task<ACE_SYNCH_USE>::put_next"); return this->next_ == 0 ? -1 : this->next_->put (msg, tv); } + +ACE_END_VERSIONED_NAMESPACE_DECL diff --git a/ace/Template_Instantiations.cpp b/ace/Template_Instantiations.cpp index 9542848b4f5..3df1a0062ec 100644 --- a/ace/Template_Instantiations.cpp +++ b/ace/Template_Instantiations.cpp @@ -35,6 +35,8 @@ #error ACE_HAS_EXPLICIT_TEMPLATE_INSTANTIATION_FILE may not be used with ACE_HAS_EXPLICIT_TEMPLATE_INSTANTIATION or ACE_HAS_TEMPLATE_INSTANTIATION_PRAGMA #endif /* defined (ACE_HAS_EXPLICIT_TEMPLATE_INSTANTIATION) || defined (ACE_HAS_TEMPLATE_INSTANTIATION_PRAGMA) */ +ACE_BEGIN_VERSIONED_NAMESPACE_DECL + // D E P T H = 0 // Templates with nesting depth 0 (no dependencies on // other templates), ordered by number of template arguments @@ -350,6 +352,8 @@ template class ACE_Timer_Queue_T<ACE_Event_Handler*, ACE_Timer_Hash_Upcall<ACE_E template class ACE_Timer_Queue_Iterator_T<ACE_Event_Handler*, ACE_Timer_Hash_Upcall<ACE_Event_Handler*, ACE_Event_Handler_Handle_Timeout_Upcall<ACE_Null_Mutex>, ACE_Null_Mutex>, ACE_Null_Mutex>; +ACE_END_VERSIONED_NAMESPACE_DECL + #elif defined (__HP_aCC) // Make aC++ stop complaining about an empty translation unit static int shut_up_aCC = 0; diff --git a/ace/Test_and_Set.cpp b/ace/Test_and_Set.cpp index 5a9cbdb0bfe..ea420bbe508 100644 --- a/ace/Test_and_Set.cpp +++ b/ace/Test_and_Set.cpp @@ -1,7 +1,7 @@ // $Id$ -#ifndef ACE_TEST_AND_SET_C -#define ACE_TEST_AND_SET_C +#ifndef ACE_TEST_AND_SET_CPP +#define ACE_TEST_AND_SET_CPP #include "ace/Test_and_Set.h" #include "ace/Guard_T.h" @@ -10,7 +10,7 @@ # pragma once #endif /* ACE_LACKS_PRAGMA_ONCE */ -ACE_RCSID(ace, Test_and_Set, "$Id$") +ACE_BEGIN_VERSIONED_NAMESPACE_DECL template <class ACE_LOCK, class TYPE> ACE_Test_and_Set<ACE_LOCK, TYPE>::ACE_Test_and_Set (TYPE initial_value) @@ -46,4 +46,6 @@ ACE_Test_and_Set<ACE_LOCK, TYPE>::handle_signal (int, siginfo_t *, ucontext_t *) return 0; } -#endif /* ACE_TEST_AND_SET_C */ +ACE_END_VERSIONED_NAMESPACE_DECL + +#endif /* ACE_TEST_AND_SET_CPP */ diff --git a/ace/Test_and_Set.h b/ace/Test_and_Set.h index 37e810f1b4e..10917e8578f 100644 --- a/ace/Test_and_Set.h +++ b/ace/Test_and_Set.h @@ -1,11 +1,10 @@ +// -*- C++ -*- //============================================================================= /** * @file Test_and_Set.h * * $Id$ - * - * @author Priyanka Gontla <pgontla@ece.uci.edu> */ //============================================================================= @@ -20,6 +19,8 @@ # pragma once #endif /* ACE_LACKS_PRAGMA_ONCE */ +ACE_BEGIN_VERSIONED_NAMESPACE_DECL + /** * @class ACE_Test_and_Set * @@ -60,6 +61,8 @@ private: ACE_LOCK lock_; }; +ACE_END_VERSIONED_NAMESPACE_DECL + #if defined (ACE_TEMPLATES_REQUIRE_SOURCE) #include "ace/Test_and_Set.cpp" #endif /* ACE_TEMPLATES_REQUIRE_SOURCE */ diff --git a/ace/Thread.cpp b/ace/Thread.cpp index 80ce71f3d7e..d59cbd8c73c 100644 --- a/ace/Thread.cpp +++ b/ace/Thread.cpp @@ -1,18 +1,20 @@ -// Thread.cpp // $Id$ #include "ace/Thread.h" -#if !defined (__ACE_INLINE__) -#include "ace/Thread.inl" -#endif /* !defined (__ACE_INLINE__) */ - ACE_RCSID(ace, Thread, "$Id$") #if defined (ACE_HAS_THREADS) +#if !defined (__ACE_INLINE__) +#include "ace/Thread.inl" +#endif /* !defined (__ACE_INLINE__) */ + + +ACE_BEGIN_VERSIONED_NAMESPACE_DECL + size_t ACE_Thread::spawn_n (size_t n, ACE_THR_FUNC func, @@ -89,4 +91,6 @@ ACE_Thread::spawn_n (ACE_thread_t thread_ids[], return i; } +ACE_END_VERSIONED_NAMESPACE_DECL + #endif /* ACE_HAS_THREADS */ diff --git a/ace/Thread.h b/ace/Thread.h index 05a81548d97..ba1b9d64a57 100644 --- a/ace/Thread.h +++ b/ace/Thread.h @@ -24,6 +24,8 @@ #include "ace/OS_NS_Thread.h" #include "ace/Thread_Adapter.h" +ACE_BEGIN_VERSIONED_NAMESPACE_DECL + struct cancel_state { /// e.g., PTHREAD_CANCEL_ENABLE, PTHREAD_CANCEL_DISABLE, @@ -265,6 +267,8 @@ private: ACE_Thread (void); }; +ACE_END_VERSIONED_NAMESPACE_DECL + #if defined (__ACE_INLINE__) #include "ace/Thread.inl" #endif /* __ACE_INLINE__ */ diff --git a/ace/Thread.inl b/ace/Thread.inl index 0091d8eec3a..ba635c6b2f0 100644 --- a/ace/Thread.inl +++ b/ace/Thread.inl @@ -1,10 +1,11 @@ -/* -*- C++ -*- */ +// -*- C++ -*- +// // $Id$ -// Thread.inl - #include "ace/OS_NS_string.h" +ACE_BEGIN_VERSIONED_NAMESPACE_DECL + // Allocates a <keyp> that is used to identify data that is specific // to each thread in the process. The key is global to all threads in // the process. @@ -279,3 +280,5 @@ ACE_Thread::setprio (ACE_hthread_t ht_id, int priority, int policy) ACE_TRACE ("ACE_Thread::setprio"); return ACE_OS::thr_setprio (ht_id, priority, policy); } + +ACE_END_VERSIONED_NAMESPACE_DECL diff --git a/ace/Thread_Adapter.cpp b/ace/Thread_Adapter.cpp index 8b1abafa302..d969e3e9d0d 100644 --- a/ace/Thread_Adapter.cpp +++ b/ace/Thread_Adapter.cpp @@ -14,6 +14,8 @@ ACE_RCSID (ace, # include "ace/Thread_Adapter.inl" #endif /* ACE_HAS_INLINED_OS_CALLS */ +ACE_BEGIN_VERSIONED_NAMESPACE_DECL + ACE_Thread_Adapter::ACE_Thread_Adapter (ACE_THR_FUNC user_func, void *arg, ACE_THR_C_FUNC entry_point, @@ -245,3 +247,5 @@ ACE_Thread_Adapter::invoke_i (void) return status; } + +ACE_END_VERSIONED_NAMESPACE_DECL diff --git a/ace/Thread_Adapter.h b/ace/Thread_Adapter.h index ecc0d713f4c..046d21b238f 100644 --- a/ace/Thread_Adapter.h +++ b/ace/Thread_Adapter.h @@ -22,6 +22,8 @@ #include "ace/Base_Thread_Adapter.h" +ACE_BEGIN_VERSIONED_NAMESPACE_DECL + // Forward decl. class ACE_Thread_Manager; class ACE_Thread_Descriptor; @@ -84,6 +86,8 @@ private: }; +ACE_END_VERSIONED_NAMESPACE_DECL + # if defined (ACE_HAS_INLINED_OSCALLS) # if defined (ACE_INLINE) # undef ACE_INLINE diff --git a/ace/Thread_Adapter.inl b/ace/Thread_Adapter.inl index 433023aad93..4f1fa0fce49 100644 --- a/ace/Thread_Adapter.inl +++ b/ace/Thread_Adapter.inl @@ -1,8 +1,13 @@ -/* -*- C++ -*- */ +// -*- C++ -*- +// // $Id$ +ACE_BEGIN_VERSIONED_NAMESPACE_DECL + ACE_INLINE ACE_Thread_Manager * ACE_Thread_Adapter::thr_mgr (void) { return this->thr_mgr_; } + +ACE_END_VERSIONED_NAMESPACE_DECL diff --git a/ace/Thread_Control.cpp b/ace/Thread_Control.cpp index 5415e74b687..5198fad391d 100644 --- a/ace/Thread_Control.cpp +++ b/ace/Thread_Control.cpp @@ -18,6 +18,8 @@ ACE_RCSID(ace, Thread_Control, "$Id$") # include "ace/Thread_Control.inl" #endif /* ACE_HAS_INLINED_OS_CALLS */ +ACE_BEGIN_VERSIONED_NAMESPACE_DECL + void ACE_Thread_Control::dump (void) const { @@ -90,3 +92,5 @@ ACE_Thread_Control::exit (ACE_THR_FUNC_RETURN exit_status, int do_thr_exit) return 0; } } + +ACE_END_VERSIONED_NAMESPACE_DECL diff --git a/ace/Thread_Control.h b/ace/Thread_Control.h index fa2bc559c8d..6989d77daad 100644 --- a/ace/Thread_Control.h +++ b/ace/Thread_Control.h @@ -1,3 +1,4 @@ +// -*- C++ -*- //============================================================================= /** @@ -20,6 +21,8 @@ # pragma once #endif /* ACE_LACKS_PRAGMA_ONCE */ +ACE_BEGIN_VERSIONED_NAMESPACE_DECL + class ACE_Thread_Manager; /** @@ -85,6 +88,8 @@ private: ACE_THR_FUNC_RETURN status_; }; +ACE_END_VERSIONED_NAMESPACE_DECL + # if defined (ACE_HAS_INLINED_OSCALLS) # if defined (ACE_INLINE) # undef ACE_INLINE diff --git a/ace/Thread_Control.inl b/ace/Thread_Control.inl index 0c2ab504112..7b96cb369f8 100644 --- a/ace/Thread_Control.inl +++ b/ace/Thread_Control.inl @@ -1,6 +1,9 @@ // -*- C++ -*- +// // $Id$ +ACE_BEGIN_VERSIONED_NAMESPACE_DECL + // Set the exit status. ACE_INLINE ACE_THR_FUNC_RETURN @@ -40,3 +43,4 @@ ACE_Thread_Control::thr_mgr (ACE_Thread_Manager *tm) return o_tm; } +ACE_END_VERSIONED_NAMESPACE_DECL diff --git a/ace/Thread_Exit.cpp b/ace/Thread_Exit.cpp index 160c1e0429c..4a9a7d0c8c3 100644 --- a/ace/Thread_Exit.cpp +++ b/ace/Thread_Exit.cpp @@ -7,6 +7,8 @@ ACE_RCSID(ace, Thread_Exit, "$Id$") +ACE_BEGIN_VERSIONED_NAMESPACE_DECL + u_int ACE_Thread_Exit::is_constructed_ = 0; void @@ -129,3 +131,5 @@ ACE_Thread_Exit_Maybe::instance (void) const #endif /* ACE_HAS_EXPLICIT_TEMPLATE_INSTANTIATION */ #endif /* ACE_HAS_THREADS && (ACE_HAS_THREAD_SPECIFIC_STORAGE || ACE_HAS_TSS_EMULATION) */ + +ACE_END_VERSIONED_NAMESPACE_DECL diff --git a/ace/Thread_Exit.h b/ace/Thread_Exit.h index e183512e5a5..fc828c5aa03 100644 --- a/ace/Thread_Exit.h +++ b/ace/Thread_Exit.h @@ -1,3 +1,4 @@ +// -*- C++ -*- //============================================================================= /** @@ -22,6 +23,8 @@ #include "ace/Thread_Control.h" +ACE_BEGIN_VERSIONED_NAMESPACE_DECL + /** * @class ACE_Thread_Exit * @@ -102,5 +105,7 @@ private: }; +ACE_END_VERSIONED_NAMESPACE_DECL + #include /**/ "ace/post.h" #endif /* ACE_THREAD_EXIT_H */ diff --git a/ace/Thread_Hook.cpp b/ace/Thread_Hook.cpp index e866a3626e5..e69eb0a482c 100644 --- a/ace/Thread_Hook.cpp +++ b/ace/Thread_Hook.cpp @@ -5,6 +5,8 @@ ACE_RCSID(ace, Thread_Hook, "$Id$") +ACE_BEGIN_VERSIONED_NAMESPACE_DECL + ACE_Thread_Hook::~ACE_Thread_Hook () { } @@ -27,3 +29,5 @@ ACE_Thread_Hook::thread_hook (void) { return ACE_OS_Object_Manager::thread_hook (); } + +ACE_END_VERSIONED_NAMESPACE_DECL diff --git a/ace/Thread_Hook.h b/ace/Thread_Hook.h index c8aa941d669..a6748d25061 100644 --- a/ace/Thread_Hook.h +++ b/ace/Thread_Hook.h @@ -23,6 +23,8 @@ #include "ace/ACE_export.h" +ACE_BEGIN_VERSIONED_NAMESPACE_DECL + /** * @class ACE_Thread_Hook * @@ -57,5 +59,7 @@ public: static ACE_Thread_Hook *thread_hook (void); }; +ACE_END_VERSIONED_NAMESPACE_DECL + #include /**/ "ace/post.h" #endif /* ACE_THREAD_HOOK_H */ diff --git a/ace/Thread_Manager.cpp b/ace/Thread_Manager.cpp index ffd9950c38a..57f8cf2973b 100644 --- a/ace/Thread_Manager.cpp +++ b/ace/Thread_Manager.cpp @@ -18,6 +18,8 @@ ACE_RCSID (ace, "$Id$") +ACE_BEGIN_VERSIONED_NAMESPACE_DECL + #if !defined(ACE_USE_ONE_SHOT_AT_THREAD_EXIT) ACE_At_Thread_Exit::~ACE_At_Thread_Exit (void) @@ -2373,3 +2375,5 @@ template class ACE_Locked_Free_List<ACE_Thread_Descriptor, ACE_DEFAULT_THREAD_MA # pragma instantiate ACE_Free_List<ACE_Thread_Descriptor> # pragma instantiate ACE_Locked_Free_List<ACE_Thread_Descriptor, ACE_DEFAULT_THREAD_MANAGER_LOCK> #endif /* ACE_HAS_EXPLICIT_TEMPLATE_INSTANTIATION */ + +ACE_END_VERSIONED_NAMESPACE_DECL diff --git a/ace/Thread_Manager.h b/ace/Thread_Manager.h index 0b55ce84978..1e08642c58b 100644 --- a/ace/Thread_Manager.h +++ b/ace/Thread_Manager.h @@ -1,4 +1,4 @@ -/* -*- C++ -*- */ +// -*- C++ -*- //============================================================================= /** @@ -74,6 +74,8 @@ # define ACE_DEFAULT_THREAD_MANAGER_LOCK ACE_SYNCH_MUTEX #endif /* ACE_DEFAULT_THREAD_MANAGER_LOCK */ +ACE_BEGIN_VERSIONED_NAMESPACE_DECL + // Forward declarations. class ACE_Task_Base; class ACE_Thread_Manager; @@ -1135,6 +1137,8 @@ private: typedef ACE_Singleton<ACE_Thread_Manager, ACE_SYNCH_MUTEX> ACE_THREAD_MANAGER_SINGLETON; #endif /* defined (ACE_THREAD_MANAGER_LACKS_STATICS) */ +ACE_END_VERSIONED_NAMESPACE_DECL + #if defined (__ACE_INLINE__) #include "ace/Thread_Manager.inl" #endif /* __ACE_INLINE__ */ diff --git a/ace/Thread_Manager.inl b/ace/Thread_Manager.inl index cac2d176761..471c98e1b62 100644 --- a/ace/Thread_Manager.inl +++ b/ace/Thread_Manager.inl @@ -2,6 +2,7 @@ // // $Id$ +ACE_BEGIN_VERSIONED_NAMESPACE_DECL #if !defined(ACE_USE_ONE_SHOT_AT_THREAD_EXIT) ACE_INLINE @@ -315,3 +316,5 @@ ACE_Thread_Manager::count_threads (void) const { return this->thr_list_.size (); } + +ACE_END_VERSIONED_NAMESPACE_DECL diff --git a/ace/Thread_Mutex.cpp b/ace/Thread_Mutex.cpp index 8a0af97ce10..061cce2684e 100644 --- a/ace/Thread_Mutex.cpp +++ b/ace/Thread_Mutex.cpp @@ -1,4 +1,3 @@ -/* -*- C++ -*- */ /** * @file Thread_Mutex.cpp * @@ -23,6 +22,8 @@ ACE_RCSID(ace, Thread_Mutex, "$Id$") +ACE_BEGIN_VERSIONED_NAMESPACE_DECL + ACE_ALLOC_HOOK_DEFINE(ACE_Thread_Mutex_Guard) #if defined (ACE_USES_OBSOLETE_GUARD_CLASSES) @@ -86,4 +87,6 @@ template class ACE_Malloc_Lock_Adapter_T<ACE_Thread_Mutex>; #pragma instantiate ACE_Malloc_Lock_Adapter_T<ACE_Thread_Mutex> #endif /* ACE_HAS_EXPLICIT_TEMPLATE_INSTANTIATION */ +ACE_END_VERSIONED_NAMESPACE_DECL + #endif /* ACE_HAS_THREADS */ diff --git a/ace/Thread_Mutex.h b/ace/Thread_Mutex.h index 2c7f32bf7f5..f75640f4e30 100644 --- a/ace/Thread_Mutex.h +++ b/ace/Thread_Mutex.h @@ -30,21 +30,23 @@ #include "ace/ACE_export.h" #include "ace/OS_NS_Thread.h" - /** - * @class ACE_Thread_Mutex - * - * @brief ACE_Thread_Mutex wrapper (only valid for threads in the same - * process). - * - * This implementation is optimized for locking threads that are - * in the same process. It maps to <CRITICAL_SECTION>s on NT - * and <ACE_mutex_t> with <type> set to <USYNC_THREAD> on UNIX. - * ACE_Thread_Mutex is recursive on some platforms (like - * Win32). However, on most platforms (like Solaris) it is not - * recursive. To be totally safe and portable, developers - * should use <ACE_Recursive_Thread_Mutex> when they need a - * recursive mutex. - */ +ACE_BEGIN_VERSIONED_NAMESPACE_DECL + +/** + * @class ACE_Thread_Mutex + * + * @brief ACE_Thread_Mutex wrapper (only valid for threads in the same + * process). + * + * This implementation is optimized for locking threads that are + * in the same process. It maps to <CRITICAL_SECTION>s on NT + * and <ACE_mutex_t> with <type> set to <USYNC_THREAD> on UNIX. + * ACE_Thread_Mutex is recursive on some platforms (like + * Win32). However, on most platforms (like Solaris) it is not + * recursive. To be totally safe and portable, developers + * should use <ACE_Recursive_Thread_Mutex> when they need a + * recursive mutex. + */ class ACE_Export ACE_Thread_Mutex { friend class ACE_Condition_Thread_Mutex; @@ -225,6 +227,8 @@ private: }; #endif /* ACE_USES_OBSOLETE_GUARD_CLASSES */ +ACE_END_VERSIONED_NAMESPACE_DECL + #if defined (__ACE_INLINE__) #include "ace/Thread_Mutex.inl" #endif /* __ACE_INLINE__ */ diff --git a/ace/Thread_Mutex.inl b/ace/Thread_Mutex.inl index f1031aafa48..7658522b38f 100644 --- a/ace/Thread_Mutex.inl +++ b/ace/Thread_Mutex.inl @@ -1,6 +1,9 @@ -/* -*- C++ -*- */ +// -*- C++ -*- +// // $Id$ +ACE_BEGIN_VERSIONED_NAMESPACE_DECL + ACE_INLINE const ACE_thread_mutex_t & ACE_Thread_Mutex::lock (void) const { @@ -165,3 +168,5 @@ ACE_Thread_Mutex_Guard::remove (void) return this->release (); } #endif /* ACE_USES_OBSOLETE_GUARD_CLASSES */ + +ACE_END_VERSIONED_NAMESPACE_DECL diff --git a/ace/Thread_Semaphore.cpp b/ace/Thread_Semaphore.cpp index 8c56a7e1c31..741c7c5ec99 100644 --- a/ace/Thread_Semaphore.cpp +++ b/ace/Thread_Semaphore.cpp @@ -1,4 +1,3 @@ -/* -*- C++ -*- */ /** * @file Thread_Semaphore.cpp * @@ -22,6 +21,8 @@ ACE_RCSID(ace, Thread_Semaphore, "$Id$") +ACE_BEGIN_VERSIONED_NAMESPACE_DECL + void ACE_Thread_Semaphore::dump (void) const { @@ -56,4 +57,6 @@ ACE_Malloc_Lock_Adapter_T<ACE_Thread_Semaphore>::operator () (const ACE_TCHAR *n return p; } +ACE_END_VERSIONED_NAMESPACE_DECL + #endif /* ACE_HAS_THREADS */ diff --git a/ace/Thread_Semaphore.h b/ace/Thread_Semaphore.h index c99a60d3575..204bfd0a85b 100644 --- a/ace/Thread_Semaphore.h +++ b/ace/Thread_Semaphore.h @@ -34,6 +34,8 @@ #include "ace/Semaphore.h" +ACE_BEGIN_VERSIONED_NAMESPACE_DECL + /** * @class ACE_Thread_Semaphore * @@ -80,6 +82,8 @@ public: ACE_Thread_Semaphore * operator () (const ACE_TCHAR *name); }; +ACE_END_VERSIONED_NAMESPACE_DECL + #if defined (__ACE_INLINE__) #include "ace/Thread_Semaphore.inl" #endif /* __ACE_INLINE__ */ diff --git a/ace/Thread_Semaphore.inl b/ace/Thread_Semaphore.inl index 8d2a9adf785..e9535ff088e 100644 --- a/ace/Thread_Semaphore.inl +++ b/ace/Thread_Semaphore.inl @@ -1,7 +1,12 @@ -/* -*- C++ -*- */ +// -*- C++ -*- +// // $Id$ +ACE_BEGIN_VERSIONED_NAMESPACE_DECL + ACE_INLINE ACE_Thread_Semaphore::~ACE_Thread_Semaphore (void) { } + +ACE_END_VERSIONED_NAMESPACE_DECL diff --git a/ace/Time_Request_Reply.cpp b/ace/Time_Request_Reply.cpp index bf1586d7260..e7524ce6ce7 100644 --- a/ace/Time_Request_Reply.cpp +++ b/ace/Time_Request_Reply.cpp @@ -7,6 +7,8 @@ ACE_RCSID(ace, Time_Request_Reply, "$Id$") +ACE_BEGIN_VERSIONED_NAMESPACE_DECL + // Default "do nothing" constructor. ACE_Time_Request::ACE_Time_Request (void) @@ -190,3 +192,5 @@ ACE_Time_Request::dump (void) const ACE_DEBUG ((LM_DEBUG, ACE_LIB_TEXT ("+++++++\n"))); #endif /* ACE_HAS_DUMP */ } + +ACE_END_VERSIONED_NAMESPACE_DECL diff --git a/ace/Time_Request_Reply.h b/ace/Time_Request_Reply.h index 551da8dfb82..8c062cbd9a5 100644 --- a/ace/Time_Request_Reply.h +++ b/ace/Time_Request_Reply.h @@ -1,4 +1,5 @@ -/* -*- C++ -*- */ +// -*- C++ -*- + //============================================================================= /** * @file Time_Request_Reply.h @@ -23,6 +24,8 @@ # pragma once #endif /* ACE_LACKS_PRAGMA_ONCE */ +ACE_BEGIN_VERSIONED_NAMESPACE_DECL + /** * @class ACE_Time_Request * @@ -130,6 +133,7 @@ private: ACE_UINT32 time_; }; +ACE_END_VERSIONED_NAMESPACE_DECL #include /**/ "ace/post.h" #endif /* ACE_TIME_REQUEST_REPLY_H */ diff --git a/ace/Time_Value.cpp b/ace/Time_Value.cpp index 2f8a9e67bff..5b7d6021d84 100644 --- a/ace/Time_Value.cpp +++ b/ace/Time_Value.cpp @@ -10,6 +10,8 @@ ACE_RCSID (ace, #endif /* __ACE_INLINE__ */ +ACE_BEGIN_VERSIONED_NAMESPACE_DECL + // Static constant representing `zero-time'. // Note: this object requires static construction. const ACE_Time_Value ACE_Time_Value::zero; @@ -241,3 +243,5 @@ ACE_Time_Value::operator *= (double d) return *this; } + +ACE_END_VERSIONED_NAMESPACE_DECL diff --git a/ace/Time_Value.h b/ace/Time_Value.h index 86ed911bfa0..ee852be7588 100644 --- a/ace/Time_Value.h +++ b/ace/Time_Value.h @@ -31,11 +31,6 @@ #define ACE_ONE_SECOND_IN_USECS 1000000L #define ACE_ONE_SECOND_IN_NSECS 1000000000L -// This forward declaration is needed by the set() and FILETIME() functions -#if defined (ACE_LACKS_LONGLONG_T) -class ACE_Export ACE_U_LongLong; -#endif /* ACE_LACKS_LONGLONG_T */ - # if !defined (ACE_HAS_POSIX_TIME) && !defined (ACE_PSOS) // Definition per POSIX. typedef struct timespec @@ -57,6 +52,13 @@ typedef struct timespec timespec_t; // needed for ACE_UINT64 #include "ace/Basic_Types.h" +ACE_BEGIN_VERSIONED_NAMESPACE_DECL + +// This forward declaration is needed by the set() and FILETIME() functions +#if defined (ACE_LACKS_LONGLONG_T) +class ACE_Export ACE_U_LongLong; +#endif /* ACE_LACKS_LONGLONG_T */ + // ------------------------------------------------------------------- /** @@ -266,11 +268,11 @@ public: /// Adds two ACE_Time_Value objects together, returns the sum. friend ACE_Export ACE_Time_Value operator + (const ACE_Time_Value &tv1, - const ACE_Time_Value &tv2); + const ACE_Time_Value &tv2); /// Subtracts two ACE_Time_Value objects, returns the difference. friend ACE_Export ACE_Time_Value operator - (const ACE_Time_Value &tv1, - const ACE_Time_Value &tv2); + const ACE_Time_Value &tv2); /// True if @a tv1 < @a tv2. friend ACE_Export bool operator < (const ACE_Time_Value &tv1, @@ -299,7 +301,7 @@ public: //@{ /// Multiplies the time value by @a d friend ACE_Export ACE_Time_Value operator * (double d, - const ACE_Time_Value &tv); + const ACE_Time_Value &tv); friend ACE_Export ACE_Time_Value operator * (const ACE_Time_Value &tv, double d); @@ -347,6 +349,8 @@ static const ACE_Time_Value& __zero_time = ACE_Time_Value::zero; static const ACE_Time_Value& __max_time = ACE_Time_Value::max_time; #endif /* __MINGW32__ */ +ACE_END_VERSIONED_NAMESPACE_DECL + #include /**/ "ace/post.h" #endif /* ACE_TIME_VALUE_H */ diff --git a/ace/Time_Value.inl b/ace/Time_Value.inl index 298485d319c..0ab4a35caae 100644 --- a/ace/Time_Value.inl +++ b/ace/Time_Value.inl @@ -2,6 +2,8 @@ // // $Id$ +ACE_BEGIN_VERSIONED_NAMESPACE_DECL + #if defined (ACE_WIN32) && defined (_WIN32_WCE) // Something is a bit brain-damaged here and I'm not sure what... this code // compiled before the OS reorg for ACE 5.4. Since then it hasn't - eVC @@ -357,3 +359,5 @@ operator - (const ACE_Time_Value &tv1, #if defined (ACE_WIN32) && defined (_WIN32_WCE) } #endif + +ACE_END_VERSIONED_NAMESPACE_DECL diff --git a/ace/Timeprobe.cpp b/ace/Timeprobe.cpp index 9fa83321885..7f5db1fbb94 100644 --- a/ace/Timeprobe.cpp +++ b/ace/Timeprobe.cpp @@ -14,6 +14,8 @@ ACE_RCSID(ace, Timeprobe, "$Id$") #include "ace/Timeprobe.inl" #endif /* __ACE_INLINE__ */ +ACE_BEGIN_VERSIONED_NAMESPACE_DECL + #if defined (ACE_HAS_EXPLICIT_TEMPLATE_INSTANTIATION) template class ACE_Timeprobe_Ex<ACE_TIMEPROBE_MUTEX,ACE_TIMEPROBE_ALLOCATOR>; template class ACE_Function_Timeprobe<ACE_Timeprobe_Ex<ACE_TIMEPROBE_MUTEX,ACE_TIMEPROBE_ALLOCATOR> >; @@ -44,5 +46,7 @@ template class ACE_Singleton<ACE_TIMEPROBE_WITH_LOCKING, ACE_SYNCH_MUTEX>; #endif /* ACE_HAS_EXPLICIT_TEMPLATE_INSTANTIATION */ # endif /* ACE_TSS_TIMEPROBES */ +ACE_END_VERSIONED_NAMESPACE_DECL + #endif /* ACE_COMPILE_TIMEPROBES */ diff --git a/ace/Timeprobe.h b/ace/Timeprobe.h index 6eca046a631..c2319014db8 100644 --- a/ace/Timeprobe.h +++ b/ace/Timeprobe.h @@ -58,6 +58,8 @@ #include "ace/OS_NS_time.h" #include "ace/OS_NS_Thread.h" +ACE_BEGIN_VERSIONED_NAMESPACE_DECL + /** * @class ACE_Event_Descriptions * @@ -154,6 +156,8 @@ ACE_SINGLETON_DECLARE (ACE_TIMEPROBE_SINGLETON_TYPE, \ typedef ACE_TIMEPROBE_SINGLETON_TYPE<ACE_TIMEPROBE_WITH_LOCKING, ACE_TIMEPROBE_SINGLETON_LOCK_TYPE> ACE_TIMEPROBE_SINGLETON; +ACE_END_VERSIONED_NAMESPACE_DECL + #endif /* ACE_COMPILE_TIMEPROBES */ // If ACE_ENABLE_TIMEPROBES is defined, the macros below will diff --git a/ace/Timeprobe.inl b/ace/Timeprobe.inl index 2815dd56e0c..d25eb4b0cfa 100644 --- a/ace/Timeprobe.inl +++ b/ace/Timeprobe.inl @@ -1,9 +1,14 @@ // -*- C++ -*- +// // $Id$ +ACE_BEGIN_VERSIONED_NAMESPACE_DECL + ACE_INLINE bool ACE_Event_Descriptions::operator== (const ACE_Event_Descriptions &rhs) const { return this->minimum_id_ == rhs.minimum_id_ && this->descriptions_ == rhs.descriptions_; } + +ACE_END_VERSIONED_NAMESPACE_DECL diff --git a/ace/Timeprobe_T.cpp b/ace/Timeprobe_T.cpp index bde2c1736dc..c9d971602ff 100644 --- a/ace/Timeprobe_T.cpp +++ b/ace/Timeprobe_T.cpp @@ -1,7 +1,7 @@ // $Id$ -#ifndef ACE_TIMEPROBE_T_C -#define ACE_TIMEPROBE_T_C +#ifndef ACE_TIMEPROBE_T_CPP +#define ACE_TIMEPROBE_T_CPP #include "ace/config-all.h" @@ -9,14 +9,14 @@ # pragma once #endif /* ACE_LACKS_PRAGMA_ONCE */ -ACE_RCSID(ace, Timeprobe_T, "$Id$") - #if defined (ACE_COMPILE_TIMEPROBES) #include "ace/Timeprobe.h" #include "ace/High_Res_Timer.h" #include "ace/OS_NS_string.h" +ACE_BEGIN_VERSIONED_NAMESPACE_DECL + template <class ACE_LOCK, class ALLOCATOR> ACE_Timeprobe_Ex<ACE_LOCK, ALLOCATOR>::ACE_Timeprobe_Ex (u_long size) : timeprobes_ (0), @@ -394,5 +394,7 @@ ACE_Function_Timeprobe<Timeprobe>::~ACE_Function_Timeprobe (void) this->timeprobe_.timeprobe (this->event_ + 1); } +ACE_END_VERSIONED_NAMESPACE_DECL + #endif /* ACE_COMPILE_TIMEPROBES */ -#endif /* ACE_TIMEPROBE_T_C */ +#endif /* ACE_TIMEPROBE_T_CPP */ diff --git a/ace/Timeprobe_T.h b/ace/Timeprobe_T.h index e4d0acc7c33..32b5bae1448 100644 --- a/ace/Timeprobe_T.h +++ b/ace/Timeprobe_T.h @@ -1,4 +1,4 @@ -/* -*- C++ -*- */ +// -*- C++ -*- //============================================================================= /** @@ -25,6 +25,8 @@ #include "ace/Unbounded_Set.h" +ACE_BEGIN_VERSIONED_NAMESPACE_DECL + /** * @class ACE_Timeprobe_Ex * @@ -205,6 +207,8 @@ protected: u_long event_; }; +ACE_END_VERSIONED_NAMESPACE_DECL + #if defined (ACE_TEMPLATES_REQUIRE_SOURCE) #include "ace/Timeprobe_T.cpp" #endif /* ACE_TEMPLATES_REQUIRE_SOURCE */ diff --git a/ace/Timer_Hash.cpp b/ace/Timer_Hash.cpp index cfd39ae18e7..876476f702c 100644 --- a/ace/Timer_Hash.cpp +++ b/ace/Timer_Hash.cpp @@ -1,10 +1,5 @@ // $Id$ -// Timer_Hash.cpp - -#if !defined (ACE_TIMER_HASH_C) -#define ACE_TIMER_HASH_C - #include "ace/Timer_Hash.h" #include "ace/Synch_Traits.h" #include "ace/Recursive_Thread_Mutex.h" @@ -15,6 +10,8 @@ ACE_RCSID(ace, Timer_Hash, "$Id$") +ACE_BEGIN_VERSIONED_NAMESPACE_DECL + #if defined (ACE_HAS_EXPLICIT_TEMPLATE_INSTANTIATION) template class ACE_Free_List<ACE_Timer_Node_T<ACE_Event_Handler *> >; template class ACE_Locked_Free_List<ACE_Timer_Node_T<ACE_Event_Handler *>, @@ -121,5 +118,4 @@ template class ACE_Timer_Hash_Iterator_T<ACE_Event_Handler *, #endif /* ACE_HAS_EXPLICIT_TEMPLATE_INSTANTIATION */ - -#endif /* ACE_TIMER_HASH_C */ +ACE_END_VERSIONED_NAMESPACE_DECL diff --git a/ace/Timer_Hash.h b/ace/Timer_Hash.h index a457ba41207..2d959be39c5 100644 --- a/ace/Timer_Hash.h +++ b/ace/Timer_Hash.h @@ -24,6 +24,8 @@ #include "ace/Timer_Heap_T.h" #include "ace/Timer_List_T.h" +ACE_BEGIN_VERSIONED_NAMESPACE_DECL + // The following typedef are here for ease of use typedef ACE_Timer_Hash_Upcall <ACE_Event_Handler *, @@ -67,5 +69,7 @@ typedef ACE_Timer_Hash_Iterator_T<ACE_Event_Handler *, ACE_Hash_Timer_Heap> ACE_Timer_Hash_Heap_Iterator; +ACE_END_VERSIONED_NAMESPACE_DECL + #include /**/ "ace/post.h" #endif /* ACE_TIMER_HASH_H */ diff --git a/ace/Timer_Heap.cpp b/ace/Timer_Heap.cpp index de160f575eb..1e8f3e5a4cf 100644 --- a/ace/Timer_Heap.cpp +++ b/ace/Timer_Heap.cpp @@ -1,17 +1,19 @@ // $Id$ -#if !defined (ACE_TIMER_HEAP_C) -#define ACE_TIMER_HEAP_C - #include "ace/Timer_Heap.h" #include "ace/Synch_Traits.h" #include "ace/Recursive_Thread_Mutex.h" -ACE_RCSID(ace, Timer_Heap, "$Id$") - #if defined (ACE_HAS_BROKEN_HPUX_TEMPLATES) #include "ace/Timer_Hash.h" #include "ace/Timer_Heap_T.cpp" + +ACE_RCSID(ace, + Timer_Heap, + "$Id$") + +ACE_BEGIN_VERSIONED_NAMESPACE_DECL + #if defined (ACE_HAS_EXPLICIT_TEMPLATE_INSTANTIATION) template class ACE_Timer_Heap_T< @@ -31,8 +33,13 @@ template class ACE_Null_Mutex>, ACE_Null_Mutex>; #endif /* ACE_HAS_EXPLICIT_TEMPLATE_INSTANTIATION */ + +ACE_END_VERSIONED_NAMESPACE_DECL + #endif /* ACE_HAS_BROKEN_HPUX_TEMPLATES */ +ACE_BEGIN_VERSIONED_NAMESPACE_DECL + #if defined (ACE_HAS_EXPLICIT_TEMPLATE_INSTANTIATION) template class ACE_Timer_Heap_T<ACE_Event_Handler *, ACE_Event_Handler_Handle_Timeout_Upcall<ACE_SYNCH_RECURSIVE_MUTEX>, ACE_SYNCH_RECURSIVE_MUTEX>; template class ACE_Timer_Heap_Iterator_T<ACE_Event_Handler *, ACE_Event_Handler_Handle_Timeout_Upcall<ACE_SYNCH_RECURSIVE_MUTEX>, ACE_SYNCH_RECURSIVE_MUTEX>; @@ -41,4 +48,5 @@ template class ACE_Timer_Heap_Iterator_T<ACE_Event_Handler *, ACE_Event_Handler_ #pragma instantiate ACE_Timer_Heap_Iterator_T<ACE_Event_Handler *, ACE_Event_Handler_Handle_Timeout_Upcall<ACE_SYNCH_RECURSIVE_MUTEX>, ACE_SYNCH_RECURSIVE_MUTEX> #endif /* ACE_HAS_EXPLICIT_TEMPLATE_INSTANTIATION */ -#endif /* ACE_TIMER_HEAP_C */ +ACE_END_VERSIONED_NAMESPACE_DECL + diff --git a/ace/Timer_Heap.h b/ace/Timer_Heap.h index e40ca3f0f39..a0c9301ebc8 100644 --- a/ace/Timer_Heap.h +++ b/ace/Timer_Heap.h @@ -20,7 +20,9 @@ # pragma once #endif /* ACE_LACKS_PRAGMA_ONCE */ -// The following typedef are here for ease of use and backward +ACE_BEGIN_VERSIONED_NAMESPACE_DECL + +// The following typedefs are here for ease of use and backward // compatibility. typedef ACE_Timer_Heap_T<ACE_Event_Handler *, @@ -33,5 +35,7 @@ typedef ACE_Timer_Heap_Iterator_T<ACE_Event_Handler *, ACE_SYNCH_RECURSIVE_MUTEX> ACE_Timer_Heap_Iterator; +ACE_END_VERSIONED_NAMESPACE_DECL + #include /**/ "ace/post.h" #endif /* ACE_TIMER_HEAP_H */ diff --git a/ace/Timer_Heap_T.cpp b/ace/Timer_Heap_T.cpp index 8f777920706..cc57cdbf5d3 100644 --- a/ace/Timer_Heap_T.cpp +++ b/ace/Timer_Heap_T.cpp @@ -1,7 +1,7 @@ // $Id$ -#ifndef ACE_TIMER_HEAP_T_C -#define ACE_TIMER_HEAP_T_C +#ifndef ACE_TIMER_HEAP_T_CPP +#define ACE_TIMER_HEAP_T_CPP #include "ace/Timer_Heap_T.h" #include "ace/Log_Msg.h" @@ -12,7 +12,7 @@ # pragma once #endif /* ACE_LACKS_PRAGMA_ONCE */ -ACE_RCSID(ace, Timer_Heap_T, "$Id$") +ACE_BEGIN_VERSIONED_NAMESPACE_DECL // Define some simple macros to clarify the code. #define ACE_HEAP_PARENT(X) (X == 0 ? 0 : (((X) - 1) / 2)) @@ -814,4 +814,6 @@ ACE_Timer_Heap_T<TYPE, FUNCTOR, ACE_LOCK>::get_first (void) return this->cur_size_ == 0 ? 0 : this->heap_[0]; } -#endif /* ACE_TIMER_HEAP_T_C */ +ACE_END_VERSIONED_NAMESPACE_DECL + +#endif /* ACE_TIMER_HEAP_T_CPP */ diff --git a/ace/Timer_Heap_T.h b/ace/Timer_Heap_T.h index bf2147019cc..5f027f85ed5 100644 --- a/ace/Timer_Heap_T.h +++ b/ace/Timer_Heap_T.h @@ -1,4 +1,4 @@ -/* -*- C++ -*- */ +// -*- C++ -*- //============================================================================= /** @@ -23,6 +23,8 @@ #include "ace/Free_List.h" #include "ace/Unbounded_Set.h" +ACE_BEGIN_VERSIONED_NAMESPACE_DECL + // Forward declaration template <class TYPE, class FUNCTOR, class ACE_LOCK> class ACE_Timer_Heap_T; @@ -322,6 +324,8 @@ private: ACE_UNIMPLEMENTED_FUNC (void operator= (const ACE_Timer_Heap_T<TYPE, FUNCTOR, ACE_LOCK> &)) }; +ACE_END_VERSIONED_NAMESPACE_DECL + #if defined (ACE_TEMPLATES_REQUIRE_SOURCE) && !defined(ACE_HAS_BROKEN_HPUX_TEMPLATES) #include "ace/Timer_Heap_T.cpp" #endif /* ACE_TEMPLATES_REQUIRE_SOURCE && !ACE_HAS_BROKEN_HPUX_TEMPLATES */ diff --git a/ace/Timer_List.cpp b/ace/Timer_List.cpp index 777091e5af1..feb7633bb68 100644 --- a/ace/Timer_List.cpp +++ b/ace/Timer_List.cpp @@ -1,8 +1,5 @@ // $Id$ -#if !defined (ACE_TIMER_LIST_C) -#define ACE_TIMER_LIST_C - #include "ace/Timer_List.h" #include "ace/Synch_Traits.h" #include "ace/Recursive_Thread_Mutex.h" @@ -13,6 +10,8 @@ ACE_RCSID(ace, Timer_List, "$Id$") #include "ace/Timer_Hash.h" #include "ace/Timer_List_T.cpp" +ACE_BEGIN_VERSIONED_NAMESPACE_DECL + #if defined (ACE_HAS_EXPLICIT_TEMPLATE_INSTANTIATION) template class ACE_Timer_List_T< @@ -42,5 +41,4 @@ template class ACE_Timer_List_Iterator_T<ACE_Event_Handler *, ACE_Event_Handler_ #pragma instantiate ACE_Timer_List_Iterator_T<ACE_Event_Handler *, ACE_Event_Handler_Handle_Timeout_Upcall<ACE_SYNCH_RECURSIVE_MUTEX>, ACE_SYNCH_RECURSIVE_MUTEX> #endif /* ACE_HAS_EXPLICIT_TEMPLATE_INSTANTIATION */ - -#endif /* ACE_TIMER_LIST_C */ +ACE_END_VERSIONED_NAMESPACE_DECL diff --git a/ace/Timer_List.h b/ace/Timer_List.h index 571364742a8..0bc689465ea 100644 --- a/ace/Timer_List.h +++ b/ace/Timer_List.h @@ -1,4 +1,4 @@ -/* -*- C++ -*- */ +// -*- C++ -*- //============================================================================= /** @@ -21,7 +21,9 @@ # pragma once #endif /* ACE_LACKS_PRAGMA_ONCE */ -// The following typedef are here for ease of use and backward +ACE_BEGIN_VERSIONED_NAMESPACE_DECL + +// The following typedefs are here for ease of use and backward // compatibility. typedef ACE_Timer_List_T<ACE_Event_Handler *, @@ -34,5 +36,7 @@ typedef ACE_Timer_List_Iterator_T<ACE_Event_Handler *, ACE_SYNCH_RECURSIVE_MUTEX> ACE_Timer_List_Iterator; +ACE_END_VERSIONED_NAMESPACE_DECL + #include /**/ "ace/post.h" #endif /* ACE_TIMER_LIST_H */ diff --git a/ace/Timer_Queue.cpp b/ace/Timer_Queue.cpp index eadbf31c883..4c52a52bb6b 100644 --- a/ace/Timer_Queue.cpp +++ b/ace/Timer_Queue.cpp @@ -1,8 +1,5 @@ // $Id$ -#if !defined (ACE_TIMER_QUEUE_C) -#define ACE_TIMER_QUEUE_C - #include "ace/Containers.h" #include "ace/Timer_Queue.h" #include "ace/Synch_Traits.h" @@ -14,6 +11,8 @@ ACE_RCSID(ace, Timer_Queue, "$Id$") #include "ace/Timer_Hash.h" #include "ace/Timer_Queue_T.cpp" +ACE_BEGIN_VERSIONED_NAMESPACE_DECL + #if defined (ACE_HAS_EXPLICIT_TEMPLATE_INSTANTIATION) template class ACE_Timer_Queue_T< @@ -58,4 +57,4 @@ template class ACE_Event_Handler_Handle_Timeout_Upcall<ACE_SYNCH_RECURSIVE_MUTEX #endif /* ACE_HAS_EXPLICIT_TEMPLATE_INSTANTIATION */ -#endif /* ACE_TIMER_QUEUE_C */ +ACE_END_VERSIONED_NAMESPACE_DECL diff --git a/ace/Timer_Queue.h b/ace/Timer_Queue.h index e697ee9213a..36182f15f95 100644 --- a/ace/Timer_Queue.h +++ b/ace/Timer_Queue.h @@ -30,6 +30,8 @@ # include "ace/Null_Mutex.h" #endif /* ACE_HAS_THREADS */ +ACE_BEGIN_VERSIONED_NAMESPACE_DECL + // The following typedef are here for ease of use and backward // compatibility. typedef ACE_Timer_Node_Dispatch_Info_T<ACE_Event_Handler *> @@ -43,6 +45,8 @@ typedef ACE_Timer_Queue_Iterator_T<ACE_Event_Handler *, ACE_SYNCH_RECURSIVE_MUTEX> ACE_Timer_Queue_Iterator; +ACE_END_VERSIONED_NAMESPACE_DECL + #include /**/ "ace/post.h" #endif /* ACE_TIMER_QUEUE_H */ diff --git a/ace/Timer_Queue_Adapters.cpp b/ace/Timer_Queue_Adapters.cpp index 13489a858a2..24ebd060aeb 100644 --- a/ace/Timer_Queue_Adapters.cpp +++ b/ace/Timer_Queue_Adapters.cpp @@ -1,14 +1,14 @@ // $Id$ +#ifndef ACE_TIMER_QUEUE_ADAPTERS_CPP +#define ACE_TIMER_QUEUE_ADAPTERS_CPP + #include "ace/Timer_Queue_Adapters.h" #if !defined (ACE_LACKS_PRAGMA_ONCE) # pragma once #endif /* ACE_LACKS_PRAGMA_ONCE */ -#ifndef ACE_TIMER_QUEUE_ADAPTERS_CPP -#define ACE_TIMER_QUEUE_ADAPTERS_CPP - # if !defined (__ACE_INLINE__) # include "ace/Timer_Queue_Adapters.inl" # endif /* __ACE_INLINE__ */ @@ -16,6 +16,8 @@ #include "ace/OS_NS_unistd.h" #include "ace/OS_NS_sys_time.h" +ACE_BEGIN_VERSIONED_NAMESPACE_DECL + template <class TQ> TQ & ACE_Async_Timer_Queue_Adapter<TQ>::timer_queue (void) { @@ -340,4 +342,6 @@ ACE_Thread_Timer_Queue_Adapter<TQ>::dispatch_commands (void) # endif /* ACE_HAS_DEFERRED_TIMER_COMMANDS */ +ACE_END_VERSIONED_NAMESPACE_DECL + #endif /* ACE_TIMER_QUEUE_ADAPTERS_CPP */ diff --git a/ace/Timer_Queue_Adapters.h b/ace/Timer_Queue_Adapters.h index ed8d0cd8ecc..74794d8a93b 100644 --- a/ace/Timer_Queue_Adapters.h +++ b/ace/Timer_Queue_Adapters.h @@ -26,9 +26,13 @@ #if defined (ACE_HAS_DEFERRED_TIMER_COMMANDS) # include "ace/Unbounded_Queue.h" +ACE_BEGIN_VERSIONED_NAMESPACE_DECL class ACE_Command_Base; +ACE_END_VERSIONED_NAMESPACE_DECL #endif /* ACE_HAS_DEFERRED_TIMER_COMMANDS */ +ACE_BEGIN_VERSIONED_NAMESPACE_DECL + /** * @class ACE_Async_Timer_Queue_Adapter * @@ -230,6 +234,8 @@ private: ACE_thread_t thr_id_; }; +ACE_END_VERSIONED_NAMESPACE_DECL + #if defined (__ACE_INLINE__) # include "ace/Timer_Queue_Adapters.inl" #endif /* __ACE_INLINE__ */ diff --git a/ace/Timer_Queue_Adapters.inl b/ace/Timer_Queue_Adapters.inl index 547c693dd13..e66168bbe98 100644 --- a/ace/Timer_Queue_Adapters.inl +++ b/ace/Timer_Queue_Adapters.inl @@ -1,6 +1,9 @@ -/* -*- C++ -*- */ +// -*- C++ -*- +// // $Id$ +ACE_BEGIN_VERSIONED_NAMESPACE_DECL + template<class TQ> ACE_INLINE TQ * ACE_Thread_Timer_Queue_Adapter<TQ>::timer_queue (void) const { @@ -22,3 +25,5 @@ ACE_Thread_Timer_Queue_Adapter<TQ>::thr_id (void) const { return this->thr_id_; } + +ACE_END_VERSIONED_NAMESPACE_DECL diff --git a/ace/Timer_Queue_T.cpp b/ace/Timer_Queue_T.cpp index 4c125cfabcd..71ee2024bb2 100644 --- a/ace/Timer_Queue_T.cpp +++ b/ace/Timer_Queue_T.cpp @@ -1,7 +1,7 @@ // $Id$ -#ifndef ACE_TIMER_QUEUE_T_C -#define ACE_TIMER_QUEUE_T_C +#ifndef ACE_TIMER_QUEUE_T_CPP +#define ACE_TIMER_QUEUE_T_CPP #include "ace/config-all.h" @@ -20,10 +20,7 @@ #include "ace/Timer_Queue_T.inl" #endif /* __ACE_INLINE__ */ -ACE_RCSID (ace, - Timer_Queue_T, - "$Id$") - +ACE_BEGIN_VERSIONED_NAMESPACE_DECL // This fudge factor can be overriden for timers that need it, such as on // Solaris, by defining the ACE_TIMER_SKEW symbol in the appropriate config @@ -475,4 +472,6 @@ ACE_Event_Handler_Handle_Timeout_Upcall<ACE_LOCK>::deletion (TIMER_QUEUE &timer_ return 0; } -#endif /* ACE_TIMER_QUEUE_T_C */ +ACE_END_VERSIONED_NAMESPACE_DECL + +#endif /* ACE_TIMER_QUEUE_T_CPP */ diff --git a/ace/Timer_Queue_T.h b/ace/Timer_Queue_T.h index 50ed8ce99a8..b173802f13f 100644 --- a/ace/Timer_Queue_T.h +++ b/ace/Timer_Queue_T.h @@ -1,4 +1,4 @@ -/* -*- C++ -*- */ +// -*- C++ -*- //============================================================================= /** @@ -25,6 +25,8 @@ #include "ace/Event_Handler.h" #include "ace/Time_Value.h" +ACE_BEGIN_VERSIONED_NAMESPACE_DECL + /** * @class ACE_Timer_Node_Dispatch_Info_T * @@ -542,6 +544,8 @@ private: ACE_UNIMPLEMENTED_FUNC (void operator= (const ACE_Event_Handler_Handle_Timeout_Upcall<ACE_LOCK> &)) }; +ACE_END_VERSIONED_NAMESPACE_DECL + #if defined (__ACE_INLINE__) #include "ace/Timer_Queue_T.inl" #endif /* __ACE_INLINE__ */ diff --git a/ace/Timer_Queue_T.inl b/ace/Timer_Queue_T.inl index 294433e8285..7275119e2e1 100644 --- a/ace/Timer_Queue_T.inl +++ b/ace/Timer_Queue_T.inl @@ -2,6 +2,7 @@ // // $Id$ +ACE_BEGIN_VERSIONED_NAMESPACE_DECL template <class TYPE> ACE_INLINE void ACE_Timer_Node_T<TYPE>::set (const TYPE &type, @@ -217,3 +218,5 @@ ACE_Timer_Queue_T<TYPE, FUNCTOR, ACE_LOCK>::upcall_functor (void) { return *this->upcall_functor_; } + +ACE_END_VERSIONED_NAMESPACE_DECL diff --git a/ace/Timer_Queuefwd.h b/ace/Timer_Queuefwd.h index 0f8ad0330c2..6e03204bdde 100644 --- a/ace/Timer_Queuefwd.h +++ b/ace/Timer_Queuefwd.h @@ -19,6 +19,8 @@ #include "ace/Synch_Traits.h" +ACE_BEGIN_VERSIONED_NAMESPACE_DECL + template <class TYPE, class FUNCTOR, class ACE_LOCK> class ACE_Timer_Queue_T; template <class ACE_LOCK> class ACE_Event_Handler_Handle_Timeout_Upcall; @@ -29,6 +31,8 @@ typedef ACE_Timer_Queue_T<ACE_Event_Handler *, ACE_SYNCH_RECURSIVE_MUTEX> ACE_Timer_Queue; +ACE_END_VERSIONED_NAMESPACE_DECL + #include /**/ "ace/post.h" #endif /* ACE_TIMER_QUEUE_FWD_H */ diff --git a/ace/Timer_Wheel.cpp b/ace/Timer_Wheel.cpp index 0675711f329..3861edb2c54 100644 --- a/ace/Timer_Wheel.cpp +++ b/ace/Timer_Wheel.cpp @@ -1,8 +1,5 @@ // $Id$ -#if !defined (ACE_TIMER_WHEEL_C) -#define ACE_TIMER_WHEEL_C - #include "ace/Timer_Wheel.h" #include "ace/Synch_Traits.h" #include "ace/Recursive_Thread_Mutex.h" @@ -13,6 +10,8 @@ ACE_RCSID(ace, Timer_Wheel, "$Id$") +ACE_BEGIN_VERSIONED_NAMESPACE_DECL + #if defined (ACE_HAS_EXPLICIT_TEMPLATE_INSTANTIATION) template class ACE_Timer_Wheel_T<ACE_Event_Handler *, ACE_Event_Handler_Handle_Timeout_Upcall<ACE_SYNCH_RECURSIVE_MUTEX>, ACE_SYNCH_RECURSIVE_MUTEX>; template class ACE_Timer_Wheel_Iterator_T<ACE_Event_Handler *, ACE_Event_Handler_Handle_Timeout_Upcall<ACE_SYNCH_RECURSIVE_MUTEX>, ACE_SYNCH_RECURSIVE_MUTEX>; @@ -21,5 +20,4 @@ template class ACE_Timer_Wheel_Iterator_T<ACE_Event_Handler *, ACE_Event_Handler #pragma instantiate ACE_Timer_Wheel_Iterator_T<ACE_Event_Handler *, ACE_Event_Handler_Handle_Timeout_Upcall<ACE_SYNCH_RECURSIVE_MUTEX>, ACE_SYNCH_RECURSIVE_MUTEX> #endif /* ACE_HAS_EXPLICIT_TEMPLATE_INSTANTIATION */ - -#endif /* ACE_TIMER_WHEEL_C */ +ACE_END_VERSIONED_NAMESPACE_DECL diff --git a/ace/Timer_Wheel.h b/ace/Timer_Wheel.h index cdd967bd9bd..307e56b5542 100644 --- a/ace/Timer_Wheel.h +++ b/ace/Timer_Wheel.h @@ -1,5 +1,4 @@ - -/* -*- C++ -*- */ +// -*- C++ -*- //============================================================================= /** @@ -22,7 +21,9 @@ # pragma once #endif /* ACE_LACKS_PRAGMA_ONCE */ -// The following typedef are here for ease of use and backward +ACE_BEGIN_VERSIONED_NAMESPACE_DECL + +// The following typedefs are here for ease of use and backward // compatibility. typedef ACE_Timer_Wheel_T<ACE_Event_Handler *, @@ -35,5 +36,7 @@ typedef ACE_Timer_Wheel_Iterator_T<ACE_Event_Handler *, ACE_SYNCH_RECURSIVE_MUTEX> ACE_Timer_Wheel_Iterator; +ACE_END_VERSIONED_NAMESPACE_DECL + #include /**/ "ace/post.h" #endif /* ACE_TIMER_WHEEL_H */ diff --git a/ace/Timer_Wheel_T.cpp b/ace/Timer_Wheel_T.cpp index f32b29b8853..149de55c520 100644 --- a/ace/Timer_Wheel_T.cpp +++ b/ace/Timer_Wheel_T.cpp @@ -1,7 +1,7 @@ // $Id$ -#ifndef ACE_TIMER_WHEEL_T_C -#define ACE_TIMER_WHEEL_T_C +#ifndef ACE_TIMER_WHEEL_T_CPP +#define ACE_TIMER_WHEEL_T_CPP #if !defined (ACE_LACKS_PRAGMA_ONCE) # pragma once @@ -12,8 +12,7 @@ #include "ace/Timer_Wheel_T.h" #include "ace/Log_Msg.h" -ACE_RCSID(ace, Timer_Wheel_T, "$Id$") - +ACE_BEGIN_VERSIONED_NAMESPACE_DECL // Design/implementation notes for ACE_Timer_Wheel_T. // @@ -941,7 +940,6 @@ ACE_Timer_Wheel_Iterator_T<TYPE, FUNCTOR, ACE_LOCK>::goto_next (u_int start_spok this->current_node_ = 0; } - /** * @return True when we there aren't any more items (when current_node_ == 0) */ @@ -951,7 +949,6 @@ ACE_Timer_Wheel_Iterator_T<TYPE, FUNCTOR, ACE_LOCK>::isdone (void) const return this->current_node_ == 0; } - /** * @return The node at the current spokeition in the sequence or 0 if the wheel * is empty @@ -962,5 +959,6 @@ ACE_Timer_Wheel_Iterator_T<TYPE, FUNCTOR, ACE_LOCK>::item (void) return this->current_node_; } +ACE_END_VERSIONED_NAMESPACE_DECL -#endif /* ACE_TIMER_WHEEL_T_C */ +#endif /* ACE_TIMER_WHEEL_T_CPP */ diff --git a/ace/Timer_Wheel_T.h b/ace/Timer_Wheel_T.h index 10bb65badd8..8c534a10b41 100644 --- a/ace/Timer_Wheel_T.h +++ b/ace/Timer_Wheel_T.h @@ -1,4 +1,4 @@ -/* -*- C++ -*- */ +// -*- C++ -*- //============================================================================= /** @@ -20,6 +20,8 @@ # pragma once #endif /* ACE_LACKS_PRAGMA_ONCE */ +ACE_BEGIN_VERSIONED_NAMESPACE_DECL + // Forward declaration template <class TYPE, class FUNCTOR, class ACE_LOCK> class ACE_Timer_Wheel_T; @@ -211,6 +213,8 @@ private: void operator= (const ACE_Timer_Wheel_T<TYPE, FUNCTOR, ACE_LOCK> &)) }; +ACE_END_VERSIONED_NAMESPACE_DECL + #if defined (ACE_TEMPLATES_REQUIRE_SOURCE) #if !defined (ACE_HAS_BROKEN_HPUX_TEMPLATES) #include "ace/Timer_Wheel_T.cpp" diff --git a/ace/TkReactor.cpp b/ace/TkReactor.cpp index 5fb8b56db71..7f6ae69e320 100644 --- a/ace/TkReactor.cpp +++ b/ace/TkReactor.cpp @@ -5,12 +5,14 @@ ACE_RCSID(ace, TkReactor, "$Id$") +ACE_BEGIN_VERSIONED_NAMESPACE_DECL + ACE_ALLOC_HOOK_DEFINE (ACE_TkReactor) // Must be called with lock held ACE_TkReactor::ACE_TkReactor (size_t size, - int restart, - ACE_Sig_Handler *h) + int restart, + ACE_Sig_Handler *h) : ACE_Select_Reactor (size, restart, h), ids_ (0), timeout_ (0) @@ -49,7 +51,7 @@ ACE_TkReactor::~ACE_TkReactor (void) int ACE_TkReactor::wait_for_multiple_events (ACE_Select_Reactor_Handle_Set &handle_set, - ACE_Time_Value *max_wait_time) + ACE_Time_Value *max_wait_time) { ACE_TRACE ("ACE_TkReactor::wait_for_multiple_events"); int nfound; @@ -63,8 +65,8 @@ ACE_TkReactor::wait_for_multiple_events (ACE_Select_Reactor_Handle_Set &handle_s handle_set.wr_mask_ = this->wait_set_.wr_mask_; handle_set.ex_mask_ = this->wait_set_.ex_mask_; nfound = TkWaitForMultipleEvents (width, - handle_set, - max_wait_time); + handle_set, + max_wait_time); } while (nfound == -1 && this->handle_error () > 0); @@ -101,7 +103,7 @@ ACE_TkReactor::TimerCallbackProc (ClientData cd) */ void ACE_TkReactor::InputCallbackProc (ClientData cd, - int /* mask */) + int /* mask */) { ACE_TkReactor_Input_Callback *callback = (ACE_TkReactor_Input_Callback *) cd; ACE_TkReactor *self = callback->reactor_; @@ -123,9 +125,9 @@ ACE_TkReactor::InputCallbackProc (ClientData cd, wait_set.ex_mask_.set_bit (handle); int result = ACE_OS::select (handle + 1, - wait_set.rd_mask_, - wait_set.wr_mask_, - wait_set.ex_mask_, &zero); + wait_set.rd_mask_, + wait_set.wr_mask_, + wait_set.ex_mask_, &zero); ACE_Select_Reactor_Handle_Set dispatch_set; @@ -133,11 +135,11 @@ ACE_TkReactor::InputCallbackProc (ClientData cd, if (result > 0) { if (wait_set.rd_mask_.is_set (handle)) - dispatch_set.rd_mask_.set_bit (handle); + dispatch_set.rd_mask_.set_bit (handle); if (wait_set.wr_mask_.is_set (handle)) - dispatch_set.wr_mask_.set_bit (handle); + dispatch_set.wr_mask_.set_bit (handle); if (wait_set.ex_mask_.is_set (handle)) - dispatch_set.ex_mask_.set_bit (handle); + dispatch_set.ex_mask_.set_bit (handle); self->dispatch (1, dispatch_set); } @@ -145,17 +147,17 @@ ACE_TkReactor::InputCallbackProc (ClientData cd, int ACE_TkReactor::TkWaitForMultipleEvents (int width, - ACE_Select_Reactor_Handle_Set &wait_set, - ACE_Time_Value *) + ACE_Select_Reactor_Handle_Set &wait_set, + ACE_Time_Value *) { // Check to make sure our handle's are all usable. ACE_Select_Reactor_Handle_Set temp_set = wait_set; if (ACE_OS::select (width, - temp_set.rd_mask_, - temp_set.wr_mask_, - temp_set.ex_mask_, - (ACE_Time_Value *) &ACE_Time_Value::zero) == -1) + temp_set.rd_mask_, + temp_set.wr_mask_, + temp_set.ex_mask_, + (ACE_Time_Value *) &ACE_Time_Value::zero) == -1) return -1; // Bad file arguments... // Instead of waiting using <select>, just use the Tk mechanism to @@ -170,16 +172,16 @@ ACE_TkReactor::TkWaitForMultipleEvents (int width, // Now actually read the result needed by the <Select_Reactor> using // <select>. return ACE_OS::select (width, - wait_set.rd_mask_, - wait_set.wr_mask_, - wait_set.ex_mask_, - (ACE_Time_Value *) &ACE_Time_Value::zero); + wait_set.rd_mask_, + wait_set.wr_mask_, + wait_set.ex_mask_, + (ACE_Time_Value *) &ACE_Time_Value::zero); } int ACE_TkReactor::register_handler_i (ACE_HANDLE handle, - ACE_Event_Handler *handler, - ACE_Reactor_Mask mask) + ACE_Event_Handler *handler, + ACE_Reactor_Mask mask) { ACE_TRACE ("ACE_TkReactor::register_handler_i"); @@ -267,8 +269,8 @@ ACE_TkReactor::register_handler_i (ACE_HANDLE handle, int ACE_TkReactor::register_handler_i (const ACE_Handle_Set &handles, - ACE_Event_Handler *handler, - ACE_Reactor_Mask mask) + ACE_Event_Handler *handler, + ACE_Reactor_Mask mask) { return ACE_Select_Reactor::register_handler_i (handles, handler, @@ -277,7 +279,7 @@ ACE_TkReactor::register_handler_i (const ACE_Handle_Set &handles, int ACE_TkReactor::remove_handler_i (ACE_HANDLE handle, - ACE_Reactor_Mask mask) + ACE_Reactor_Mask mask) { ACE_TRACE ("ACE_TkReactor::remove_handler_i"); @@ -332,10 +334,10 @@ ACE_TkReactor::remove_TkFileHandler (ACE_HANDLE handle) int ACE_TkReactor::remove_handler_i (const ACE_Handle_Set &handles, - ACE_Reactor_Mask mask) + ACE_Reactor_Mask mask) { return ACE_Select_Reactor::remove_handler_i (handles, - mask); + mask); } // The following functions ensure that there is an Tk timeout for the @@ -380,9 +382,9 @@ ACE_TkReactor::reset_timer_interval long ACE_TkReactor::schedule_timer (ACE_Event_Handler *event_handler, - const void *arg, + const void *arg, const ACE_Time_Value &delay, - const ACE_Time_Value &interval) + const ACE_Time_Value &interval) { ACE_TRACE ("ACE_TkReactor::schedule_timer"); ACE_MT (ACE_GUARD_RETURN (ACE_Select_Reactor_Token, ace_mon, this->token_, -1)); @@ -402,12 +404,12 @@ ACE_TkReactor::schedule_timer (ACE_Event_Handler *event_handler, int ACE_TkReactor::cancel_timer (ACE_Event_Handler *handler, - int dont_call_handle_close) + int dont_call_handle_close) { ACE_TRACE ("ACE_TkReactor::cancel_timer"); if (ACE_Select_Reactor::cancel_timer (handler, - dont_call_handle_close) == -1) + dont_call_handle_close) == -1) return -1; else { @@ -418,14 +420,14 @@ ACE_TkReactor::cancel_timer (ACE_Event_Handler *handler, int ACE_TkReactor::cancel_timer (long timer_id, - const void **arg, - int dont_call_handle_close) + const void **arg, + int dont_call_handle_close) { ACE_TRACE ("ACE_TkReactor::cancel_timer"); if (ACE_Select_Reactor::cancel_timer (timer_id, - arg, - dont_call_handle_close) == -1) + arg, + dont_call_handle_close) == -1) return -1; else { @@ -434,3 +436,4 @@ ACE_TkReactor::cancel_timer (long timer_id, } } +ACE_END_VERSIONED_NAMESPACE_DECL diff --git a/ace/TkReactor.h b/ace/TkReactor.h index 024d341b937..0ae370c0687 100644 --- a/ace/TkReactor.h +++ b/ace/TkReactor.h @@ -1,4 +1,5 @@ -/* -*- C++ -*- */ +// -*- C++ -*- + //============================================================================= /** * @file TkReactor.h @@ -24,6 +25,8 @@ #include "ace/Select_Reactor.h" #include /**/ <tk.h> +ACE_BEGIN_VERSIONED_NAMESPACE_DECL + /** * @class ACE_TkReactorID * @@ -127,5 +130,7 @@ private: ACE_TkReactor &operator = (const ACE_TkReactor &); }; +ACE_END_VERSIONED_NAMESPACE_DECL + #include /**/ "ace/post.h" #endif /* ACE_TK_REACTOR_H */ diff --git a/ace/Token.cpp b/ace/Token.cpp index d67e51e5bcb..53c7bfaaed8 100644 --- a/ace/Token.cpp +++ b/ace/Token.cpp @@ -1,7 +1,12 @@ // $Id$ -#include "ace/Thread.h" #include "ace/Token.h" + +ACE_RCSID(ace, Token, "$Id$") + +#if defined (ACE_HAS_THREADS) + +#include "ace/Thread.h" #include "ace/Log_Msg.h" #if defined (DEBUGGING) @@ -9,17 +14,14 @@ #include "ace/streams.h" #endif /* DEBUGGING */ -ACE_RCSID(ace, Token, "$Id$") - #if !defined (__ACE_INLINE__) #include "ace/Token.inl" #endif /* __ACE_INLINE__ */ -#if defined (ACE_HAS_THREADS) +ACE_BEGIN_VERSIONED_NAMESPACE_DECL ACE_ALLOC_HOOK_DEFINE(ACE_Token) - void ACE_Token::dump (void) const { @@ -544,8 +546,6 @@ ACE_Token::wakeup_next_waiter (void) this->owner_ = queue->head_->thread_id_; } -#endif /* ACE_HAS_THREADS */ +ACE_END_VERSIONED_NAMESPACE_DECL -#if defined (ACE_HAS_EXPLICIT_TEMPLATE_INSTANTIATION) -#elif defined (ACE_HAS_TEMPLATE_INSTANTIATION_PRAGMA) -#endif /* ACE_HAS_EXPLICIT_TEMPLATE_INSTANTIATION */ +#endif /* ACE_HAS_THREADS */ diff --git a/ace/Token.h b/ace/Token.h index 0295133e542..f351bcab979 100644 --- a/ace/Token.h +++ b/ace/Token.h @@ -1,4 +1,4 @@ -/* -*- C++ -*- */ +// -*- C++ -*- //============================================================================= /** @@ -34,14 +34,15 @@ # define ACE_TOKEN_USES_SEMAPHORE #endif /* (ACE_WIN32 && !ACE_HAS_WINCE) || VXWORKS || ACE_PSOS */ -class ACE_Time_Value; - #if defined (ACE_TOKEN_USES_SEMAPHORE) # include "ace/Semaphore.h" #endif /* ACE_TOKEN_USES_SEMAPHORE */ #include "ace/Condition_Thread_Mutex.h" +ACE_BEGIN_VERSIONED_NAMESPACE_DECL + +class ACE_Time_Value; /** * @class ACE_Token @@ -316,7 +317,12 @@ private: int queueing_strategy_; }; +ACE_END_VERSIONED_NAMESPACE_DECL + #else + +ACE_BEGIN_VERSIONED_NAMESPACE_DECL + class ACE_Export ACE_Token { public: @@ -327,8 +333,13 @@ public: int remove (void) { ACE_NOTSUP_RETURN (-1); } int release (void) { ACE_NOTSUP_RETURN (-1); } }; + +ACE_END_VERSIONED_NAMESPACE_DECL + #endif /* ACE_HAS_THREADS */ +ACE_BEGIN_VERSIONED_NAMESPACE_DECL + class ACE_Export ACE_Noop_Token : public ACE_Null_Mutex { public: @@ -354,6 +365,8 @@ public: ACE_ALLOC_HOOK_DECLARE; }; +ACE_END_VERSIONED_NAMESPACE_DECL + #if defined (__ACE_INLINE__) #include "ace/Token.inl" #endif /* __ACE_INLINE__ */ diff --git a/ace/Token.inl b/ace/Token.inl index 5cea9866cea..4ba04e9e55d 100644 --- a/ace/Token.inl +++ b/ace/Token.inl @@ -1,14 +1,15 @@ -/* -*- C++ -*- */ +// -*- C++ -*- +// // $Id$ #include "ace/Guard_T.h" -// Token.i - #if defined (ACE_HAS_THREADS) #include "ace/Time_Value.h" +ACE_BEGIN_VERSIONED_NAMESPACE_DECL + ACE_INLINE int ACE_Token::queueing_strategy (void) { @@ -29,15 +30,15 @@ ACE_Token::remove (void) ACE_NOTSUP_RETURN (-1); } -ACE_INLINE int +ACE_INLINE int ACE_Token::tryacquire (void) { ACE_TRACE ("ACE_Token::tryacquire"); - return this->shared_acquire + return this->shared_acquire (0, 0, (ACE_Time_Value *) &ACE_Time_Value::zero, ACE_Token::WRITE_TOKEN); } -ACE_INLINE int +ACE_INLINE int ACE_Token::waiters (void) { ACE_TRACE ("ACE_Token::waiters"); @@ -47,7 +48,7 @@ ACE_Token::waiters (void) return ret; } -ACE_INLINE ACE_thread_t +ACE_INLINE ACE_thread_t ACE_Token::current_owner (void) { ACE_TRACE ("ACE_Token::current_owner"); @@ -132,7 +133,7 @@ ACE_Token::ACE_Token_Queue_Entry::wait (ACE_Time_Value *timeout, ACE_Thread_Mute ACE_INLINE int ACE_Token::ACE_Token_Queue_Entry::signal (void) { - return + return #if defined (ACE_TOKEN_USES_SEMAPHORE) this->cv_.release (); #else @@ -140,8 +141,13 @@ ACE_Token::ACE_Token_Queue_Entry::signal (void) #endif /* ACE_TOKEN_USES_SEMAPHORE */ } +ACE_END_VERSIONED_NAMESPACE_DECL + #endif /* ACE_HAS_THREADS */ -/******************************************************************************/ + +/*****************************************************************************/ + +ACE_BEGIN_VERSIONED_NAMESPACE_DECL ACE_INLINE int ACE_Noop_Token::queueing_strategy (void) @@ -164,3 +170,5 @@ ACE_INLINE void ACE_Noop_Token::dump (void) const { } + +ACE_END_VERSIONED_NAMESPACE_DECL diff --git a/ace/Token_Collection.cpp b/ace/Token_Collection.cpp index 5287cd6208a..19136876e47 100644 --- a/ace/Token_Collection.cpp +++ b/ace/Token_Collection.cpp @@ -1,19 +1,20 @@ #include "ace/Token_Collection.h" +#if defined (ACE_HAS_TOKENS_LIBRARY) + #if !defined (__ACE_INLINE__) #include "ace/Token_Collection.inl" #endif /* __ACE_INLINE__ */ -#if defined (ACE_HAS_TOKENS_LIBRARY) - ACE_RCSID (ace, Token_Collection, "$Id$") +ACE_BEGIN_VERSIONED_NAMESPACE_DECL ACE_Token_Collection::ACE_Token_Collection (int debug, - const ACE_TCHAR *name) + const ACE_TCHAR *name) : debug_ (debug) { ACE_TRACE ("ACE_Token_Collection::ACE_Token_Collection"); @@ -74,8 +75,8 @@ ACE_Token_Collection::is_member (const ACE_Token_Proxy &token) int ACE_Token_Collection::acquire (int notify, - void (*sleep_hook)(void *), - ACE_Synch_Options &options) + void (*sleep_hook)(void *), + ACE_Synch_Options &options) { ACE_TRACE ("ACE_Token_Collection::acquire"); @@ -86,18 +87,18 @@ ACE_Token_Collection::acquire (int notify, iterator.advance ()) { if (debug_) - ACE_DEBUG ((LM_DEBUG, + ACE_DEBUG ((LM_DEBUG, ACE_LIB_TEXT ("collection acquiring %s\n"), - temp->int_id_->name ())); + temp->int_id_->name ())); if (temp->int_id_->acquire (notify, sleep_hook, options) == -1) - { + { // Save/restore errno. ACE_Errno_Guard error (errno); - this->release (); - ACE_RETURN (-1); - } + this->release (); + ACE_RETURN (-1); + } } return 0; @@ -105,9 +106,9 @@ ACE_Token_Collection::acquire (int notify, int ACE_Token_Collection::acquire (const ACE_TCHAR *token_name, - int notify, - void (*sleep_hook)(void *), - ACE_Synch_Options &options) + int notify, + void (*sleep_hook)(void *), + ACE_Synch_Options &options) { ACE_TRACE ("ACE_Token_Collection::acquire"); TOKEN_NAME name (token_name); @@ -124,7 +125,7 @@ ACE_Token_Collection::acquire (const ACE_TCHAR *token_name, int ACE_Token_Collection::tryacquire (const ACE_TCHAR *token_name, - void (*sleep_hook)(void *)) + void (*sleep_hook)(void *)) { ACE_TRACE ("ACE_Token_Collection::tryacquire"); TOKEN_NAME name (token_name); @@ -151,11 +152,11 @@ ACE_Token_Collection::tryacquire (void (*sleep_hook)(void *)) iterator.advance ()) { if (debug_) - ACE_DEBUG ((LM_DEBUG, ACE_LIB_TEXT ("collection acquiring %s\n"), - temp->int_id_->name ())); + ACE_DEBUG ((LM_DEBUG, ACE_LIB_TEXT ("collection acquiring %s\n"), + temp->int_id_->name ())); // We will fail if _any_ token is not free. if (temp->int_id_->tryacquire (sleep_hook) == -1) - return -1; + return -1; } return 0; @@ -163,7 +164,7 @@ ACE_Token_Collection::tryacquire (void (*sleep_hook)(void *)) int ACE_Token_Collection::renew (int requeue_position, - ACE_Synch_Options &options) + ACE_Synch_Options &options) { ACE_TRACE ("ACE_Token_Collection::renew"); @@ -174,10 +175,10 @@ ACE_Token_Collection::renew (int requeue_position, iterator.advance ()) { if (debug_) - ACE_DEBUG ((LM_DEBUG, ACE_LIB_TEXT ("collection renewing %s\n"), - temp->int_id_->name ())); + ACE_DEBUG ((LM_DEBUG, ACE_LIB_TEXT ("collection renewing %s\n"), + temp->int_id_->name ())); if (temp->int_id_->renew (requeue_position, options) == -1) - return -1; + return -1; } return 0; @@ -185,8 +186,8 @@ ACE_Token_Collection::renew (int requeue_position, int ACE_Token_Collection::renew (const ACE_TCHAR *token_name, - int requeue_position, - ACE_Synch_Options &options) + int requeue_position, + ACE_Synch_Options &options) { ACE_TRACE ("ACE_Token_Collection::renew"); TOKEN_NAME name (token_name); @@ -198,8 +199,8 @@ ACE_Token_Collection::renew (const ACE_TCHAR *token_name, // Did we find it? if (result == -1) ACE_ERROR_RETURN ((LM_DEBUG, ACE_LIB_TEXT ("%p %s\n"), - ACE_LIB_TEXT ("not in collection "), - token_name), -1); + ACE_LIB_TEXT ("not in collection "), + token_name), -1); // perform the operation return temp->renew (requeue_position, options); } @@ -216,8 +217,8 @@ ACE_Token_Collection::release (ACE_Synch_Options &) iterator.advance ()) { if (debug_) - ACE_DEBUG ((LM_DEBUG, ACE_LIB_TEXT ("collection releasing %s\n"), - temp->int_id_->name ())); + ACE_DEBUG ((LM_DEBUG, ACE_LIB_TEXT ("collection releasing %s\n"), + temp->int_id_->name ())); temp->int_id_->release (); } @@ -226,7 +227,7 @@ ACE_Token_Collection::release (ACE_Synch_Options &) int ACE_Token_Collection::release (const ACE_TCHAR *token_name, - ACE_Synch_Options &options) + ACE_Synch_Options &options) { ACE_TRACE ("ACE_Token_Collection::release"); TOKEN_NAME name (token_name); @@ -302,4 +303,6 @@ template class ACE_Map_Entry<ACE_Token_Name, ACE_Token_Proxy *>; #pragma instantiate ACE_Map_Entry<ACE_Token_Name, ACE_Token_Proxy *> #endif /* ACE_HAS_EXPLICIT_TEMPLATE_INSTANTIATION */ +ACE_END_VERSIONED_NAMESPACE_DECL + #endif /* ACE_HAS_TOKENS_LIBRARY */ diff --git a/ace/Token_Collection.h b/ace/Token_Collection.h index 1f42c8406cf..0d57cc0ca58 100644 --- a/ace/Token_Collection.h +++ b/ace/Token_Collection.h @@ -1,4 +1,4 @@ -/* -*- C++ -*- */ +// -*- C++ -*- //============================================================================= /** @@ -35,6 +35,8 @@ #include "ace/Local_Tokens.h" #include "ace/Null_Mutex.h" +ACE_BEGIN_VERSIONED_NAMESPACE_DECL + /** * @class ACE_Token_Collection * @@ -229,11 +231,13 @@ protected: virtual ACE_Tokens *create_token (const ACE_TCHAR *name); }; -#endif /* ACE_HAS_TOKENS_LIBRARY */ +ACE_END_VERSIONED_NAMESPACE_DECL #if defined (__ACE_INLINE__) #include "ace/Token_Collection.inl" #endif /* __ACE_INLINE__ */ +#endif /* ACE_HAS_TOKENS_LIBRARY */ + #include /**/ "ace/post.h" #endif /* ACE_TOKEN_COLLECTION_H */ diff --git a/ace/Token_Collection.inl b/ace/Token_Collection.inl index fcab4df9b09..db86701a325 100644 --- a/ace/Token_Collection.inl +++ b/ace/Token_Collection.inl @@ -1,12 +1,17 @@ -/* -*- C++ -*- */ +// -*- C++ -*- +// // $Id$ #if defined (ACE_HAS_TOKENS_LIBRARY) +ACE_BEGIN_VERSIONED_NAMESPACE_DECL + ACE_INLINE const ACE_TCHAR * ACE_Token_Collection::name (void) const { return name_; } +ACE_END_VERSIONED_NAMESPACE_DECL + #endif /* ACE_HAS_TOKENS_LIBRARY */ diff --git a/ace/Token_Invariants.cpp b/ace/Token_Invariants.cpp index e59d28bd6ba..58ca73b9006 100644 --- a/ace/Token_Invariants.cpp +++ b/ace/Token_Invariants.cpp @@ -1,13 +1,14 @@ #include "ace/Token_Invariants.h" -#include "ace/Object_Manager.h" #if defined (ACE_HAS_TOKENS_LIBRARY) +#include "ace/Object_Manager.h" ACE_RCSID (ace, Token_Invariants, "$Id$") +ACE_BEGIN_VERSIONED_NAMESPACE_DECL ACE_Token_Invariant_Manager *ACE_Token_Invariant_Manager::instance_ = 0; @@ -373,4 +374,6 @@ template class ACE_Map_Entry<ACE_Token_Name, ACE_RWLock_Invariants *>; #pragma instantiate ACE_Map_Entry<ACE_Token_Name, ACE_RWLock_Invariants *> #endif /* ACE_HAS_EXPLICIT_TEMPLATE_INSTANTIATION */ +ACE_END_VERSIONED_NAMESPACE_DECL + #endif /* ACE_HAS_TOKENS_LIBRARY */ diff --git a/ace/Token_Invariants.h b/ace/Token_Invariants.h index c5b4fb42ffc..6816d209ab3 100644 --- a/ace/Token_Invariants.h +++ b/ace/Token_Invariants.h @@ -32,6 +32,7 @@ #include "ace/Local_Tokens.h" #include "ace/Null_Mutex.h" +ACE_BEGIN_VERSIONED_NAMESPACE_DECL /** * @class ACE_Mutex_Invariants @@ -236,6 +237,8 @@ protected: static ACE_Token_Invariant_Manager *instance_; }; +ACE_END_VERSIONED_NAMESPACE_DECL + #endif /* ACE_HAS_TOKENS_LIBRARY */ #include /**/ "ace/post.h" diff --git a/ace/Token_Manager.cpp b/ace/Token_Manager.cpp index 24d79871448..3933a468c8d 100644 --- a/ace/Token_Manager.cpp +++ b/ace/Token_Manager.cpp @@ -1,16 +1,19 @@ #include "ace/Token_Manager.h" + +#if defined (ACE_HAS_TOKENS_LIBRARY) + #include "ace/Object_Manager.h" #if !defined (__ACE_INLINE__) #include "ace/Token_Manager.inl" #endif /* __ACE_INLINE__ */ -#if defined (ACE_HAS_TOKENS_LIBRARY) - ACE_RCSID (ace, Token_Manager, "$Id$") +ACE_BEGIN_VERSIONED_NAMESPACE_DECL + // singleton token manager ACE_Token_Manager *ACE_Token_Manager::token_manager_ = 0; @@ -279,4 +282,6 @@ template class ACE_Map_Entry <ACE_Token_Name, ACE_Tokens *>; #pragma instantiate ACE_Map_Entry <ACE_Token_Name, ACE_Tokens *> #endif /* ACE_HAS_EXPLICIT_TEMPLATE_INSTANTIATION */ +ACE_END_VERSIONED_NAMESPACE_DECL + #endif /* ACE_HAS_TOKENS_LIBRARY */ diff --git a/ace/Token_Manager.h b/ace/Token_Manager.h index c19b625116e..63c78712203 100644 --- a/ace/Token_Manager.h +++ b/ace/Token_Manager.h @@ -1,4 +1,4 @@ -/* -*- C++ -*- */ +// -*- C++ -*- //============================================================================= /** @@ -27,6 +27,8 @@ #include "ace/Null_Mutex.h" #include "ace/Map_Manager.h" +ACE_BEGIN_VERSIONED_NAMESPACE_DECL + class ACE_Local_Mutex; class ACE_Mutex_Token; @@ -136,11 +138,13 @@ private: COLLECTION collection_; }; -#endif /* ACE_HAS_TOKENS_LIBRARY */ +ACE_END_VERSIONED_NAMESPACE_DECL #if defined (__ACE_INLINE__) #include "ace/Token_Manager.inl" #endif /* __ACE_INLINE__ */ +#endif /* ACE_HAS_TOKENS_LIBRARY */ + #include /**/ "ace/post.h" #endif /* ACE_TOKEN_MANAGER_H */ diff --git a/ace/Token_Manager.inl b/ace/Token_Manager.inl index 2ef2d7e1f53..b38c4b9e346 100644 --- a/ace/Token_Manager.inl +++ b/ace/Token_Manager.inl @@ -1,8 +1,11 @@ -/* -*- C++ -*- */ +// -*- C++ -*- +// // $Id$ #if defined (ACE_HAS_TOKENS_LIBRARY) +ACE_BEGIN_VERSIONED_NAMESPACE_DECL + ACE_INLINE ACE_TOKEN_CONST::MUTEX & ACE_Token_Manager::mutex (void) { @@ -17,4 +20,6 @@ ACE_Token_Manager::debug (int d) debug_ = d; } +ACE_END_VERSIONED_NAMESPACE_DECL + #endif /* ACE_HAS_TOKENS_LIBRARY */ diff --git a/ace/Token_Request_Reply.cpp b/ace/Token_Request_Reply.cpp index 01ee4fb305d..fa4435bb9d7 100644 --- a/ace/Token_Request_Reply.cpp +++ b/ace/Token_Request_Reply.cpp @@ -2,14 +2,16 @@ #include "ace/Token_Request_Reply.h" +#if defined (ACE_HAS_TOKENS_LIBRARY) + #if !defined (__ACE_INLINE__) #include "ace/Token_Request_Reply.inl" #endif /* __ACE_INLINE__ */ -#if defined (ACE_HAS_TOKENS_LIBRARY) - ACE_RCSID(ace, Token_Request_Reply, "$Id$") +ACE_BEGIN_VERSIONED_NAMESPACE_DECL + // Default "do nothing" constructor. ACE_Token_Request::ACE_Token_Request (void) @@ -21,11 +23,11 @@ ACE_Token_Request::ACE_Token_Request (void) // Create a ACE_Token_Request message. ACE_Token_Request::ACE_Token_Request (int token_type, - int proxy_type, - ACE_UINT32 operation_type, - const ACE_TCHAR token_name[], - const ACE_TCHAR client_id[], - const ACE_Synch_Options &options) + int proxy_type, + ACE_UINT32 operation_type, + const ACE_TCHAR token_name[], + const ACE_TCHAR client_id[], + const ACE_Synch_Options &options) { this->token_type (token_type); this->proxy_type (proxy_type); @@ -57,8 +59,8 @@ ACE_Token_Request::decode (void) this->token_name_ = this->transfer_.data_; options_.set (transfer_.use_timeout_ == 1 ? ACE_Synch_Options::USE_TIMEOUT : 0, - ACE_Time_Value (transfer_.sec_, transfer_.usec_), - (void *) transfer_.arg_); + ACE_Time_Value (transfer_.sec_, transfer_.usec_), + (void *) transfer_.arg_); // Decode the variable-sized portion. int token_len = ACE_OS::strlen (this->token_name_); @@ -79,8 +81,8 @@ ACE_Token_Request::decode (void) // client_id_ plus '\0' size_t data_size = ACE_TOKEN_REQUEST_HEADER_SIZE + ACE_OS::strlen (this->token_name_) + 1 - + ACE_OS::strlen (this->client_id_) + 1 - + 1; + + ACE_OS::strlen (this->client_id_) + 1 + + 1; // Make sure the message was correctly received and framed. return this->length () == data_size ? 0 : -1; @@ -94,7 +96,7 @@ ACE_Token_Request::dump (void) const #if defined (ACE_HAS_DUMP) ACE_DEBUG ((LM_DEBUG, ACE_BEGIN_DUMP, this)); ACE_DEBUG ((LM_DEBUG, ACE_LIB_TEXT ("*******\nlength = %d\ntoken name = %s\nclient id = %s\n"), - this->length (), this->token_name (), this->client_id ())); + this->length (), this->token_name (), this->client_id ())); ACE_DEBUG ((LM_DEBUG, ACE_LIB_TEXT ("type = "))); if (this->token_type () == ACE_Tokens::MUTEX) @@ -102,9 +104,9 @@ ACE_Token_Request::dump (void) const else // == ACE_Tokens::RWLOCK { if (this->proxy_type () == ACE_RW_Token::READER) - ACE_DEBUG ((LM_DEBUG, ACE_LIB_TEXT ("RLOCK\n"))); + ACE_DEBUG ((LM_DEBUG, ACE_LIB_TEXT ("RLOCK\n"))); else // == WRITER - ACE_DEBUG ((LM_DEBUG, ACE_LIB_TEXT ("WLOCK\n"))); + ACE_DEBUG ((LM_DEBUG, ACE_LIB_TEXT ("WLOCK\n"))); } ACE_DEBUG ((LM_DEBUG, ACE_LIB_TEXT ("operation = "))); @@ -129,7 +131,7 @@ ACE_Token_Request::dump (void) const else { ACE_DEBUG ((LM_DEBUG, ACE_LIB_TEXT ("waiting for %d secs and %d usecs\n"), - this->options ().timeout ().sec (), this->options ().timeout ().usec ())); + this->options ().timeout ().sec (), this->options ().timeout ().usec ())); } ACE_DEBUG ((LM_DEBUG, ACE_END_DUMP)); #endif /* ACE_HAS_DUMP */ @@ -174,9 +176,11 @@ ACE_Token_Reply::dump (void) const { #if defined (ACE_HAS_DUMP) ACE_DEBUG ((LM_DEBUG, ACE_LIB_TEXT ("*******\nlength = %d\nerrnum = %d"), - this->length (), this->errnum ())); + this->length (), this->errnum ())); ACE_DEBUG ((LM_DEBUG, ACE_LIB_TEXT ("arg = %d"), this->arg ())); #endif /* ACE_HAS_DUMP */ } +ACE_END_VERSIONED_NAMESPACE_DECL + #endif /* ACE_HAS_TOKENS_LIBRARY */ diff --git a/ace/Token_Request_Reply.h b/ace/Token_Request_Reply.h index 86f516a0203..167db0289f5 100644 --- a/ace/Token_Request_Reply.h +++ b/ace/Token_Request_Reply.h @@ -1,4 +1,4 @@ -/* -*- C++ -*- */ +// -*- C++ -*- //============================================================================= /** @@ -28,6 +28,8 @@ #if defined (ACE_HAS_TOKENS_LIBRARY) +ACE_BEGIN_VERSIONED_NAMESPACE_DECL + /// Specifies the size of the fixed length portion of /// the Transfer structure in ACE_Token_Request #define ACE_TOKEN_REQUEST_HEADER_SIZE 40 @@ -256,11 +258,13 @@ private: } transfer_; }; -#endif /* ACE_HAS_TOKENS_LIBRARY */ +ACE_END_VERSIONED_NAMESPACE_DECL #if defined (__ACE_INLINE__) #include "ace/Token_Request_Reply.inl" #endif /* __ACE_INLINE__ */ +#endif /* ACE_HAS_TOKENS_LIBRARY */ + #include /**/ "ace/post.h" #endif /* ACE_TOKEN_REQUEST_REPLY_H */ diff --git a/ace/Token_Request_Reply.inl b/ace/Token_Request_Reply.inl index e1c8ace3ad5..5ec19569adc 100644 --- a/ace/Token_Request_Reply.inl +++ b/ace/Token_Request_Reply.inl @@ -1,8 +1,11 @@ -/* -*- C++ -*- */ +// -*- C++ -*- +// // $Id$ #if defined (ACE_HAS_TOKENS_LIBRARY) +ACE_BEGIN_VERSIONED_NAMESPACE_DECL + // = Set/get the length of the encoded/decoded message. ACE_INLINE ACE_UINT32 @@ -11,7 +14,7 @@ ACE_Token_Request::length (void) const return ntohl (this->transfer_.length_); } -ACE_INLINE void +ACE_INLINE void ACE_Token_Request::length (ACE_UINT32 l) { this->transfer_.length_ = htonl (l); @@ -24,7 +27,7 @@ ACE_Token_Request::token_type (void) const return (int) ntohl (this->transfer_.token_type_); } -ACE_INLINE void +ACE_INLINE void ACE_Token_Request::token_type (int t) { this->transfer_.token_type_ = htonl ((ACE_UINT32) t); @@ -50,33 +53,33 @@ ACE_Token_Request::operation_type (void) const return ntohl (this->transfer_.operation_type_); } -ACE_INLINE void +ACE_INLINE void ACE_Token_Request::operation_type (ACE_UINT32 t) { this->transfer_.operation_type_ = htonl (t); } // = Set/get the requeue position -ACE_INLINE ACE_UINT32 +ACE_INLINE ACE_UINT32 ACE_Token_Request::requeue_position (void) const { return ntohl (this->transfer_.requeue_position_); } -ACE_INLINE void +ACE_INLINE void ACE_Token_Request::requeue_position (ACE_UINT32 rq) { this->transfer_.requeue_position_ = htonl (rq); } // = Set/get the requeue position -ACE_INLINE ACE_UINT32 +ACE_INLINE ACE_UINT32 ACE_Token_Request::notify (void) const { return ntohl (this->transfer_.notify_); } -ACE_INLINE void +ACE_INLINE void ACE_Token_Request::notify (ACE_UINT32 rq) { this->transfer_.notify_ = htonl (rq); @@ -89,7 +92,7 @@ ACE_Token_Request::options (void) const return (ACE_Synch_Options &) options_; } -ACE_INLINE void +ACE_INLINE void ACE_Token_Request::options (const ACE_Synch_Options &opt) { // fight the friggin const from hell @@ -115,8 +118,8 @@ ACE_Token_Request::token_name (void) const return token_name_; } -ACE_INLINE void -ACE_Token_Request::token_name (const ACE_TCHAR *token_name, +ACE_INLINE void +ACE_Token_Request::token_name (const ACE_TCHAR *token_name, const ACE_TCHAR *client_id) { size_t token_name_length = ACE_OS::strlen (token_name) + 1; // Add 1 for '\0'. @@ -127,17 +130,17 @@ ACE_Token_Request::token_name (const ACE_TCHAR *token_name, client_id_ = &this->token_name_[token_name_length + 1]; // Add 1 for ':'; client_id_[-1] = ACE_LIB_TEXT (':'); // Insert the ':' before this->clientId_. - (void) ACE_OS::memcpy (this->token_name_, - token_name, + (void) ACE_OS::memcpy (this->token_name_, + token_name, token_name_length * sizeof (ACE_TCHAR)); - (void) ACE_OS::memcpy (this->client_id_, - client_id, + (void) ACE_OS::memcpy (this->client_id_, + client_id, client_id_length * sizeof (ACE_TCHAR)); // Fixed length header size size_t len = ACE_TOKEN_REQUEST_HEADER_SIZE; - // ... then add in the amount of the variable-sized portion. + // ... then add in the amount of the variable-sized portion. len += token_name_length + client_id_length + 1; this->length (len); @@ -155,42 +158,44 @@ ACE_Token_Request::client_id (void) const // ************************************************************ // = Set/get the length of the encoded/decoded message. -ACE_INLINE ACE_UINT32 +ACE_INLINE ACE_UINT32 ACE_Token_Reply::length (void) const { return ntohl (this->transfer_.length_); } -ACE_INLINE void +ACE_INLINE void ACE_Token_Reply::length (ACE_UINT32 l) { this->transfer_.length_ = htonl (l); } // = Set/get the errno of a failed reply. -ACE_INLINE ACE_UINT32 +ACE_INLINE ACE_UINT32 ACE_Token_Reply::errnum (void) const { return ntohl (this->transfer_.errno_); } -ACE_INLINE void +ACE_INLINE void ACE_Token_Reply::errnum (ACE_UINT32 e) { this->transfer_.errno_ = htonl (e); } // = Set/get the length of the encoded/decoded message. -ACE_INLINE ACE_UINT32 +ACE_INLINE ACE_UINT32 ACE_Token_Reply::arg (void) const { return ntohl (this->transfer_.arg_); } -ACE_INLINE void +ACE_INLINE void ACE_Token_Reply::arg (ACE_UINT32 arg) { this->transfer_.arg_ = htonl (arg); } +ACE_END_VERSIONED_NAMESPACE_DECL + #endif /* ACE_HAS_TOKENS_LIBRARY */ diff --git a/ace/Trace.cpp b/ace/Trace.cpp index 5869f8bef45..63faa316d4e 100644 --- a/ace/Trace.cpp +++ b/ace/Trace.cpp @@ -16,6 +16,8 @@ ACE_RCSID (ace, #include "ace/Log_Msg.h" #include "ace/Object_Manager_Base.h" +ACE_BEGIN_VERSIONED_NAMESPACE_DECL + // = Static initialization. // Keeps track of how far to indent per trace call. @@ -131,3 +133,5 @@ ACE_Trace::~ACE_Trace (void) } } } + +ACE_END_VERSIONED_NAMESPACE_DECL diff --git a/ace/Trace.h b/ace/Trace.h index 67979f0287f..c473ee14014 100644 --- a/ace/Trace.h +++ b/ace/Trace.h @@ -21,6 +21,8 @@ # pragma once #endif /* ACE_LACKS_PRAGMA_ONCE */ +ACE_BEGIN_VERSIONED_NAMESPACE_DECL + /** * @class ACE_Trace * @@ -87,6 +89,8 @@ private: }; }; +ACE_END_VERSIONED_NAMESPACE_DECL + #include /**/ "ace/post.h" #endif /* ACE_TRACE_H */ diff --git a/ace/Typed_SV_Message.cpp b/ace/Typed_SV_Message.cpp index 3062952d2b4..79f931b77df 100644 --- a/ace/Typed_SV_Message.cpp +++ b/ace/Typed_SV_Message.cpp @@ -1,8 +1,8 @@ -// Typed_SV_Message.cpp // $Id$ -#ifndef ACE_TYPED_SV_MESSAGE_C -#define ACE_TYPED_SV_MESSAGE_C +#ifndef ACE_TYPED_SV_MESSAGE_CPP +#define ACE_TYPED_SV_MESSAGE_CPP + #include "ace/Typed_SV_Message.h" #if !defined (ACE_LACKS_PRAGMA_ONCE) @@ -13,7 +13,7 @@ #include "ace/Typed_SV_Message.inl" #endif /* __ACE_INLINE__ */ -ACE_RCSID(ace, Typed_SV_Message, "$Id$") +ACE_BEGIN_VERSIONED_NAMESPACE_DECL ACE_ALLOC_HOOK_DEFINE(ACE_Typed_SV_Message) @@ -25,4 +25,6 @@ ACE_Typed_SV_Message<T>::dump (void) const #endif /* ACE_HAS_DUMP */ } -#endif /* ACE_TYPED_SV_MESSAGE_C */ +ACE_END_VERSIONED_NAMESPACE_DECL + +#endif /* ACE_TYPED_SV_MESSAGE_CPP */ diff --git a/ace/Typed_SV_Message.h b/ace/Typed_SV_Message.h index 178cdfb8340..e88ddd6bf00 100644 --- a/ace/Typed_SV_Message.h +++ b/ace/Typed_SV_Message.h @@ -22,6 +22,8 @@ # pragma once #endif /* ACE_LACKS_PRAGMA_ONCE */ +ACE_BEGIN_VERSIONED_NAMESPACE_DECL + /** * @class ACE_Typed_SV_Message * @@ -86,6 +88,8 @@ private: T data_; }; +ACE_END_VERSIONED_NAMESPACE_DECL + #if defined (__ACE_INLINE__) #include "ace/Typed_SV_Message.inl" #endif /* __ACE_INLINE__ */ diff --git a/ace/Typed_SV_Message.inl b/ace/Typed_SV_Message.inl index a2dde0af39e..00ff07109ac 100644 --- a/ace/Typed_SV_Message.inl +++ b/ace/Typed_SV_Message.inl @@ -1,13 +1,16 @@ -/* -*- C++ -*- */ +// -*- C++ -*- +// // $Id$ #include "ace/config-all.h" #include "ace/Global_Macros.h" +ACE_BEGIN_VERSIONED_NAMESPACE_DECL + template <class T> ACE_INLINE -ACE_Typed_SV_Message<T>::ACE_Typed_SV_Message (long t, - int l, - int m) +ACE_Typed_SV_Message<T>::ACE_Typed_SV_Message (long t, + int l, + int m) : type_ (t) { ACE_TRACE ("ACE_Typed_SV_Message<T>::ACE_Typed_SV_Message"); @@ -16,10 +19,10 @@ ACE_Typed_SV_Message<T>::ACE_Typed_SV_Message (long t, } template <class T> ACE_INLINE -ACE_Typed_SV_Message<T>::ACE_Typed_SV_Message (const T &d, - long t, - int l, - int m) +ACE_Typed_SV_Message<T>::ACE_Typed_SV_Message (const T &d, + long t, + int l, + int m) : type_ (t), data_ (d) { @@ -90,3 +93,4 @@ ACE_Typed_SV_Message<T>::data (const T &d) this->data_ = d; } +ACE_END_VERSIONED_NAMESPACE_DECL diff --git a/ace/Typed_SV_Message_Queue.cpp b/ace/Typed_SV_Message_Queue.cpp index c1d6bb6de39..7fc2b0fd38d 100644 --- a/ace/Typed_SV_Message_Queue.cpp +++ b/ace/Typed_SV_Message_Queue.cpp @@ -1,8 +1,7 @@ -// Typed_SV_Message_Queue.cpp // $Id$ -#ifndef ACE_TYPED_SV_MESSAGE_QUEUE_C -#define ACE_TYPED_SV_MESSAGE_QUEUE_C +#ifndef ACE_TYPED_SV_MESSAGE_QUEUE_CPP +#define ACE_TYPED_SV_MESSAGE_QUEUE_CPP #include "ace/Typed_SV_Message.h" @@ -17,7 +16,7 @@ #include "ace/Typed_SV_Message_Queue.inl" #endif /* __ACE_INLINE__ */ -ACE_RCSID(ace, Typed_SV_Message_Queue, "$Id$") +ACE_BEGIN_VERSIONED_NAMESPACE_DECL ACE_ALLOC_HOOK_DEFINE(ACE_Typed_SV_Message_Queue) @@ -52,4 +51,6 @@ ACE_Typed_SV_Message_Queue<T>::~ACE_Typed_SV_Message_Queue (void) ACE_TRACE ("ACE_Typed_SV_Message_Queue<T>::~ACE_Typed_SV_Message_Queue"); } -#endif /* ACE_TYPED_SV_MESSAGE_QUEUE_C */ +ACE_END_VERSIONED_NAMESPACE_DECL + +#endif /* ACE_TYPED_SV_MESSAGE_QUEUE_CPP */ diff --git a/ace/Typed_SV_Message_Queue.h b/ace/Typed_SV_Message_Queue.h index 6c486197450..f7c2c066654 100644 --- a/ace/Typed_SV_Message_Queue.h +++ b/ace/Typed_SV_Message_Queue.h @@ -1,4 +1,4 @@ -/* -*- C++ -*- */ +// -*- C++ -*- //============================================================================= /** @@ -22,6 +22,8 @@ #include "ace/Typed_SV_Message.h" +ACE_BEGIN_VERSIONED_NAMESPACE_DECL + /** * @class ACE_Typed_SV_Message_Queue * @@ -72,6 +74,8 @@ private: ACE_SV_Message_Queue message_queue_; }; +ACE_END_VERSIONED_NAMESPACE_DECL + #if defined (__ACE_INLINE__) #include "ace/Typed_SV_Message_Queue.inl" #endif /* __ACE_INLINE__ */ diff --git a/ace/Typed_SV_Message_Queue.inl b/ace/Typed_SV_Message_Queue.inl index aad60fd2055..21ae9536501 100644 --- a/ace/Typed_SV_Message_Queue.inl +++ b/ace/Typed_SV_Message_Queue.inl @@ -1,14 +1,15 @@ -/* -*- C++ -*- */ +// -*- C++ -*- +// // $Id$ -// Typed_SV_Message_Queue.i - #include "ace/SV_Message_Queue.h" +ACE_BEGIN_VERSIONED_NAMESPACE_DECL + template <class T> ACE_INLINE int ACE_Typed_SV_Message_Queue<T>::open (key_t external_id, - int create, - int perms) + int create, + int perms) { ACE_TRACE ("ACE_Typed_SV_Message_Queue<T>::open"); return this->message_queue_.open (external_id, create, perms); @@ -25,7 +26,7 @@ ACE_Typed_SV_Message_Queue<T>::close (void) template <class T> ACE_INLINE int ACE_Typed_SV_Message_Queue<T>::recv (ACE_Typed_SV_Message<T> &mb, - int mflags) + int mflags) { ACE_TRACE ("ACE_Typed_SV_Message_Queue<T>::recv"); @@ -42,7 +43,7 @@ ACE_Typed_SV_Message_Queue<T>::recv (ACE_Typed_SV_Message<T> &mb, template <class T> ACE_INLINE int ACE_Typed_SV_Message_Queue<T>::send (const ACE_Typed_SV_Message<T> &mb, - int mflags) + int mflags) { ACE_TRACE ("ACE_Typed_SV_Message_Queue<T>::send"); return @@ -63,7 +64,7 @@ ACE_Typed_SV_Message_Queue<T>::remove (void) template <class T> ACE_INLINE int ACE_Typed_SV_Message_Queue<T>::control (int option, - void *arg) + void *arg) { ACE_TRACE ("ACE_Typed_SV_Message_Queue<T>::control"); @@ -75,3 +76,5 @@ ACE_Typed_SV_Message_Queue<T>::get_id (void) const { return this->message_queue_.get_id (); } + +ACE_END_VERSIONED_NAMESPACE_DECL diff --git a/ace/UNIX_Addr.cpp b/ace/UNIX_Addr.cpp index 4732c21cb6d..8dd3c52a36c 100644 --- a/ace/UNIX_Addr.cpp +++ b/ace/UNIX_Addr.cpp @@ -10,6 +10,8 @@ ACE_RCSID(ace, UNIX_Addr, "$Id$") #include "ace/UNIX_Addr.inl" #endif /* __ACE_INLINE__ */ +ACE_BEGIN_VERSIONED_NAMESPACE_DECL + ACE_ALLOC_HOOK_DEFINE(ACE_UNIX_Addr) // Set a pointer to the address. @@ -20,8 +22,8 @@ ACE_UNIX_Addr::set_addr (void *addr, int len) this->ACE_Addr::base_set (AF_UNIX, len); ACE_OS::memcpy ((void *) &this->unix_addr_, - (void *) addr, - len); + (void *) addr, + len); } // Return a pointer to the underlying address. @@ -107,7 +109,7 @@ int ACE_UNIX_Addr::set (const sockaddr_un *un, int len) { (void) ACE_OS::memset ((void *) &this->unix_addr_, 0, - sizeof this->unix_addr_); + sizeof this->unix_addr_); this->unix_addr_.sun_family = AF_UNIX; ACE_OS::strcpy (this->unix_addr_.sun_path, un->sun_path); this->base_set (AF_UNIX, len); @@ -123,17 +125,17 @@ int ACE_UNIX_Addr::set (const char rendezvous_point[]) { (void) ACE_OS::memset ((void *) &this->unix_addr_, - 0, - sizeof this->unix_addr_); + 0, + sizeof this->unix_addr_); this->unix_addr_.sun_family = AF_UNIX; - (void) ACE_OS::strsncpy (this->unix_addr_.sun_path, + (void) ACE_OS::strsncpy (this->unix_addr_.sun_path, rendezvous_point, sizeof this->unix_addr_.sun_path); this->ACE_Addr::base_set (AF_UNIX, - sizeof this->unix_addr_ - - sizeof (this->unix_addr_.sun_path) + - ACE_OS::strlen (this->unix_addr_.sun_path)); + sizeof this->unix_addr_ - + sizeof (this->unix_addr_.sun_path) + + ACE_OS::strlen (this->unix_addr_.sun_path)); return 0; } @@ -144,4 +146,6 @@ ACE_UNIX_Addr::ACE_UNIX_Addr (const char rendezvous_point[]) this->set (rendezvous_point); } +ACE_END_VERSIONED_NAMESPACE_DECL + #endif /* ACE_LACKS_UNIX_DOMAIN_SOCKETS */ diff --git a/ace/UNIX_Addr.h b/ace/UNIX_Addr.h index 36a040e4ec2..956bcc7d8cc 100644 --- a/ace/UNIX_Addr.h +++ b/ace/UNIX_Addr.h @@ -34,6 +34,8 @@ #include "ace/ACE.h" #include "ace/os_include/sys/os_un.h" +ACE_BEGIN_VERSIONED_NAMESPACE_DECL + /** * @class ACE_UNIX_Addr * @@ -107,10 +109,14 @@ private: sockaddr_un unix_addr_; }; +ACE_END_VERSIONED_NAMESPACE_DECL + #if defined (__ACE_INLINE__) #include "ace/UNIX_Addr.inl" #endif /* __ACE_INLINE__ */ #endif /* ACE_LACKS_UNIX_DOMAIN_SOCKETS */ + #include /**/ "ace/post.h" + #endif /* ACE_UNIX_ADDR_H */ diff --git a/ace/UNIX_Addr.inl b/ace/UNIX_Addr.inl index 966fc1118ea..34fa002ef34 100644 --- a/ace/UNIX_Addr.inl +++ b/ace/UNIX_Addr.inl @@ -8,6 +8,8 @@ #if !defined (ACE_LACKS_UNIX_DOMAIN_SOCKETS) +ACE_BEGIN_VERSIONED_NAMESPACE_DECL + #if defined (ACE_HAS_WCHAR) /// Creates an ACE_UNIX_Addr from a string. ACE_INLINE @@ -30,8 +32,8 @@ ACE_INLINE bool ACE_UNIX_Addr::operator == (const ACE_UNIX_Addr &sap) const { return ACE_OS::strncmp (this->unix_addr_.sun_path, - sap.unix_addr_.sun_path, - sizeof this->unix_addr_.sun_path) == 0; + sap.unix_addr_.sun_path, + sizeof this->unix_addr_.sun_path) == 0; } // Compare two addresses for inequality. @@ -39,7 +41,7 @@ ACE_UNIX_Addr::operator == (const ACE_UNIX_Addr &sap) const ACE_INLINE bool ACE_UNIX_Addr::operator != (const ACE_UNIX_Addr &sap) const { - return !((*this) == sap); // This is lazy, of course... ;-) + return !((*this) == sap); // This is lazy, of course... ;-) } // Return the path name used for the rendezvous point. @@ -50,4 +52,6 @@ ACE_UNIX_Addr::get_path_name (void) const return this->unix_addr_.sun_path; } +ACE_END_VERSIONED_NAMESPACE_DECL + #endif /* ACE_LACKS_UNIX_DOMAIN_SOCKETS */ diff --git a/ace/UPIPE_Acceptor.cpp b/ace/UPIPE_Acceptor.cpp index c7fa930f284..4b106b4a4be 100644 --- a/ace/UPIPE_Acceptor.cpp +++ b/ace/UPIPE_Acceptor.cpp @@ -1,4 +1,3 @@ -// UPIPE_Acceptor.cpp // $Id$ #include "ace/UPIPE_Acceptor.h" @@ -13,6 +12,8 @@ ACE_RCSID(ace, UPIPE_Acceptor, "$Id$") #include "ace/UPIPE_Acceptor.inl" #endif /* __ACE_INLINE__ */ +ACE_BEGIN_VERSIONED_NAMESPACE_DECL + ACE_ALLOC_HOOK_DEFINE(ACE_UPIPE_Acceptor) void @@ -40,7 +41,7 @@ ACE_UPIPE_Acceptor::~ACE_UPIPE_Acceptor (void) int ACE_UPIPE_Acceptor::open (const ACE_UPIPE_Addr &local_addr, - int reuse_addr) + int reuse_addr) { ACE_TRACE ("ACE_UPIPE_Acceptor::open"); return this->ACE_SPIPE_Acceptor::open (local_addr, reuse_addr); @@ -56,7 +57,7 @@ ACE_UPIPE_Acceptor::close (void) // General purpose routine for accepting new connections. ACE_UPIPE_Acceptor::ACE_UPIPE_Acceptor (const ACE_UPIPE_Addr &local_addr, - int reuse_addr) + int reuse_addr) : mb_ (sizeof (ACE_UPIPE_Stream *)) { ACE_TRACE ("ACE_UPIPE_Acceptor::ACE_UPIPE_Acceptor"); @@ -69,9 +70,9 @@ ACE_UPIPE_Acceptor::ACE_UPIPE_Acceptor (const ACE_UPIPE_Addr &local_addr, int ACE_UPIPE_Acceptor::accept (ACE_UPIPE_Stream &new_stream, - ACE_UPIPE_Addr *remote_addr, - ACE_Time_Value *timeout, - int restart, + ACE_UPIPE_Addr *remote_addr, + ACE_Time_Value *timeout, + int restart, int reset_new_handle) { ACE_TRACE ("ACE_UPIPE_Acceptor::accept"); @@ -80,7 +81,7 @@ ACE_UPIPE_Acceptor::accept (ACE_UPIPE_Stream &new_stream, ACE_SPIPE_Stream new_io; if (this->ACE_SPIPE_Acceptor::accept (new_io, remote_addr, - timeout, restart) == -1) + timeout, restart) == -1) return -1; else { @@ -100,20 +101,20 @@ ACE_UPIPE_Acceptor::accept (ACE_UPIPE_Stream &new_stream, // ACE_UPIPE_Stream to our ACE_UPIPE_Stream. if (ACE_OS::read (new_stream.get_handle (), - (char *) &remote_stream, - sizeof remote_stream) == -1) - ACE_ERROR ((LM_ERROR, - ACE_LIB_TEXT ("ACE_UPIPE_Acceptor: %p\n"), - ACE_LIB_TEXT ("read stream address failed"))); + (char *) &remote_stream, + sizeof remote_stream) == -1) + ACE_ERROR ((LM_ERROR, + ACE_LIB_TEXT ("ACE_UPIPE_Acceptor: %p\n"), + ACE_LIB_TEXT ("read stream address failed"))); else if (new_stream.stream_.link (remote_stream->stream_) == -1) - ACE_ERROR ((LM_ERROR, - ACE_LIB_TEXT ("ACE_UPIPE_Acceptor: %p\n"), - ACE_LIB_TEXT ("link streams failed"))); + ACE_ERROR ((LM_ERROR, + ACE_LIB_TEXT ("ACE_UPIPE_Acceptor: %p\n"), + ACE_LIB_TEXT ("link streams failed"))); // Send a message over the new streampipe to confirm acceptance. else if (new_stream.send (&mb_, 0) == -1) - ACE_ERROR ((LM_ERROR, - ACE_LIB_TEXT ("ACE_UPIPE_Acceptor: %p\n"), - ACE_LIB_TEXT ("linked stream.put failed"))); + ACE_ERROR ((LM_ERROR, + ACE_LIB_TEXT ("ACE_UPIPE_Acceptor: %p\n"), + ACE_LIB_TEXT ("linked stream.put failed"))); // Close down the new_stream at this point in order to conserve // handles. Note that we don't need the SPIPE connection @@ -123,4 +124,6 @@ ACE_UPIPE_Acceptor::accept (ACE_UPIPE_Stream &new_stream, } } +ACE_END_VERSIONED_NAMESPACE_DECL + #endif /* ACE_HAS_THREADS */ diff --git a/ace/UPIPE_Acceptor.h b/ace/UPIPE_Acceptor.h index 0f51b3253bb..b7b94179cb6 100644 --- a/ace/UPIPE_Acceptor.h +++ b/ace/UPIPE_Acceptor.h @@ -1,4 +1,4 @@ -/* -*- C++ -*- */ +// -*- C++ -*- //============================================================================= /** @@ -22,10 +22,12 @@ # pragma once #endif /* ACE_LACKS_PRAGMA_ONCE */ +#if defined (ACE_HAS_THREADS) + #include "ace/SPIPE_Acceptor.h" #include "ace/Thread_Manager.h" -#if defined (ACE_HAS_THREADS) +ACE_BEGIN_VERSIONED_NAMESPACE_DECL /** * @class ACE_UPIPE_Acceptor @@ -84,10 +86,14 @@ private: ACE_Message_Block mb_; }; +ACE_END_VERSIONED_NAMESPACE_DECL + #if defined (__ACE_INLINE__) #include "ace/UPIPE_Acceptor.inl" #endif /* __ACE_INLINE__ */ #endif /* ACE_HAS_THREADS */ + #include /**/ "ace/post.h" + #endif /* ACE_UPIPE_ACCEPTOR_H */ diff --git a/ace/UPIPE_Acceptor.inl b/ace/UPIPE_Acceptor.inl index 0e28e250ab0..731d6be4a6c 100644 --- a/ace/UPIPE_Acceptor.inl +++ b/ace/UPIPE_Acceptor.inl @@ -1,9 +1,14 @@ -/* -*- C++ -*- */ +// -*- C++ -*- +// // $Id$ +ACE_BEGIN_VERSIONED_NAMESPACE_DECL + ACE_INLINE int ACE_UPIPE_Acceptor::remove (void) { ACE_TRACE ("ACE_UPIPE_Acceptor::remove"); return this->ACE_SPIPE_Acceptor::remove (); } + +ACE_END_VERSIONED_NAMESPACE_DECL diff --git a/ace/UPIPE_Addr.h b/ace/UPIPE_Addr.h index 2b4d3040527..75f948c6bf5 100644 --- a/ace/UPIPE_Addr.h +++ b/ace/UPIPE_Addr.h @@ -1,5 +1,4 @@ -/* -*- C++ -*- */ - +// -*- C++ -*- //============================================================================= /** @@ -14,6 +13,7 @@ #ifndef ACE_UPIPE_ADDR_H #define ACE_UPIPE_ADDR_H + #include /**/ "ace/pre.h" #include "ace/SPIPE_Addr.h" @@ -22,7 +22,12 @@ # pragma once #endif /* ACE_LACKS_PRAGMA_ONCE */ +ACE_BEGIN_VERSIONED_NAMESPACE_DECL + typedef ACE_SPIPE_Addr ACE_UPIPE_Addr; +ACE_END_VERSIONED_NAMESPACE_DECL + #include /**/ "ace/post.h" + #endif /* ACE_UPIPE_ADDR_H */ diff --git a/ace/UPIPE_Connector.cpp b/ace/UPIPE_Connector.cpp index 455d982e993..ef7e622739e 100644 --- a/ace/UPIPE_Connector.cpp +++ b/ace/UPIPE_Connector.cpp @@ -1,4 +1,3 @@ -// UPIPE_Connector.cpp // $Id$ #include "ace/UPIPE_Connector.h" @@ -7,12 +6,15 @@ ACE_RCSID(ace, UPIPE_Connector, "$Id$") #if defined (ACE_HAS_THREADS) +#include "ace/Handle_Ops.h" #include "ace/OS_NS_unistd.h" #if !defined (__ACE_INLINE__) #include "ace/UPIPE_Connector.inl" #endif /* __ACE_INLINE__ */ +ACE_BEGIN_VERSIONED_NAMESPACE_DECL + ACE_ALLOC_HOOK_DEFINE(ACE_UPIPE_Connector) void @@ -45,7 +47,7 @@ ACE_UPIPE_Connector::connect (ACE_UPIPE_Stream &new_stream, flags, perms); if (handle == ACE_INVALID_HANDLE) - return -1; + return -1; #if !defined (ACE_WIN32) else if (ACE_OS::isastream (handle) != 1) return -1; @@ -92,4 +94,7 @@ ACE_UPIPE_Connector::connect (ACE_UPIPE_Stream &new_stream, return result; } } + +ACE_END_VERSIONED_NAMESPACE_DECL + #endif /* ACE_HAS_THREADS */ diff --git a/ace/UPIPE_Connector.h b/ace/UPIPE_Connector.h index b98ab643c92..c2778f82a11 100644 --- a/ace/UPIPE_Connector.h +++ b/ace/UPIPE_Connector.h @@ -1,4 +1,4 @@ -/* -*- C++ -*- */ +// -*- C++ -*- //============================================================================= /** @@ -21,10 +21,10 @@ # pragma once #endif /* ACE_LACKS_PRAGMA_ONCE */ -#include "ace/SPIPE_Stream.h" - #if defined (ACE_HAS_THREADS) +ACE_BEGIN_VERSIONED_NAMESPACE_DECL + /** * @class ACE_UPIPE_Connector * @@ -102,10 +102,14 @@ public: ACE_ALLOC_HOOK_DECLARE; }; +ACE_END_VERSIONED_NAMESPACE_DECL + #if defined (__ACE_INLINE__) #include "ace/UPIPE_Connector.inl" #endif /* __ACE_INLINE__ */ #endif /* ACE_HAS_THREADS */ + #include /**/ "ace/post.h" + #endif /* ACE_UPIPE_CONNECTOR_H */ diff --git a/ace/UPIPE_Connector.inl b/ace/UPIPE_Connector.inl index 980d8a28164..b45134f1067 100644 --- a/ace/UPIPE_Connector.inl +++ b/ace/UPIPE_Connector.inl @@ -1,6 +1,9 @@ -/* -*- C++ -*- */ +// -*- C++ -*- +// // $Id$ +ACE_BEGIN_VERSIONED_NAMESPACE_DECL + // Creates a Local ACE_UPIPE. ACE_INLINE ACE_UPIPE_Connector::ACE_UPIPE_Connector (ACE_UPIPE_Stream &new_stream, @@ -13,7 +16,7 @@ ACE_UPIPE_Connector::ACE_UPIPE_Connector (ACE_UPIPE_Stream &new_stream, { ACE_TRACE ("ACE_UPIPE_Connector::ACE_UPIPE_Connector"); if (this->connect (new_stream, addr, timeout, local_sap, - reuse_addr, flags, perms) == -1 + reuse_addr, flags, perms) == -1 && timeout != 0 && !(errno == EWOULDBLOCK || errno == ETIME)) ACE_ERROR ((LM_ERROR, ACE_LIB_TEXT ("address %s, %p\n"), @@ -22,9 +25,10 @@ ACE_UPIPE_Connector::ACE_UPIPE_Connector (ACE_UPIPE_Stream &new_stream, } ACE_INLINE int -ACE_UPIPE_Connector::reset_new_handle (ACE_HANDLE handle) +ACE_UPIPE_Connector::reset_new_handle (ACE_HANDLE /* handle */) { - ACE_UNUSED_ARG (handle); // Nothing to do here since the handle is not a socket return 0; } + +ACE_END_VERSIONED_NAMESPACE_DECL diff --git a/ace/UPIPE_Stream.cpp b/ace/UPIPE_Stream.cpp index 4df8d5fc547..53b170d23cd 100644 --- a/ace/UPIPE_Stream.cpp +++ b/ace/UPIPE_Stream.cpp @@ -1,17 +1,18 @@ -// UPIPE_Stream.cpp // $Id$ #include "ace/UPIPE_Stream.h" -#include "ace/OS_NS_string.h" ACE_RCSID(ace, UPIPE_Stream, "$Id$") #if defined (ACE_HAS_THREADS) +#include "ace/OS_NS_string.h" + #if !defined (__ACE_INLINE__) #include "ace/UPIPE_Stream.inl" #endif /* __ACE_INLINE__ */ +ACE_BEGIN_VERSIONED_NAMESPACE_DECL ACE_ALLOC_HOOK_DEFINE(ACE_UPIPE_Stream) @@ -225,5 +226,6 @@ ACE_UPIPE_Stream::recv_n (char *buf, return bytes_read; } +ACE_END_VERSIONED_NAMESPACE_DECL #endif /* ACE_HAS_THREADS */ diff --git a/ace/UPIPE_Stream.h b/ace/UPIPE_Stream.h index f9002d2c255..1d8be43c910 100644 --- a/ace/UPIPE_Stream.h +++ b/ace/UPIPE_Stream.h @@ -22,11 +22,13 @@ # pragma once #endif /* ACE_LACKS_PRAGMA_ONCE */ +#if defined (ACE_HAS_THREADS) + #include "ace/SPIPE.h" #include "ace/Message_Queue.h" #include "ace/UPIPE_Addr.h" -#if defined (ACE_HAS_THREADS) +ACE_BEGIN_VERSIONED_NAMESPACE_DECL // Use a typedef to make life easier later on. typedef ACE_Stream<ACE_SYNCH> MT_Stream; @@ -127,10 +129,14 @@ private: #endif /* ACE_MT_SAFE */ }; +ACE_END_VERSIONED_NAMESPACE_DECL + #if defined (__ACE_INLINE__) #include "ace/UPIPE_Stream.inl" #endif /* __ACE_INLINE__ */ #endif /* ACE_HAS_THREADS */ + #include /**/ "ace/post.h" + #endif /*ACE_UPIPE_STREAM_H */ diff --git a/ace/UPIPE_Stream.inl b/ace/UPIPE_Stream.inl index 9bd3912d1ba..3a33d287b0b 100644 --- a/ace/UPIPE_Stream.inl +++ b/ace/UPIPE_Stream.inl @@ -1,6 +1,9 @@ -/* -*- C++ -*- */ +// -*- C++ -*- +// // $Id$ +ACE_BEGIN_VERSIONED_NAMESPACE_DECL + ACE_INLINE ACE_HANDLE ACE_UPIPE_Stream::get_handle (void) const { @@ -8,3 +11,4 @@ ACE_UPIPE_Stream::get_handle (void) const return this->ACE_SPIPE::get_handle (); } +ACE_END_VERSIONED_NAMESPACE_DECL diff --git a/ace/UUID.cpp b/ace/UUID.cpp index 0873cc7d903..5342fd6be7d 100644 --- a/ace/UUID.cpp +++ b/ace/UUID.cpp @@ -20,6 +20,8 @@ ACE_RCSID (ace, "$Id$") +ACE_BEGIN_VERSIONED_NAMESPACE_DECL + namespace ACE_Utils { @@ -487,3 +489,5 @@ template class ACE_Singleton <ACE_Utils::UUID_Generator, ACE_SYNCH_MUTEX>; template ACE_Singleton<ACE_Utils::UUID_Generator, ACE_SYNCH_MUTEX> * ACE_Singleton<ACE_Utils::UUID_Generator, ACE_SYNCH_MUTEX>::singleton_; #endif /* ACE_HAS_EXPLICIT_TEMPLATE_INSTANTIATION */ + +ACE_END_VERSIONED_NAMESPACE_DECL diff --git a/ace/UUID.h b/ace/UUID.h index 9882c24cef5..9a1a9cce956 100644 --- a/ace/UUID.h +++ b/ace/UUID.h @@ -1,4 +1,5 @@ -/* -*- C++ -*- */ +// -*- C++ -*- + //============================================================================= /** * @file UUID.h @@ -24,6 +25,8 @@ #include "ace/Singleton.h" #include "ace/Synch_Traits.h" +ACE_BEGIN_VERSIONED_NAMESPACE_DECL + namespace ACE_Utils { /// Class to hold a MAC address @@ -215,10 +218,12 @@ namespace ACE_Utils int destroy_lock_; }; - typedef ACE_Singleton <UUID_Generator, ACE_SYNCH_MUTEX> UUID_GENERATOR; + typedef ACE_Singleton<UUID_Generator, ACE_SYNCH_MUTEX> UUID_GENERATOR; } +ACE_END_VERSIONED_NAMESPACE_DECL + #if defined (__ACE_INLINE__) #include "ace/UUID.inl" #endif /* __ACE_INLINE__ */ diff --git a/ace/UUID.inl b/ace/UUID.inl index 0bd9fc053c6..7eb8dd323de 100644 --- a/ace/UUID.inl +++ b/ace/UUID.inl @@ -1,5 +1,8 @@ -//$Id$ // -*- C++ -*- +// +//$Id$ + +ACE_BEGIN_VERSIONED_NAMESPACE_DECL namespace ACE_Utils { @@ -194,3 +197,5 @@ namespace ACE_Utils // return false; // } } + +ACE_END_VERSIONED_NAMESPACE_DECL diff --git a/ace/Unbounded_Queue.cpp b/ace/Unbounded_Queue.cpp index 332fddb4428..37060bc9633 100644 --- a/ace/Unbounded_Queue.cpp +++ b/ace/Unbounded_Queue.cpp @@ -1,7 +1,7 @@ // $Id$ -#ifndef ACE_UNBOUNDED_QUEUE_C -#define ACE_UNBOUNDED_QUEUE_C +#ifndef ACE_UNBOUNDED_QUEUE_CPP +#define ACE_UNBOUNDED_QUEUE_CPP #include "ace/Unbounded_Queue.h" @@ -17,7 +17,7 @@ #include "ace/Log_Msg.h" #include "ace/os_include/os_errno.h" -ACE_RCSID(ace, Unbounded_Queue, "$Id$") +ACE_BEGIN_VERSIONED_NAMESPACE_DECL ACE_ALLOC_HOOK_DEFINE(ACE_Unbounded_Queue) @@ -429,4 +429,6 @@ ACE_Unbounded_Queue_Iterator<T>::next (T *&item) } } -#endif /* ACE_UNBOUNDED_QUEUE_C */ +ACE_END_VERSIONED_NAMESPACE_DECL + +#endif /* ACE_UNBOUNDED_QUEUE_CPP */ diff --git a/ace/Unbounded_Queue.h b/ace/Unbounded_Queue.h index fca8b344d30..39314168da8 100644 --- a/ace/Unbounded_Queue.h +++ b/ace/Unbounded_Queue.h @@ -1,4 +1,4 @@ -/* -*- C++ -*- */ +// -*- C++ -*- //============================================================================= /** @@ -23,6 +23,8 @@ // For size_t under Chorus #include "ace/os_include/os_stddef.h" +ACE_BEGIN_VERSIONED_NAMESPACE_DECL + class ACE_Allocator; template <class T> @@ -278,6 +280,8 @@ protected: ACE_Allocator *allocator_; }; +ACE_END_VERSIONED_NAMESPACE_DECL + #if defined (__ACE_INLINE__) #include "ace/Unbounded_Queue.inl" #endif /* __ACE_INLINE__ */ diff --git a/ace/Unbounded_Queue.inl b/ace/Unbounded_Queue.inl index ea552e7d3d8..35bb7fb9cdf 100644 --- a/ace/Unbounded_Queue.inl +++ b/ace/Unbounded_Queue.inl @@ -1,5 +1,9 @@ +// -*- C++ -*- +// // $Id$ +ACE_BEGIN_VERSIONED_NAMESPACE_DECL + template <class T> ACE_INLINE size_t ACE_Unbounded_Queue<T>::size (void) const { @@ -19,3 +23,5 @@ ACE_Unbounded_Queue<T>::is_full (void) const // ACE_TRACE ("ACE_Unbounded_Queue<T>::is_full"); return 0; // We should implement a "node of last resort for this..." } + +ACE_END_VERSIONED_NAMESPACE_DECL diff --git a/ace/Unbounded_Set.cpp b/ace/Unbounded_Set.cpp index 54ffa30a0f2..d86c91095ff 100644 --- a/ace/Unbounded_Set.cpp +++ b/ace/Unbounded_Set.cpp @@ -1,7 +1,7 @@ // $Id$ -#ifndef ACE_UNBOUNDED_SET_C -#define ACE_UNBOUNDED_SET_C +#ifndef ACE_UNBOUNDED_SET_CPP +#define ACE_UNBOUNDED_SET_CPP #include "ace/Unbounded_Set.h" #include "ace/Malloc_Base.h" @@ -15,7 +15,7 @@ #include "ace/Unbounded_Set.inl" #endif /* __ACE_INLINE__ */ -ACE_RCSID(ace, Unbounded_Set, "$Id$") +ACE_BEGIN_VERSIONED_NAMESPACE_DECL ACE_ALLOC_HOOK_DEFINE(ACE_Unbounded_Set) @@ -440,11 +440,13 @@ ACE_Unbounded_Set_Const_Iterator<T>::operator* (void) //ACE_TRACE ("ACE_Unbounded_Set_Const_Iterator<T>::operator*"); T *retv = 0; - int result = this->next (retv); + int const result = this->next (retv); ACE_ASSERT (result != 0); ACE_UNUSED_ARG (result); return *retv; } -#endif /* ACE_UNBOUNDED_SET_C */ +ACE_END_VERSIONED_NAMESPACE_DECL + +#endif /* ACE_UNBOUNDED_SET_CPP */ diff --git a/ace/Unbounded_Set.h b/ace/Unbounded_Set.h index d4f2a957cdd..963c6d80f00 100644 --- a/ace/Unbounded_Set.h +++ b/ace/Unbounded_Set.h @@ -1,4 +1,4 @@ -/* -*- C++ -*- */ +// -*- C++ -*- //============================================================================= /** @@ -21,6 +21,8 @@ # pragma once #endif /* ACE_LACKS_PRAGMA_ONCE */ +ACE_BEGIN_VERSIONED_NAMESPACE_DECL + class ACE_Allocator; /** @@ -299,6 +301,8 @@ private: ACE_Allocator *allocator_; }; +ACE_END_VERSIONED_NAMESPACE_DECL + #if defined (__ACE_INLINE__) #include "ace/Unbounded_Set.inl" #endif /* __ACE_INLINE__ */ diff --git a/ace/Unbounded_Set.inl b/ace/Unbounded_Set.inl index 9aad60c4a08..363fe6e4a6d 100644 --- a/ace/Unbounded_Set.inl +++ b/ace/Unbounded_Set.inl @@ -1,8 +1,11 @@ -/* -*- C++ -*- */ +// -*- C++ -*- +// // $Id$ #include "ace/Global_Macros.h" +ACE_BEGIN_VERSIONED_NAMESPACE_DECL + template <class T> ACE_INLINE int ACE_Unbounded_Set<T>::is_empty (void) const { @@ -16,3 +19,5 @@ ACE_Unbounded_Set<T>::is_full (void) const ACE_TRACE ("ACE_Unbounded_Set<T>::is_full"); return 0; // We should implement a "node of last resort for this..." } + +ACE_END_VERSIONED_NAMESPACE_DECL diff --git a/ace/Value_Ptr.h b/ace/Value_Ptr.h index 4c05f288409..b652183ef43 100644 --- a/ace/Value_Ptr.h +++ b/ace/Value_Ptr.h @@ -18,6 +18,8 @@ #include <algorithm> +ACE_BEGIN_VERSIONED_NAMESPACE_DECL + namespace ACE { /** @@ -158,4 +160,6 @@ namespace ACE } +ACE_END_VERSIONED_NAMESPACE_DECL + #endif /* ACE_VALUE_PTR_H */ diff --git a/ace/Vector_T.cpp b/ace/Vector_T.cpp index 2dcbd96f67c..adf9727c6ff 100644 --- a/ace/Vector_T.cpp +++ b/ace/Vector_T.cpp @@ -1,7 +1,7 @@ // $Id$ -#ifndef ACE_VECTOR_T_C -#define ACE_VECTOR_T_C +#ifndef ACE_VECTOR_T_CPP +#define ACE_VECTOR_T_CPP #if !defined (ACE_LACKS_PRAGMA_ONCE) # pragma once @@ -13,13 +13,13 @@ #include "ace/Vector_T.inl" #endif /* __ACE_INLINE__ */ -ACE_RCSID(ace, Vector_T, "$Id$") +ACE_BEGIN_VERSIONED_NAMESPACE_DECL ACE_ALLOC_HOOK_DEFINE(ACE_Vector) template <class T, size_t DEFAULT_SIZE> void ACE_Vector<T, DEFAULT_SIZE>::resize (const size_t new_size, - const T& t) + const T& t) { ACE_Array<T>::size (new_size); if (new_size > length_) @@ -101,9 +101,9 @@ int compare(const ACE_Vector<T>& v1, // cout<<", V2["<<i<<"]="<<v2[i]; // cout<<": NOT EQUAL == "<<(v1[i]!=v2[i])<<endl; if (v1[i] != v2[i]) - { - return false; - } + { + return false; + } } // cout<<"compare() ====================>"<<endl; return true; @@ -111,9 +111,9 @@ int compare(const ACE_Vector<T>& v1, template<class T> int partial_compare(const ACE_Vector<T>& v1, - const ACE_Vector<T>& v2, - const size_t from_ndx, - const size_t to_ndx) + const ACE_Vector<T>& v2, + const size_t from_ndx, + const size_t to_ndx) { size_t last1 = v1.size () - 1; size_t last2 = v2.size () - 1; @@ -132,9 +132,9 @@ int partial_compare(const ACE_Vector<T>& v1, // cout<<", V2["<<i<<"]="<<v2[i]; // cout<<": NOT EQUAL == "<<(v1[i]!=v2[i])<<endl; if (v1[i] != v2[i]) - { - return false; - } + { + return false; + } } // cout<<"partial_compare() ====================>"<<endl; return true; @@ -160,4 +160,6 @@ ACE_Vector_Iterator<T, DEFAULT_SIZE>::next (T *&item) } } -#endif /* ACE_VECTOR_T_C */ +ACE_END_VERSIONED_NAMESPACE_DECL + +#endif /* ACE_VECTOR_T_CPP */ diff --git a/ace/Vector_T.h b/ace/Vector_T.h index c6e5b60b074..b82ea62b90e 100644 --- a/ace/Vector_T.h +++ b/ace/Vector_T.h @@ -22,10 +22,12 @@ # pragma once #endif /* ACE_LACKS_PRAGMA_ONCE */ +ACE_BEGIN_VERSIONED_NAMESPACE_DECL + /* * Default size for an ACE_Vector. */ -const size_t ACE_VECTOR_DEFAULT_SIZE = 32; +static const size_t ACE_VECTOR_DEFAULT_SIZE = 32; // Forward declaration. template <class T, size_t DEFAULT_SIZE> class ACE_Vector_Iterator; @@ -83,7 +85,7 @@ public: * default ACE allocator is used */ ACE_Vector (const size_t init_size = DEFAULT_SIZE, - ACE_Allocator* alloc = 0); + ACE_Allocator* alloc = 0); /** * Destructor. @@ -128,7 +130,7 @@ public: * initialization clause for this parameter). */ void resize (const size_t new_size, - const T& t); + const T& t); /** * Appends a new element to the vector ("push back"). If the @@ -222,9 +224,9 @@ protected: */ template<class T> int compare (const ACE_Vector<T>& v1, - const ACE_Vector<T>& v2, - const size_t from_ndx, - const size_t to_ndx); + const ACE_Vector<T>& v2, + const size_t from_ndx, + const size_t to_ndx); /** * Does a partial comparison of two vectors in the range of @@ -244,9 +246,9 @@ int compare (const ACE_Vector<T>& v1, template<class T> int partial_compare (const ACE_Vector<T>& v1, - const ACE_Vector<T>& v2, - const size_t from_ndx, - const size_t to_ndx); + const ACE_Vector<T>& v2, + const size_t from_ndx, + const size_t to_ndx); #endif /* 0 */ // **************************************************************** @@ -293,6 +295,8 @@ private: ACE_Vector<T, DEFAULT_SIZE> &vector_; }; +ACE_END_VERSIONED_NAMESPACE_DECL + #if defined (__ACE_INLINE__) #include "ace/Vector_T.inl" #endif /* __ACE_INLINE__ */ diff --git a/ace/Vector_T.inl b/ace/Vector_T.inl index a936c2bfe4d..aef981b447d 100644 --- a/ace/Vector_T.inl +++ b/ace/Vector_T.inl @@ -1,9 +1,12 @@ -/* -*- C++ -*- */ +// -*- C++ -*- +// // $Id$ +ACE_BEGIN_VERSIONED_NAMESPACE_DECL + template <class T, size_t DEFAULT_SIZE> ACE_INLINE ACE_Vector<T, DEFAULT_SIZE>::ACE_Vector (const size_t init_size, - ACE_Allocator* alloc) + ACE_Allocator* alloc) : ACE_Array<T> (init_size == 0 ? DEFAULT_SIZE : init_size, alloc) { length_ = 0; @@ -88,3 +91,5 @@ ACE_Vector_Iterator<T, DEFAULT_SIZE>::done (void) const return this->current_ >= vector_.size (); } + +ACE_END_VERSIONED_NAMESPACE_DECL diff --git a/ace/WFMO_Reactor.cpp b/ace/WFMO_Reactor.cpp index 2b3e3b86df5..3a343f8930f 100644 --- a/ace/WFMO_Reactor.cpp +++ b/ace/WFMO_Reactor.cpp @@ -18,6 +18,8 @@ ACE_RCSID(ace, WFMO_Reactor, "$Id$") #include "ace/Auto_Ptr.h" +ACE_BEGIN_VERSIONED_NAMESPACE_DECL + ACE_WFMO_Reactor_Handler_Repository::ACE_WFMO_Reactor_Handler_Repository (ACE_WFMO_Reactor &wfmo_reactor) : wfmo_reactor_ (wfmo_reactor) { @@ -2676,28 +2678,22 @@ ACE_WFMO_Reactor::resumable_handler (void) // No-op WinSOCK2 methods to help WFMO_Reactor compile #if !defined (ACE_HAS_WINSOCK2) || (ACE_HAS_WINSOCK2 == 0) int -WSAEventSelect (SOCKET s, - WSAEVENT hEventObject, - long lNetworkEvents) +WSAEventSelect (SOCKET /* s */, + WSAEVENT /* hEventObject */, + long /* lNetworkEvents */) { - ACE_UNUSED_ARG (s); - ACE_UNUSED_ARG (hEventObject); - ACE_UNUSED_ARG (lNetworkEvents); - return -1; } int -WSAEnumNetworkEvents (SOCKET s, - WSAEVENT hEventObject, - LPWSANETWORKEVENTS lpNetworkEvents) +WSAEnumNetworkEvents (SOCKET /* s */, + WSAEVENT /* hEventObject */, + LPWSANETWORKEVENTS /* lpNetworkEvents */) { - ACE_UNUSED_ARG (s); - ACE_UNUSED_ARG (hEventObject); - ACE_UNUSED_ARG (lpNetworkEvents); - return -1; } #endif /* !defined ACE_HAS_WINSOCK2 */ +ACE_END_VERSIONED_NAMESPACE_DECL + #endif /* ACE_WIN32 */ diff --git a/ace/WFMO_Reactor.h b/ace/WFMO_Reactor.h index 7be1525ea8a..a657e486fef 100644 --- a/ace/WFMO_Reactor.h +++ b/ace/WFMO_Reactor.h @@ -1,4 +1,4 @@ -/* -*- C++ -*- */ +// -*- C++ -*- //============================================================================= /** @@ -73,6 +73,8 @@ int WSAEnumNetworkEvents (SOCKET s, #endif /* !defined ACE_HAS_WINSOCK2 */ +ACE_BEGIN_VERSIONED_NAMESPACE_DECL + // Forward decl. class ACE_WFMO_Reactor; class ACE_Handle_Set; @@ -1342,6 +1344,8 @@ private: ACE_WFMO_Reactor &operator = (const ACE_WFMO_Reactor &); }; +ACE_END_VERSIONED_NAMESPACE_DECL + #if defined (__ACE_INLINE__) #include "ace/WFMO_Reactor.inl" #endif /* __ACE_INLINE__ */ diff --git a/ace/WFMO_Reactor.inl b/ace/WFMO_Reactor.inl index e8893728b3a..adf8ca96634 100644 --- a/ace/WFMO_Reactor.inl +++ b/ace/WFMO_Reactor.inl @@ -1,4 +1,5 @@ -/* -*- C++ -*- */ +// -*- C++ -*- +// // $Id$ #include "ace/Handle_Set.h" @@ -6,16 +7,15 @@ #include "ace/Thread.h" #include "ace/OS_NS_errno.h" +ACE_BEGIN_VERSIONED_NAMESPACE_DECL + /************************************************************/ ACE_INLINE int -ACE_Wakeup_All_Threads_Handler::handle_signal (int signum, - siginfo_t *siginfo, +ACE_Wakeup_All_Threads_Handler::handle_signal (int /* signum */, + siginfo_t * /* siginfo */, ucontext_t *) { - ACE_UNUSED_ARG (signum); - ACE_UNUSED_ARG (siginfo); - // This will get called when <WFMO_Reactor->wakeup_all_threads_> event // is signaled. There is nothing to be done here. // ACE_DEBUG ((LM_DEBUG, ACE_LIB_TEXT ("(%t) waking up to get updated handle set info\n"))); @@ -1168,3 +1168,5 @@ ACE_WFMO_Reactor_Handler_Repository::~ACE_WFMO_Reactor_Handler_Repository (void) } #endif /* ACE_WIN32 */ + +ACE_END_VERSIONED_NAMESPACE_DECL diff --git a/ace/WIN32_Asynch_IO.cpp b/ace/WIN32_Asynch_IO.cpp index 39e72b6f575..80b4b9f726a 100644 --- a/ace/WIN32_Asynch_IO.cpp +++ b/ace/WIN32_Asynch_IO.cpp @@ -17,6 +17,8 @@ ACE_RCSID (ace, #include "ace/OS_NS_unistd.h" #include "ace/OS_NS_sys_socket.h" +ACE_BEGIN_VERSIONED_NAMESPACE_DECL + size_t ACE_WIN32_Asynch_Result::bytes_transferred (void) const { @@ -3770,4 +3772,6 @@ template class ACE_Map_Reverse_Iterator<ACE_HANDLE, ACE_WIN32_Asynch_Connect_Res #endif /* ACE_HAS_EXPLICIT_TEMPLATE_INSTANTIATION */ +ACE_END_VERSIONED_NAMESPACE_DECL + #endif /* ACE_WIN32 || ACE_HAS_WINCE */ diff --git a/ace/WIN32_Asynch_IO.h b/ace/WIN32_Asynch_IO.h index f8683a7c24d..1e259ef9e95 100644 --- a/ace/WIN32_Asynch_IO.h +++ b/ace/WIN32_Asynch_IO.h @@ -1,4 +1,4 @@ -/* -*- C++ -*- */ +// -*- C++ -*- //============================================================================= /** @@ -41,6 +41,8 @@ #include "ace/Map_Manager.h" #include "ace/Null_Mutex.h" +ACE_BEGIN_VERSIONED_NAMESPACE_DECL + // Forward declaration class ACE_WIN32_Proactor; @@ -1927,6 +1929,8 @@ protected: ACE_WIN32_Asynch_Write_Dgram (void); }; +ACE_END_VERSIONED_NAMESPACE_DECL + #endif /* ACE_WIN32 && !ACE_HAS_WINCE */ #include /**/ "ace/post.h" #endif /* ACE_WIN32_ASYNCH_IO_H */ diff --git a/ace/WIN32_Proactor.cpp b/ace/WIN32_Proactor.cpp index 56bd9ceb779..d4e50430e23 100644 --- a/ace/WIN32_Proactor.cpp +++ b/ace/WIN32_Proactor.cpp @@ -12,6 +12,8 @@ #include "ace/OS_NS_errno.h" #include "ace/OS_NS_unistd.h" +ACE_BEGIN_VERSIONED_NAMESPACE_DECL + /** * @class ACE_WIN32_Wakeup_Completion * @@ -19,7 +21,7 @@ * ACE_Proactor interface to wake up all the threads blocking * for completions. */ -class ACE_Export ACE_WIN32_Wakeup_Completion : public ACE_WIN32_Asynch_Result +class ACE_WIN32_Wakeup_Completion : public ACE_WIN32_Asynch_Result { public: @@ -710,7 +712,7 @@ ACE_WIN32_Proactor::post_completion (ACE_WIN32_Asynch_Result *result) } // If Proactor event is valid, signal it - if (handle != ACE_INVALID_HANDLE + if (handle != ACE_INVALID_HANDLE && handle != 0) ACE_OS::event_signal (&handle); @@ -812,4 +814,6 @@ ACE_WIN32_Wakeup_Completion::complete (size_t /* bytes_transferred */, handler->handle_wakeup (); } +ACE_END_VERSIONED_NAMESPACE_DECL + #endif /* ACE_WIN32 */ diff --git a/ace/WIN32_Proactor.h b/ace/WIN32_Proactor.h index 27d78888459..1fd1e2de2e2 100644 --- a/ace/WIN32_Proactor.h +++ b/ace/WIN32_Proactor.h @@ -1,4 +1,4 @@ -/* -*- C++ -*- */ +// -*- C++ -*- //============================================================================= /** @@ -34,6 +34,8 @@ #include "ace/Asynch_Pseudo_Task.h" #include "ace/Auto_Event.h" +ACE_BEGIN_VERSIONED_NAMESPACE_DECL + // Forward declarations. class ACE_WIN32_Asynch_Result; class ACE_WIN32_Proactor_Timer_Handler; @@ -65,7 +67,7 @@ public: /// This method adds the @a handle to the I/O completion port. This /// function is a no-op function for Unix systems. virtual int register_handle (ACE_HANDLE handle, - const void *completion_key); + const void *completion_key); /** * Dispatch a single set of events. If @a wait_time elapses before @@ -235,7 +237,7 @@ protected: /// Called when object is removed from the ACE_Reactor. virtual int handle_close (ACE_HANDLE handle, - ACE_Reactor_Mask close_mask); + ACE_Reactor_Mask close_mask); /** * Dispatch a single set of events. If @a milli_seconds elapses @@ -247,9 +249,9 @@ protected: /// Protect against structured exceptions caused by user code when /// dispatching handles. void application_specific_code (ACE_WIN32_Asynch_Result *asynch_result, - size_t bytes_transferred, - const void *completion_key, - u_long error); + size_t bytes_transferred, + const void *completion_key, + u_long error); /** * Post @a how_many completions to the completion port so that all @@ -316,6 +318,8 @@ protected: ACE_Time_Value time_; }; +ACE_END_VERSIONED_NAMESPACE_DECL + #endif /* ACE_WIN32 */ #include /**/ "ace/post.h" #endif /* ACE_PROACTOR_H */ diff --git a/ace/XML_Svc_Conf.cpp b/ace/XML_Svc_Conf.cpp index 76300b641d7..b81c9162076 100644 --- a/ace/XML_Svc_Conf.cpp +++ b/ace/XML_Svc_Conf.cpp @@ -3,7 +3,13 @@ #include "ace/XML_Svc_Conf.h" #if (ACE_USES_CLASSIC_SVC_CONF == 0) + +ACE_BEGIN_VERSIONED_NAMESPACE_DECL + ACE_XML_Svc_Conf::~ACE_XML_Svc_Conf (void) { } + +ACE_END_VERSIONED_NAMESPACE_DECL + #endif /* ACE_USES_CLASSIC_SVC_CONF == 0 */ diff --git a/ace/XML_Svc_Conf.h b/ace/XML_Svc_Conf.h index c05e63babfd..a91594b6075 100644 --- a/ace/XML_Svc_Conf.h +++ b/ace/XML_Svc_Conf.h @@ -1,4 +1,4 @@ -/* -*- C++ -*- */ +// -*- C++ -*- //============================================================================= /** @@ -23,6 +23,9 @@ #endif /* ACE_LACKS_PRAGMA_ONCE */ #if (ACE_USES_CLASSIC_SVC_CONF==0) + +ACE_BEGIN_VERSIONED_NAMESPACE_DECL + /** * @class ACE_XML_Svc_Conf * @@ -52,6 +55,9 @@ public: virtual int parse_string (const ACE_TCHAR str[]) = 0; }; + +ACE_END_VERSIONED_NAMESPACE_DECL + #endif /* ACE_USES_CLASSIC_SVC_CONF == 0 */ #include /**/ "ace/post.h" diff --git a/ace/XTI_ATM_Mcast.cpp b/ace/XTI_ATM_Mcast.cpp index a4524e248f9..3ab9dcdad3a 100644 --- a/ace/XTI_ATM_Mcast.cpp +++ b/ace/XTI_ATM_Mcast.cpp @@ -1,4 +1,3 @@ -// XTI_ATM_Mcast.cpp // $Id$ #include "ace/XTI_ATM_Mcast.h" @@ -11,6 +10,8 @@ ACE_RCSID(ace, XTI_ATM_Mcast, "$Id$") #include "ace/XTI_ATM_Mcast.inl" #endif /* __ACE_INLINE__ */ +ACE_BEGIN_VERSIONED_NAMESPACE_DECL + ACE_ALLOC_HOOK_DEFINE(ACE_XTI_ATM_Mcast) void @@ -30,8 +31,8 @@ ACE_XTI_ATM_Mcast::ACE_XTI_ATM_Mcast (void) int ACE_XTI_ATM_Mcast::add_leaf (ACE_TLI_Stream ¤t_stream, - const ACE_Addr &remote_sap, - ACE_INT32 leaf_id, + const ACE_Addr &remote_sap, + ACE_INT32 leaf_id, ACE_Time_Value *timeout) { ACE_TRACE ("ACE_XTI_ATM_Mcast::add_leaf"); @@ -65,4 +66,6 @@ ACE_XTI_ATM_Mcast::add_leaf (ACE_TLI_Stream ¤t_stream, return 0; } +ACE_END_VERSIONED_NAMESPACE_DECL + #endif /* ACE_HAS_XTI_ATM */ diff --git a/ace/XTI_ATM_Mcast.h b/ace/XTI_ATM_Mcast.h index ea2ba46739f..357af246784 100644 --- a/ace/XTI_ATM_Mcast.h +++ b/ace/XTI_ATM_Mcast.h @@ -1,4 +1,4 @@ -/* -*- C++ -*- */ +// -*- C++ -*- //============================================================================= /** @@ -26,6 +26,8 @@ #include "ace/TLI_Connector.h" #include "ace/ATM_Addr.h" +ACE_BEGIN_VERSIONED_NAMESPACE_DECL + /** * @class ACE_XTI_ATM_Mcast * @@ -122,10 +124,14 @@ public: ACE_ALLOC_HOOK_DECLARE; }; +ACE_END_VERSIONED_NAMESPACE_DECL + #if defined (__ACE_INLINE__) #include "ace/XTI_ATM_Mcast.inl" #endif /* __ACE_INLINE__ */ #endif /* ACE_HAS_XTI_ATM */ + #include /**/ "ace/post.h" + #endif /* ACE_XTI_ATM_MCAST_H */ diff --git a/ace/XTI_ATM_Mcast.inl b/ace/XTI_ATM_Mcast.inl index 895f37f30ff..b062f8423b2 100644 --- a/ace/XTI_ATM_Mcast.inl +++ b/ace/XTI_ATM_Mcast.inl @@ -1,7 +1,8 @@ -/* -*- C++ -*- */ +// -*- C++ -*- +// // $Id$ -// XTI_ATM_Mcast.i +ACE_BEGIN_VERSIONED_NAMESPACE_DECL ACE_INLINE ACE_XTI_ATM_Mcast::ACE_XTI_ATM_Mcast (ACE_TLI_Stream &new_stream, @@ -60,3 +61,5 @@ ACE_XTI_ATM_Mcast::connect (ACE_TLI_Stream &new_stream, udata, opt); } + +ACE_END_VERSIONED_NAMESPACE_DECL diff --git a/ace/XtReactor.cpp b/ace/XtReactor.cpp index 6fb2c898ba3..d1ed38af310 100644 --- a/ace/XtReactor.cpp +++ b/ace/XtReactor.cpp @@ -7,13 +7,15 @@ ACE_RCSID(ace, XtReactor, "$Id$") +ACE_BEGIN_VERSIONED_NAMESPACE_DECL + ACE_ALLOC_HOOK_DEFINE (ACE_XtReactor) // Must be called with lock held ACE_XtReactor::ACE_XtReactor (XtAppContext context, - size_t size, - int restart, - ACE_Sig_Handler *h) + size_t size, + int restart, + ACE_Sig_Handler *h) : ACE_Select_Reactor (size, restart, h), context_ (context), ids_ (0), @@ -53,7 +55,7 @@ ACE_XtReactor::~ACE_XtReactor (void) int ACE_XtReactor::wait_for_multiple_events (ACE_Select_Reactor_Handle_Set &handle_set, - ACE_Time_Value *max_wait_time) + ACE_Time_Value *max_wait_time) { ACE_TRACE ("ACE_XtReactor::wait_for_multiple_events"); int nfound; @@ -67,8 +69,8 @@ ACE_XtReactor::wait_for_multiple_events (ACE_Select_Reactor_Handle_Set &handle_s handle_set.wr_mask_ = this->wait_set_.wr_mask_; handle_set.ex_mask_ = this->wait_set_.ex_mask_; nfound = XtWaitForMultipleEvents (width, - handle_set, - max_wait_time); + handle_set, + max_wait_time); } while (nfound == -1 && this->handle_error () > 0); @@ -101,8 +103,8 @@ ACE_XtReactor::TimerCallbackProc (XtPointer closure, XtIntervalId * /* id */) void ACE_XtReactor::InputCallbackProc (XtPointer closure, - int *source, - XtInputId *) + int *source, + XtInputId *) { ACE_XtReactor *self = (ACE_XtReactor *) closure; ACE_HANDLE handle = (ACE_HANDLE) *source; @@ -123,9 +125,9 @@ ACE_XtReactor::InputCallbackProc (XtPointer closure, wait_set.ex_mask_.set_bit (handle); int result = ACE_OS::select (*source + 1, - wait_set.rd_mask_, - wait_set.wr_mask_, - wait_set.ex_mask_, &zero); + wait_set.rd_mask_, + wait_set.wr_mask_, + wait_set.ex_mask_, &zero); ACE_Select_Reactor_Handle_Set dispatch_set; @@ -133,11 +135,11 @@ ACE_XtReactor::InputCallbackProc (XtPointer closure, if (result > 0) { if (wait_set.rd_mask_.is_set (handle)) - dispatch_set.rd_mask_.set_bit (handle); + dispatch_set.rd_mask_.set_bit (handle); if (wait_set.wr_mask_.is_set (handle)) - dispatch_set.wr_mask_.set_bit (handle); + dispatch_set.wr_mask_.set_bit (handle); if (wait_set.ex_mask_.is_set (handle)) - dispatch_set.ex_mask_.set_bit (handle); + dispatch_set.ex_mask_.set_bit (handle); self->dispatch (1, dispatch_set); } @@ -145,8 +147,8 @@ ACE_XtReactor::InputCallbackProc (XtPointer closure, int ACE_XtReactor::XtWaitForMultipleEvents (int width, - ACE_Select_Reactor_Handle_Set &wait_set, - ACE_Time_Value *) + ACE_Select_Reactor_Handle_Set &wait_set, + ACE_Time_Value *) { // Make sure we have a valid context ACE_ASSERT (this->context_ != 0); @@ -155,10 +157,10 @@ ACE_XtReactor::XtWaitForMultipleEvents (int width, ACE_Select_Reactor_Handle_Set temp_set = wait_set; if (ACE_OS::select (width, - temp_set.rd_mask_, - temp_set.wr_mask_, - temp_set.ex_mask_, - (ACE_Time_Value *) &ACE_Time_Value::zero) == -1) + temp_set.rd_mask_, + temp_set.wr_mask_, + temp_set.ex_mask_, + (ACE_Time_Value *) &ACE_Time_Value::zero) == -1) return -1; // Bad file arguments... // Instead of waiting using <select>, just use the Xt mechanism to @@ -173,10 +175,10 @@ ACE_XtReactor::XtWaitForMultipleEvents (int width, // Now actually read the result needed by the <Select_Reactor> using // <select>. return ACE_OS::select (width, - wait_set.rd_mask_, - wait_set.wr_mask_, - wait_set.ex_mask_, - (ACE_Time_Value *) &ACE_Time_Value::zero); + wait_set.rd_mask_, + wait_set.wr_mask_, + wait_set.ex_mask_, + (ACE_Time_Value *) &ACE_Time_Value::zero); } XtAppContext @@ -193,8 +195,8 @@ ACE_XtReactor::context (XtAppContext context) int ACE_XtReactor::register_handler_i (ACE_HANDLE handle, - ACE_Event_Handler *handler, - ACE_Reactor_Mask mask) + ACE_Event_Handler *handler, + ACE_Reactor_Mask mask) { ACE_TRACE ("ACE_XtReactor::register_handler_i"); @@ -263,10 +265,10 @@ ACE_XtReactor::register_handler_i (ACE_HANDLE handle, XtID->next_ = this->ids_; XtID->handle_ = handle; XtID->id_ = ::XtAppAddInput (this->context_, - (int) handle, - (XtPointer) condition, - InputCallbackProc, - (XtPointer) this); + (int) handle, + (XtPointer) condition, + InputCallbackProc, + (XtPointer) this); this->ids_ = XtID; } return 0; @@ -274,8 +276,8 @@ ACE_XtReactor::register_handler_i (ACE_HANDLE handle, int ACE_XtReactor::register_handler_i (const ACE_Handle_Set &handles, - ACE_Event_Handler *handler, - ACE_Reactor_Mask mask) + ACE_Event_Handler *handler, + ACE_Reactor_Mask mask) { return ACE_Select_Reactor::register_handler_i (handles, handler, @@ -284,7 +286,7 @@ ACE_XtReactor::register_handler_i (const ACE_Handle_Set &handles, int ACE_XtReactor::remove_handler_i (ACE_HANDLE handle, - ACE_Reactor_Mask mask) + ACE_Reactor_Mask mask) { ACE_TRACE ("ACE_XtReactor::remove_handler_i"); @@ -339,10 +341,10 @@ ACE_XtReactor::remove_XtInput (ACE_HANDLE handle) int ACE_XtReactor::remove_handler_i (const ACE_Handle_Set &handles, - ACE_Reactor_Mask mask) + ACE_Reactor_Mask mask) { return ACE_Select_Reactor::remove_handler_i (handles, - mask); + mask); } // The following functions ensure that there is an Xt timeout for the @@ -393,7 +395,7 @@ long ACE_XtReactor::schedule_timer (ACE_Event_Handler *event_handler, const void *arg, const ACE_Time_Value &delay, - const ACE_Time_Value &interval) + const ACE_Time_Value &interval) { ACE_TRACE ("ACE_XtReactor::schedule_timer"); ACE_MT (ACE_GUARD_RETURN (ACE_Select_Reactor_Token, ace_mon, this->token_, -1)); @@ -413,12 +415,12 @@ ACE_XtReactor::schedule_timer (ACE_Event_Handler *event_handler, int ACE_XtReactor::cancel_timer (ACE_Event_Handler *handler, - int dont_call_handle_close) + int dont_call_handle_close) { ACE_TRACE ("ACE_XtReactor::cancel_timer"); if (ACE_Select_Reactor::cancel_timer (handler, - dont_call_handle_close) == -1) + dont_call_handle_close) == -1) return -1; else { @@ -429,14 +431,14 @@ ACE_XtReactor::cancel_timer (ACE_Event_Handler *handler, int ACE_XtReactor::cancel_timer (long timer_id, - const void **arg, - int dont_call_handle_close) + const void **arg, + int dont_call_handle_close) { ACE_TRACE ("ACE_XtReactor::cancel_timer"); if (ACE_Select_Reactor::cancel_timer (timer_id, - arg, - dont_call_handle_close) == -1) + arg, + dont_call_handle_close) == -1) return -1; else { @@ -445,3 +447,4 @@ ACE_XtReactor::cancel_timer (long timer_id, } } +ACE_END_VERSIONED_NAMESPACE_DECL diff --git a/ace/XtReactor.h b/ace/XtReactor.h index e51fc87722e..fdd0ccae273 100644 --- a/ace/XtReactor.h +++ b/ace/XtReactor.h @@ -1,4 +1,4 @@ -/* -*- C++ -*- */ +// -*- C++ -*- //============================================================================= /** @@ -6,7 +6,7 @@ * * $Id$ * - * @author Eric C. Newton's <ecn@clark.net> + * @author Eric C. Newton <ecn@clark.net> * @author Kirill Rybaltchenko <Kirill.Rybaltchenko@cern.ch> * @author Douglas C. Schmidt <schmidt@cs.wustl.edu> */ @@ -29,6 +29,8 @@ #include /**/ <X11/Intrinsic.h> //#undef String +ACE_BEGIN_VERSIONED_NAMESPACE_DECL + /** * @class ACE_XtReactorID * @@ -131,5 +133,8 @@ private: ACE_XtReactor &operator = (const ACE_XtReactor &); }; +ACE_END_VERSIONED_NAMESPACE_DECL + #include /**/ "ace/post.h" + #endif /* ACE_XTREACTOR_H */ |