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 //%/////////////////////////////////////////////////////////////////////////////
33
34 #ifndef Pegasus_JMPILocalProviderManager_h
35 #define Pegasus_JMPILocalProviderManager_h
36
37 #include <Pegasus/Common/Config.h>
38 #include <Pegasus/Common/String.h>
39 #include <Pegasus/Common/HashTable.h>
40
41 #include <Pegasus/ProviderManager2/JMPI/JMPIProvider.h>
|
42 mark.hamzy 1.14 #include <Pegasus/ProviderManager2/JMPI/Linkage.h>
|
43 schuur 1.1
44 PEGASUS_NAMESPACE_BEGIN
45
|
46 mark.hamzy 1.14 class PEGASUS_JMPIPM_LINKAGE JMPILocalProviderManager
|
47 schuur 1.1 {
48
49 public:
50 JMPILocalProviderManager(void);
51 virtual ~JMPILocalProviderManager(void);
52
53 public:
|
54 marek 1.15 JMPIProvider::OpProviderHolder getProvider(
55 const String & fileName,
56 const String & providerName,
57 const String & interfaceName = String::EMPTY);
|
58 schuur 1.1
59 void unloadProvider(const String & fileName, const String & providerName);
60
61 void shutdownAllProviders(void);
62
|
63 kumpf 1.2 Boolean hasActiveProviders();
64 void unloadIdleProviders();
|
65 schuur 1.1
|
66 carolann.graves 1.5 /**
67 Gets list of indication providers to be enabled.
68 Once IndicationService initialization has been completed, the
69 enableIndications() method must be called on each indication provider
70 that has current subscriptions.
71
72 @return list of providers whose enableIndications() method must be
73 called
74 */
75 Array <JMPIProvider *> getIndicationProvidersToEnable ();
76
|
77 schuur 1.1 private:
78 enum CTRL
79 {
80 INSERT_PROVIDER,
81 INSERT_MODULE,
82 REMOVE_PROVIDER,
83 REMOVE_MODULE,
84 LOOKUP_PROVIDER,
85 LOOKUP_MODULE,
86 GET_PROVIDER,
87 UNLOAD_PROVIDER,
88 UNLOAD_ALL_PROVIDERS,
89 UNLOAD_IDLE_PROVIDERS,
90 UNLOAD_IDLE_MODULES
91 };
92
93 typedef HashTable<String, JMPIProvider *,
94 EqualFunc<String>, HashFunc<String> > ResolverTable;
95
96 typedef HashTable<String, JMPIProvider *,
97 EqualFunc<String>, HashFunc<String> > ProviderTable;
98 schuur 1.1
99 typedef HashTable<String, JMPIProviderModule *,
100 EqualFunc<String>, HashFunc<String> > ModuleTable;
101
102 typedef struct
103 {
104 const String *providerName;
105 const String *fileName;
106 const String *interfaceName;
107 } CTRL_STRINGS;
108
109 ResolverTable _resolvers;
110 ProviderTable _providers;
111 ModuleTable _modules;
112 Uint32 _idle_timeout;
113
|
114 marek 1.15 JMPIProvider *_getResolver(
115 const String & fileName,
116 const String & interfaceType);
|
117 schuur 1.1 Sint32 _provider_ctrl(CTRL code, void *parm, void *ret);
118
|
119 mark.hamzy 1.7 Mutex _providerTableMutex;
120
121 static int trace;
|
122 schuur 1.1 protected:
123
124 };
125
126 PEGASUS_NAMESPACE_END
127
128 #endif
129
|