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

  1 martin 1.28 //%LICENSE////////////////////////////////////////////////////////////////
  2 martin 1.29 //
  3 martin 1.28 // 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.29 //
 10 martin 1.28 // 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.29 //
 17 martin 1.28 // The above copyright notice and this permission notice shall be included
 18             // in all copies or substantial portions of the Software.
 19 martin 1.29 //
 20 martin 1.28 // THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS
 21 martin 1.29 // OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
 22 martin 1.28 // 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.29 //
 28 martin 1.28 //////////////////////////////////////////////////////////////////////////
 29 schuur 1.1  //
 30             //%/////////////////////////////////////////////////////////////////////////////
 31             
 32             #ifndef Pegasus_JMPIProviderManager_h
 33             #define Pegasus_JMPIProviderManager_h
 34             
 35             #include <Pegasus/Common/Config.h>
 36             #include <Pegasus/Common/HashTable.h>
 37             #include <Pegasus/ProviderManager2/ProviderName.h>
 38             #include <Pegasus/ProviderManager2/ProviderManager.h>
 39             #include <Pegasus/Server/Linkage.h>
 40             #include <Pegasus/Config/ConfigManager.h>
 41             #include <Pegasus/ProviderManager2/OperationResponseHandler.h>
 42 kumpf  1.2  #include <Pegasus/Common/OperationContextInternal.h>
 43 mark.hamzy 1.24 #include <Pegasus/ProviderManager2/JMPI/Linkage.h>
 44                 #include <Pegasus/ProviderManager2/JMPI/JMPIProvider.h>
 45 kumpf      1.5  #include <Pegasus/ProviderManager2/JMPI/JMPILocalProviderManager.h>
 46 konrad.r   1.12 #include <Pegasus/Provider/CIMOMHandleQueryContext.h>
 47 mark.hamzy 1.21 #include <Pegasus/WQL/WQLSelectStatement.h>
 48                 #include <Pegasus/WQL/WQLParser.h>
 49 schuur     1.1  
 50                 PEGASUS_NAMESPACE_BEGIN
 51                 
 52 mark.hamzy 1.24 class PEGASUS_JMPIPM_LINKAGE JMPIProviderManager : public ProviderManager
 53 schuur     1.1  {
 54                 public:
 55 mark.hamzy 1.22     JMPIProviderManager();
 56 schuur     1.1      virtual ~JMPIProviderManager(void);
 57 mark.hamzy 1.14 
 58                     virtual Boolean insertProvider(const ProviderName & providerName,
 59 schuur     1.1              const String &ns, const String &cn);
 60 mark.hamzy 1.14 
 61 schuur     1.1      virtual Message * processMessage(Message * request) throw();
 62                 
 63                     static String resolveFileName(String name);
 64                 
 65 kumpf      1.5      virtual Boolean hasActiveProviders();
 66                     virtual void unloadIdleProviders();
 67 mark.hamzy 1.14 
 68 mark.hamzy 1.19     class indProvRecord
 69                     {
 70                     public:
 71                         indProvRecord ()
 72                         {
 73                            enabled   = false;
 74                            count     = 0;
 75                            ctx       = NULL;
 76                            handler   = NULL;
 77                         }
 78                 
 79                         mutable Mutex                     mutex;
 80                         Boolean                           enabled;
 81                         int                               count;
 82                         OperationContext                 *ctx;
 83                         EnableIndicationsResponseHandler *handler;
 84                     };
 85                 
 86                     class indSelectRecord
 87                     {
 88                     public:
 89 mark.hamzy 1.19         indSelectRecord ()
 90                         {
 91                             qContext = NULL;
 92                         }
 93                 
 94 kumpf      1.25         CIMOMHandleQueryContext *qContext;
 95 mark.hamzy 1.19         String                   query;
 96                         String                   queryLanguage;
 97                         CIMPropertyList          propertyList;
 98                     };
 99                 
100 marek      1.27     typedef HashTable<String,indProvRecord*,EqualFunc<String>,
101                                       HashFunc<String> > IndProvTab;
102                     typedef HashTable<String,indSelectRecord*,EqualFunc<String>,
103                                       HashFunc<String> > IndSelectTab;
104                     typedef HashTable<String,ProviderName,EqualFunc<String>,
105                                       HashFunc<String> > ProvRegistrar;
106 mark.hamzy 1.19 
107                     static Mutex         mutexProvTab;
108                     static IndProvTab    provTab;
109                     static Mutex         mutexSelxTab;
110                     static IndSelectTab  selxTab;
111                     static Mutex         mutexProvReg;
112                     static ProvRegistrar provReg;
113 mark.hamzy 1.14 
114 schuur     1.1  protected:
115 kumpf      1.5      JMPILocalProviderManager providerManager;
116 schuur     1.1  
117                     Message * handleUnsupportedRequest(const Message * message) throw();
118                 
119                     Message * handleGetInstanceRequest(const Message * message) throw();
120                     Message * handleEnumerateInstancesRequest(const Message * message) throw();
121 marek      1.26     Message * handleEnumerateInstanceNamesRequest(
122                                   const Message * message) throw();
123 schuur     1.1      Message * handleCreateInstanceRequest(const Message * message) throw();
124                     Message * handleModifyInstanceRequest(const Message * message) throw();
125                     Message * handleDeleteInstanceRequest(const Message * message) throw();
126                 
127 mark.hamzy 1.15     Message * handleExecQueryRequest(const Message * message) throw();
128 schuur     1.1  
129 mark.hamzy 1.15     Message * handleAssociatorsRequest(const Message * message) throw();
130 schuur     1.1      Message * handleAssociatorNamesRequest(const Message * message) throw();
131                     Message * handleReferencesRequest(const Message * message) throw();
132                     Message * handleReferenceNamesRequest(const Message * message) throw();
133 mark.hamzy 1.15 
134 mark.hamzy 1.16     Message * handleGetPropertyRequest(const Message * message) throw();
135                     Message * handleSetPropertyRequest(const Message * message) throw();
136 mark.hamzy 1.15 
137 schuur     1.1      Message * handleInvokeMethodRequest(const Message * message) throw();
138 schuur     1.8  
139 schuur     1.1      Message * handleCreateSubscriptionRequest(const Message * message) throw();
140 mark.hamzy 1.15 ////Message * handleModifySubscriptionRequest(const Message * message) throw();
141 schuur     1.1      Message * handleDeleteSubscriptionRequest(const Message * message) throw();
142 schuur     1.8  
143 mark.hamzy 1.15 ////Not supported by JMPI
144                 ////Message * handleExportIndicationRequest(const Message * message) throw();
145 schuur     1.1  
146                     Message * handleDisableModuleRequest(const Message * message) throw();
147                     Message * handleEnableModuleRequest(const Message * message) throw();
148                     Message * handleStopAllProvidersRequest(const Message * message) throw();
149 carolann.graves 1.11     Message * handleSubscriptionInitCompleteRequest (const Message * message);
150 schuur          1.1  
151 kumpf           1.2      ProviderName _resolveProviderName(const ProviderIdContainer & providerId);
152 mark.hamzy      1.14 
153                      private:
154                          void debugPrintMethodPointers (JNIEnv *env, jclass jc);
155 mark.hamzy      1.18     bool getInterfaceType         (ProviderIdContainer pidc,
156                                                         String&             interfaceType,
157                                                         String&             interfaceVersion);
158                          bool interfaceIsUsed          (JNIEnv             *env,
159                                                         jobject             jObject,
160                                                         String              searchInterfaceName);
161 mark.hamzy      1.14 
162                          static int trace;
163 schuur          1.1  };
164                      
165                      PEGASUS_NAMESPACE_END
166                      
167                      #endif

No CVS admin address has been configured
Powered by
ViewCVS 0.9.2