Dynamic_Service_Dependency.cpp

Go to the documentation of this file.
00001 #include "ace/ACE.h"
00002 #include "ace/DLL_Manager.h"
00003 #include "ace/Dynamic_Service_Dependency.h"
00004 #include "ace/Service_Config.h"
00005 #include "ace/Log_Msg.h"
00006 
00007 ACE_RCSID (ace,
00008            Dynamic_Service_Dependency,
00009            "Dynamic_Service_Dependency.cpp,v 4.5 2006/06/06 21:56:38 shuston Exp")
00010 
00011 
00012   ACE_BEGIN_VERSIONED_NAMESPACE_DECL
00013 
00014 
00015 ACE_Dynamic_Service_Dependency::ACE_Dynamic_Service_Dependency (const ACE_TCHAR *principal)
00016 {
00017   this->init (ACE_Service_Config::current (), principal);
00018 }
00019 
00020 ACE_Dynamic_Service_Dependency::ACE_Dynamic_Service_Dependency (const ACE_Service_Gestalt *cfg,
00021                                                                 const ACE_TCHAR *principal)
00022 {
00023   this->init (cfg, principal);
00024 }
00025 
00026 
00027 ACE_Dynamic_Service_Dependency::~ACE_Dynamic_Service_Dependency (void)
00028 {
00029   if (ACE::debug () > 1)
00030     ACE_DEBUG ((LM_DEBUG,
00031                 ACE_TEXT ("(%P|%t) DSD, this=%@ - destroying dependency\n"),
00032                 this));
00033 }
00034 
00035 void
00036 ACE_Dynamic_Service_Dependency::init (const ACE_Service_Gestalt *cfg,
00037                                       const ACE_TCHAR *principal)
00038 {
00039   const ACE_Service_Type* st =
00040     ACE_Dynamic_Service_Base::find_i (cfg, principal,false);
00041   if (ACE::debug () > 1)
00042     {
00043       ACE_DEBUG ((LM_DEBUG,
00044       ACE_TEXT ("(%P|%t) DSD, this=%@ - creating dependency on "), this));
00045       st->dump ();
00046     }
00047   this->tracker_ = st->dll ();
00048 }
00049 
00050 
00051 ACE_END_VERSIONED_NAMESPACE_DECL

Generated on Thu Nov 9 09:41:50 2006 for ACE by doxygen 1.3.6