(file) Return to JMPILocalProviderManager.h CVS log (file) (dir) Up to [Pegasus] / pegasus / src / Pegasus / ProviderManager2 / JMPI

  1 martin 1.16 //%LICENSE////////////////////////////////////////////////////////////////
  2 martin 1.17 //
  3 martin 1.16 // Licensed to The Open Group (TOG) under one or more contributor license
  4             // agreements.  Refer to the OpenPegasusNOTICE.txt file distributed with
  5             // this work for additional information regarding copyright ownership.
  6             // Each contributor licenses this file to you under the OpenPegasus Open
  7             // Source License; you may not use this file except in compliance with the
  8             // License.
  9 martin 1.17 //
 10 martin 1.16 // Permission is hereby granted, free of charge, to any person obtaining a
 11             // copy of this software and associated documentation files (the "Software"),
 12             // to deal in the Software without restriction, including without limitation
 13             // the rights to use, copy, modify, merge, publish, distribute, sublicense,
 14             // and/or sell copies of the Software, and to permit persons to whom the
 15             // Software is furnished to do so, subject to the following conditions:
 16 martin 1.17 //
 17 martin 1.16 // The above copyright notice and this permission notice shall be included
 18             // in all copies or substantial portions of the Software.
 19 martin 1.17 //
 20 martin 1.16 // THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS
 21 martin 1.17 // OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
 22 martin 1.16 // MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT.
 23             // IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY
 24             // CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT,
 25             // TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
 26             // SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
 27 martin 1.17 //
 28 martin 1.16 //////////////////////////////////////////////////////////////////////////
 29 schuur 1.1  //
 30             //%/////////////////////////////////////////////////////////////////////////////
 31             
 32             #ifndef Pegasus_JMPILocalProviderManager_h
 33             #define Pegasus_JMPILocalProviderManager_h
 34             
 35             #include <Pegasus/Common/Config.h>
 36             #include <Pegasus/Common/String.h>
 37             #include <Pegasus/Common/HashTable.h>
 38             
 39             #include <Pegasus/ProviderManager2/JMPI/JMPIProvider.h>
 40 mark.hamzy 1.14 #include <Pegasus/ProviderManager2/JMPI/Linkage.h>
 41 schuur     1.1  
 42                 PEGASUS_NAMESPACE_BEGIN
 43                 
 44 mark.hamzy 1.14 class PEGASUS_JMPIPM_LINKAGE JMPILocalProviderManager
 45 schuur     1.1  {
 46                 
 47                 public:
 48                     JMPILocalProviderManager(void);
 49                     virtual ~JMPILocalProviderManager(void);
 50                 
 51                 public:
 52 marek      1.15     JMPIProvider::OpProviderHolder getProvider(
 53                         const String & fileName,
 54                         const String & providerName,
 55                         const String & interfaceName = String::EMPTY);
 56 schuur     1.1  
 57                     void unloadProvider(const String & fileName, const String & providerName);
 58                 
 59                     void shutdownAllProviders(void);
 60                 
 61 kumpf      1.2      Boolean hasActiveProviders();
 62                     void unloadIdleProviders();
 63 schuur     1.1  
 64 carolann.graves 1.5      /**
 65                               Gets list of indication providers to be enabled.
 66                               Once IndicationService initialization has been completed, the
 67                               enableIndications() method must be called on each indication provider
 68                               that has current subscriptions.
 69                      
 70                               @return list of providers whose enableIndications() method must be
 71                                       called
 72                           */
 73                          Array <JMPIProvider *> getIndicationProvidersToEnable ();
 74                      
 75 schuur          1.1  private:
 76                          enum CTRL
 77                          {
 78                              INSERT_PROVIDER,
 79                              INSERT_MODULE,
 80                              REMOVE_PROVIDER,
 81                              REMOVE_MODULE,
 82                              LOOKUP_PROVIDER,
 83                              LOOKUP_MODULE,
 84                              GET_PROVIDER,
 85                              UNLOAD_PROVIDER,
 86                              UNLOAD_ALL_PROVIDERS,
 87                              UNLOAD_IDLE_PROVIDERS,
 88                              UNLOAD_IDLE_MODULES
 89                          };
 90                      
 91                          typedef HashTable<String, JMPIProvider *,
 92                              EqualFunc<String>,  HashFunc<String> > ResolverTable;
 93                      
 94                          typedef HashTable<String, JMPIProvider *,
 95                              EqualFunc<String>,  HashFunc<String> > ProviderTable;
 96 schuur          1.1  
 97                          typedef HashTable<String, JMPIProviderModule *,
 98                              EqualFunc<String>, HashFunc<String> > ModuleTable;
 99                      
100                          typedef struct
101                          {
102                              const String *providerName;
103                              const String *fileName;
104                              const String *interfaceName;
105                          } CTRL_STRINGS;
106                      
107                          ResolverTable _resolvers;
108                          ProviderTable _providers;
109                          ModuleTable _modules;
110                          Uint32 _idle_timeout;
111                      
112 marek           1.15     JMPIProvider *_getResolver(
113                              const String & fileName,
114                              const String & interfaceType);
115 schuur          1.1      Sint32 _provider_ctrl(CTRL code, void *parm, void *ret);
116                      
117 mark.hamzy      1.7      Mutex _providerTableMutex;
118                      
119                          static int trace;
120 schuur          1.1  protected:
121                      
122                      };
123                      
124                      PEGASUS_NAMESPACE_END
125                      
126                      #endif
127                      

No CVS admin address has been configured
Powered by
ViewCVS 0.9.2