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 740 of file Object_Manager.cpp.
|
Definition at line 751 of file Object_Manager.cpp. References ACE_Object_Manager::instance().
00752 : saved_main_thread_id_ (ACE_OS::thr_self ()) 00753 { 00754 // Ensure that the Object_Manager gets initialized before any 00755 // application threads have been spawned. Because this will be called 00756 // during construction of static objects, that should always be the 00757 // case. 00758 (void) ACE_Object_Manager::instance (); 00759 } |
|
Definition at line 761 of file Object_Manager.cpp. References saved_main_thread_id_, and ACE_OS::thr_equal().
00762 { 00763 if (ACE_OS::thr_equal (ACE_OS::thr_self (), 00764 saved_main_thread_id_)) 00765 { 00766 delete ACE_Object_Manager::instance_; 00767 ACE_Object_Manager::instance_ = 0; 00768 } 00769 // else if this destructor is not called by the main thread, then do 00770 // not delete the ACE_Object_Manager. That causes problems, on 00771 // WIN32 at least. 00772 } |
|
Save the main thread ID, so that destruction can be suppressed.
Definition at line 748 of file Object_Manager.cpp. Referenced by ~ACE_Object_Manager_Manager(). |