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

  1 karl  1.8 //%2006////////////////////////////////////////////////////////////////////////
  2 schuur 1.1 //
  3 karl   1.3 // Copyright (c) 2000, 2001, 2002 BMC Software; Hewlett-Packard Development
  4            // Company, L.P.; IBM Corp.; The Open Group; Tivoli Systems.
  5            // Copyright (c) 2003 BMC Software; Hewlett-Packard Development Company, L.P.;
  6            // IBM Corp.; EMC Corporation, The Open Group.
  7            // Copyright (c) 2004 BMC Software; Hewlett-Packard Development Company, L.P.;
  8            // IBM Corp.; EMC Corporation; VERITAS Software Corporation; The Open Group.
  9 karl   1.4 // Copyright (c) 2005 Hewlett-Packard Development Company, L.P.; IBM Corp.;
 10            // EMC Corporation; VERITAS Software Corporation; The Open Group.
 11 karl   1.8 // Copyright (c) 2006 Hewlett-Packard Development Company, L.P.; IBM Corp.;
 12            // EMC Corporation; Symantec Corporation; The Open Group.
 13 schuur 1.1 //
 14            // Permission is hereby granted, free of charge, to any person obtaining a copy
 15            // of this software and associated documentation files (the "Software"), to
 16            // deal in the Software without restriction, including without limitation the
 17            // rights to use, copy, modify, merge, publish, distribute, sublicense, and/or
 18            // sell copies of the Software, and to permit persons to whom the Software is
 19            // furnished to do so, subject to the following conditions:
 20 karl   1.8 // 
 21 schuur 1.1 // THE ABOVE COPYRIGHT NOTICE AND THIS PERMISSION NOTICE SHALL BE INCLUDED IN
 22            // ALL COPIES OR SUBSTANTIAL PORTIONS OF THE SOFTWARE. THE SOFTWARE IS PROVIDED
 23            // "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT
 24            // LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR
 25            // PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
 26            // HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN
 27            // ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
 28            // WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
 29            //
 30            //==============================================================================
 31            //
 32            // Author: Chip Vincent (cvincent@us.ibm.com)
 33            //
 34            // Modified By: Yi Zhou, Hewlett-Packard Company(yi_zhou@hp.com)
 35            //              Jenny Yu, Hewlett-Packard Company(jenny_yu@hp.com)
 36            //              Mike Day, IBM (mdday@us.ibm.com)
 37            //              Adrian Schuur, schuur@de.ibm.com
 38            //
 39            //%/////////////////////////////////////////////////////////////////////////////
 40            
 41            #ifndef Pegasus_JMPILocalProviderManager_h
 42 schuur 1.1 #define Pegasus_JMPILocalProviderManager_h
 43            
 44            #include <Pegasus/Common/Config.h>
 45            #include <Pegasus/Common/String.h>
 46            #include <Pegasus/Common/HashTable.h>
 47            
 48            #include <Pegasus/ProviderManager2/JMPI/JMPIProvider.h>
 49            //#include <Pegasus/ProviderManager2/JMPI/JMPIResolverModule.h>
 50            
 51            #include <Pegasus/Server/Linkage.h>
 52            
 53            PEGASUS_NAMESPACE_BEGIN
 54            
 55            class PEGASUS_SERVER_LINKAGE JMPILocalProviderManager
 56            {
 57            
 58            public:
 59                JMPILocalProviderManager(void);
 60                virtual ~JMPILocalProviderManager(void);
 61            
 62            public:
 63 schuur 1.1     JMPIProvider::OpProviderHolder getProvider(const String & fileName, const String & providerName,
 64                     const String & interfaceName = String::EMPTY);
 65            
 66                void unloadProvider(const String & fileName, const String & providerName);
 67            
 68                void shutdownAllProviders(void);
 69            
 70 kumpf  1.2     Boolean hasActiveProviders();
 71                void unloadIdleProviders();
 72 schuur 1.1 
 73 carolann.graves 1.5     /**
 74                              Gets list of indication providers to be enabled.
 75                              Once IndicationService initialization has been completed, the
 76                              enableIndications() method must be called on each indication provider
 77                              that has current subscriptions.
 78                     
 79                              @return list of providers whose enableIndications() method must be
 80                                      called
 81                          */
 82                         Array <JMPIProvider *> getIndicationProvidersToEnable ();
 83                     
 84 schuur          1.1 private:
 85                         enum CTRL
 86                         {
 87                             INSERT_PROVIDER,
 88                             INSERT_MODULE,
 89                             REMOVE_PROVIDER,
 90                             REMOVE_MODULE,
 91                             LOOKUP_PROVIDER,
 92                             LOOKUP_MODULE,
 93                             GET_PROVIDER,
 94                             UNLOAD_PROVIDER,
 95                             UNLOAD_ALL_PROVIDERS,
 96                             UNLOAD_IDLE_PROVIDERS,
 97                             UNLOAD_IDLE_MODULES
 98                         };
 99                     
100                         typedef HashTable<String, JMPIProvider *,
101                             EqualFunc<String>,  HashFunc<String> > ResolverTable;
102                     
103                         typedef HashTable<String, JMPIProvider *,
104                             EqualFunc<String>,  HashFunc<String> > ProviderTable;
105 schuur          1.1 
106                         typedef HashTable<String, JMPIProviderModule *,
107                             EqualFunc<String>, HashFunc<String> > ModuleTable;
108                     
109                         typedef struct
110                         {
111                             const String *providerName;
112                             const String *fileName;
113                             const String *interfaceName;
114                         } CTRL_STRINGS;
115                     
116                         friend class ProviderManagerService;
117                     
118                         ResolverTable _resolvers;
119                         ProviderTable _providers;
120                         ModuleTable _modules;
121                         Uint32 _idle_timeout;
122                     
123                         JMPIProvider *_getResolver(const String & fileName, const String & interfaceType);
124                     //    CMPIResolverModule *_loadResolver(const String & fileName);
125                         Sint32 _provider_ctrl(CTRL code, void *parm, void *ret);
126 schuur          1.1 
127 mark.hamzy      1.7     Mutex _providerTableMutex;
128                     
129                         static int trace;
130 schuur          1.1 protected:
131                     
132                     };
133                     
134                     PEGASUS_NAMESPACE_END
135                     
136                     #endif
137                     

No CVS admin address has been configured
Powered by
ViewCVS 0.9.2