Public Member Functions | |
ACE_Object_Manager_Manager (void) | |
~ACE_Object_Manager_Manager (void) | |
Private Attributes | |
ACE_thread_t | saved_main_thread_id_ |
Save the main thread ID, so that destruction can be suppressed. |
Without ACE_HAS_NONSTATIC_OBJECT_MANAGER, a static instance of this class is created. Therefore, it gets created before main () is called. And it gets destroyed after main () returns.
Definition at line 739 of file Object_Manager.cpp.
|
Definition at line 750 of file Object_Manager.cpp. References ACE_Object_Manager::instance().
00751 : saved_main_thread_id_ (ACE_OS::thr_self ()) 00752 { 00753 // Ensure that the Object_Manager gets initialized before any 00754 // application threads have been spawned. Because this will be called 00755 // during construction of static objects, that should always be the 00756 // case. 00757 (void) ACE_Object_Manager::instance (); 00758 } |
|
Definition at line 760 of file Object_Manager.cpp. References saved_main_thread_id_, and ACE_OS::thr_equal().
00761 { 00762 if (ACE_OS::thr_equal (ACE_OS::thr_self (), 00763 saved_main_thread_id_)) 00764 { 00765 delete ACE_Object_Manager::instance_; 00766 ACE_Object_Manager::instance_ = 0; 00767 } 00768 // else if this destructor is not called by the main thread, then do 00769 // not delete the ACE_Object_Manager. That causes problems, on 00770 // WIN32 at least. 00771 } |
|
Save the main thread ID, so that destruction can be suppressed.
Definition at line 747 of file Object_Manager.cpp. Referenced by ~ACE_Object_Manager_Manager(). |