Main Page   Class Hierarchy   Alphabetical List   Compound List   File List   Compound Members   File Members   Related Pages  

Service_Config.i

Go to the documentation of this file.
00001 // -*- C++ -*-
00002 //
00003 // $Id: Service_Config.i,v 1.1.1.3 2001/12/04 14:33:09 chad Exp $
00004 
00005 
00006 // This is the primary entry point into the ACE_Service_Config (the
00007 // constructor just handles simple initializations).
00008 
00009 ACE_INLINE int
00010 ACE_Service_Config::open (const ACE_TCHAR program_name[],
00011                           const ACE_TCHAR *logger_key,
00012                           int ignore_static_svcs,
00013                           int ignore_default_svc_conf,
00014                           int ignore_debug_flag)
00015 {
00016   ACE_TRACE ("ACE_Service_Config::open");
00017   ACE_Service_Config::no_static_svcs_ = ignore_static_svcs;
00018 
00019   return ACE_Service_Config::open_i (program_name,
00020                                      logger_key,
00021                                      ignore_default_svc_conf,
00022                                      ignore_debug_flag);
00023 }
00024 
00025 ACE_INLINE int
00026 ACE_Service_Config::open (int argc,
00027                           ACE_TCHAR *argv[],
00028                           const ACE_TCHAR *logger_key,
00029                           int ignore_static_svcs,
00030                           int ignore_default_svc_conf,
00031                           int ignore_debug_flag)
00032 {
00033   ACE_TRACE ("ACE_Service_Config::open");
00034   ACE_Service_Config::no_static_svcs_ = ignore_static_svcs;
00035 
00036   if (ACE_Service_Config::parse_args (argc,
00037                                       argv) == -1)
00038     return -1;
00039   else
00040     return ACE_Service_Config::open_i (argv[0],
00041                                        logger_key,
00042                                        ignore_default_svc_conf,
00043                                        ignore_debug_flag);
00044 }
00045 
00046 // Compare two service descriptors for equality.
00047 
00048 ACE_INLINE int
00049 ACE_Static_Svc_Descriptor::operator== (ACE_Static_Svc_Descriptor &d) const
00050 {
00051   return ACE_OS::strcmp (name_, d.name_) == 0;
00052 }
00053 
00054 // Compare two service descriptors for inequality.
00055 
00056 ACE_INLINE int
00057 ACE_Static_Svc_Descriptor::operator!= (ACE_Static_Svc_Descriptor &d) const
00058 {
00059   return !(*this == d);
00060 }
00061 
00062 ACE_INLINE void
00063 ACE_Service_Config::signal_handler (ACE_Sig_Adapter *signal_handler)
00064 {
00065   signal_handler_ = signal_handler;
00066 }
00067 
00068 #if defined (ACE_HAS_WINCE) && !defined (ACE_USES_WCHAR)
00069   // We must provide these function to bridge Svc_Conf parser with ACE.
00070 
00071 ACE_INLINE int
00072 ACE_Service_Config::initialize (const ACE_Service_Type *sp, char parameters[])
00073 {
00074   return ACE_Service_Config::initialize (sp, ACE_TEXT_CHAR_TO_TCHAR (parameters));
00075 }
00076 
00077 ACE_INLINE int
00078 ACE_Service_Config::initialize (const char svc_name[], char parameters[])
00079 {
00080   return ACE_Service_Config::initialize (ACE_TEXT_CHAR_TO_TCHAR (svc_name),
00081                                          ACE_TEXT_CHAR_TO_TCHAR (parameters));
00082 }
00083 
00084 ACE_INLINE int
00085 ACE_Service_Config::resume (const char svc_name[])
00086 {
00087   return ACE_Service_Config::resume (ACE_TEXT_CHAR_TO_TCHAR (svc_name));
00088 }
00089 
00090 ACE_INLINE int
00091 ACE_Service_Config::suspend (const char svc_name[])
00092 {
00093   return ACE_Service_Config::suspend (ACE_TEXT_CHAR_TO_TCHAR (svc_name));
00094 }
00095 
00096 ACE_INLINE int
00097 ACE_Service_Config::remove (const char svc_name[])
00098 {
00099   return ACE_Service_Config::remove (ACE_TEXT_CHAR_TO_TCHAR (svc_name));
00100 }
00101 #endif /* ACE_HAS_WINCE && !ACE_USES_WCHAR */

Generated on Mon Jun 16 11:21:11 2003 for ACE by doxygen1.2.14 written by Dimitri van Heesch, © 1997-2002