Monitor_Control_Action.cpp

Go to the documentation of this file.
00001 // $Id: Monitor_Control_Action.cpp 81691 2008-05-14 11:09:21Z johnnyw $
00002 
00003 #include "ace/Monitor_Control_Action.h"
00004 
00005 #if defined (ACE_HAS_MONITOR_FRAMEWORK) && (ACE_HAS_MONITOR_FRAMEWORK == 1)
00006 
00007 #include "ace/Guard_T.h"
00008 
00009 ACE_BEGIN_VERSIONED_NAMESPACE_DECL
00010 
00011 namespace ACE
00012 {
00013   namespace Monitor_Control
00014   {
00015     Control_Action::Control_Action (void)
00016       : ACE_Refcountable_T<ACE_SYNCH_MUTEX> (1)
00017     {}
00018 
00019     Control_Action::~Control_Action (void)
00020     {}
00021 
00022     void
00023     Control_Action::add_ref (void)
00024     {
00025       (void) this->increment ();
00026     }
00027 
00028     void
00029     Control_Action::remove_ref (void)
00030     {
00031       const long new_count = this->decrement ();
00032 
00033       if (new_count == 0)
00034         {
00035           delete this;
00036         }
00037     }
00038   }
00039 }
00040 
00041 ACE_END_VERSIONED_NAMESPACE_DECL
00042 
00043 #endif /* ACE_HAS_MONITOR_FRAMEWORK==1 */
00044 
00045 

Generated on Tue Feb 2 17:18:41 2010 for ACE by  doxygen 1.4.7