00001 // $Id: Service.cpp 79084 2007-07-30 13:13:45Z elliott_c $ 00002 00003 #include "orbsvcs/Notify/Service.h" 00004 #include "ace/Dynamic_Service.h" 00005 00006 ACE_RCSID (Notify, 00007 TAO_Notify_Service, 00008 "$Id: Service.cpp 79084 2007-07-30 13:13:45Z elliott_c $") 00009 00010 TAO_BEGIN_VERSIONED_NAMESPACE_DECL 00011 00012 TAO_Notify_Service::~TAO_Notify_Service (void) 00013 { 00014 } 00015 00016 TAO_Notify_Service* 00017 TAO_Notify_Service::load_default (void) 00018 { 00019 static const char* services[] = { TAO_MC_NOTIFICATION_SERVICE_NAME, 00020 TAO_NOTIFICATION_SERVICE_NAME, 00021 TAO_COS_NOTIFICATION_SERVICE_NAME, 00022 0 00023 }; 00024 00025 TAO_Notify_Service* notify_service = 0; 00026 for(size_t i = 0; services[i] != 0; i++) 00027 { 00028 notify_service = 00029 ACE_Dynamic_Service<TAO_Notify_Service>::instance (services[i]); 00030 if (notify_service != 0) 00031 break; 00032 } 00033 return notify_service; 00034 } 00035 00036 TAO_END_VERSIONED_NAMESPACE_DECL