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

  1 karl  1.10 //%2005////////////////////////////////////////////////////////////////////////
  2 schuur 1.1  //
  3 karl   1.9  // 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 schuur 1.1  // IBM Corp.; EMC Corporation, The Open Group.
  7 karl   1.9  // 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.10 // Copyright (c) 2005 Hewlett-Packard Development Company, L.P.; IBM Corp.;
 10             // EMC Corporation; VERITAS Software Corporation; The Open Group.
 11 schuur 1.1  //
 12             // Permission is hereby granted, free of charge, to any person obtaining a copy
 13             // of this software and associated documentation files (the "Software"), to
 14             // deal in the Software without restriction, including without limitation the
 15             // rights to use, copy, modify, merge, publish, distribute, sublicense, and/or
 16             // sell copies of the Software, and to permit persons to whom the Software is
 17             // furnished to do so, subject to the following conditions:
 18 karl   1.9  // 
 19 schuur 1.1  // THE ABOVE COPYRIGHT NOTICE AND THIS PERMISSION NOTICE SHALL BE INCLUDED IN
 20             // ALL COPIES OR SUBSTANTIAL PORTIONS OF THE SOFTWARE. THE SOFTWARE IS PROVIDED
 21             // "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT
 22             // LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR
 23             // PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
 24             // HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN
 25             // ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
 26             // WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
 27             //
 28             //==============================================================================
 29             //
 30             // Author:      Adrian Schuur, schuur@de.ibm.com
 31             //
 32             // Modified By:
 33             //
 34             //%/////////////////////////////////////////////////////////////////////////////
 35             
 36             #ifndef Pegasus_JMPIProviderManager_h
 37             #define Pegasus_JMPIProviderManager_h
 38             
 39             #include <Pegasus/Common/Config.h>
 40 schuur 1.1  #include <Pegasus/Common/HashTable.h>
 41             #include <Pegasus/ProviderManager2/ProviderRegistrarInitializer.h>
 42             #include <Pegasus/ProviderManager2/ProviderName.h>
 43             #include <Pegasus/ProviderManager2/ProviderManager.h>
 44             #include <Pegasus/Server/Linkage.h>
 45             #include <Pegasus/Config/ConfigManager.h>
 46             #include <Pegasus/ProviderManager2/OperationResponseHandler.h>
 47 kumpf  1.2  #include <Pegasus/Common/OperationContextInternal.h>
 48 kumpf  1.5  #include <Pegasus/ProviderManager2/JMPI/JMPILocalProviderManager.h>
 49 konrad.r 1.12 #include <Pegasus/Provider/CIMOMHandleQueryContext.h>
 50 schuur   1.1  
 51               PEGASUS_NAMESPACE_BEGIN
 52               
 53               class CMPI_SelectExp;
 54               
 55               class PEGASUS_SERVER_LINKAGE JMPIProviderManager : public ProviderManager
 56               {
 57               public:
 58                   enum Mode { 
 59                      CMPI_MODE,
 60                      CMPI_R_MODE,
 61                      CMPI_O_MODE
 62                   };
 63               
 64                   Mode getMode() { return mode; }
 65                   JMPIProviderManager(Mode=CMPI_MODE);
 66                   virtual ~JMPIProviderManager(void);
 67                   
 68                   virtual Boolean insertProvider(const ProviderName & providerName, 
 69                           const String &ns, const String &cn);
 70                 
 71 schuur   1.1      virtual Message * processMessage(Message * request) throw();
 72               
 73                   static String resolveFileName(String name);
 74               
 75 kumpf    1.5      virtual Boolean hasActiveProviders();
 76                   virtual void unloadIdleProviders();
 77 schuur   1.1      
 78                  struct indProvRecord {
 79 schuur   1.8        indProvRecord() : enabled(false), count(1), handler(NULL), ctx(NULL) {}
 80 schuur   1.1        Boolean enabled;
 81                     int count;
 82                     EnableIndicationsResponseHandler* handler;
 83 schuur   1.8        OperationContext* ctx;
 84 schuur   1.1     };
 85               
 86 schuur   1.8  
 87 schuur   1.1     struct indSelectRecord {
 88                     indSelectRecord() : eSelx(NULL) {}
 89                     CMPI_SelectExp *eSelx;
 90 konrad.r 1.12 	  CIMOMHandleQueryContext *qContext;
 91 schuur   1.1     };
 92               
 93                  typedef HashTable<String,indProvRecord*,  EqualFunc<String>,HashFunc<String> > IndProvTab;
 94                  typedef HashTable<String,indSelectRecord*,EqualFunc<String>,HashFunc<String> > IndSelectTab;
 95                  typedef HashTable<String,ProviderName,EqualFunc<String>,HashFunc<String> > ProvRegistrar;
 96               
 97                  static IndProvTab provTab;
 98                  static IndSelectTab selxTab;
 99                  static ProvRegistrar provReg;
100                  
101               protected:
102 kumpf    1.5      JMPILocalProviderManager providerManager;
103 schuur   1.1      Mode mode;
104               
105                   Message * handleUnsupportedRequest(const Message * message) throw();
106               
107                   Message * handleGetInstanceRequest(const Message * message) throw();
108                   Message * handleEnumerateInstancesRequest(const Message * message) throw();
109                   Message * handleEnumerateInstanceNamesRequest(const Message * message) throw();
110                   Message * handleCreateInstanceRequest(const Message * message) throw();
111                   Message * handleModifyInstanceRequest(const Message * message) throw();
112                   Message * handleDeleteInstanceRequest(const Message * message) throw();
113               
114               /*    Message * handleExecuteQueryRequest(const Message * message) throw();
115               
116               */    Message * handleAssociatorsRequest(const Message * message) throw();
117                   Message * handleAssociatorNamesRequest(const Message * message) throw();
118                   Message * handleReferencesRequest(const Message * message) throw();
119                   Message * handleReferenceNamesRequest(const Message * message) throw();
120               /*
121                   Message * handleGetPropertyRequest(const Message * message) throw();
122                   Message * handleSetPropertyRequest(const Message * message) throw();
123 schuur   1.7  */
124 schuur   1.1      Message * handleInvokeMethodRequest(const Message * message) throw();
125 schuur   1.8  
126 schuur   1.1      Message * handleCreateSubscriptionRequest(const Message * message) throw();
127               //    Message * handleModifySubscriptionRequest(const Message * message) throw();
128                   Message * handleDeleteSubscriptionRequest(const Message * message) throw();
129 schuur   1.8  
130 schuur   1.1  //  Not supported by CMPI
131 kumpf    1.6  //    Message * handleExportIndicationRequest(const Message * message) throw();
132 schuur   1.1  
133                   Message * handleDisableModuleRequest(const Message * message) throw();
134                   Message * handleEnableModuleRequest(const Message * message) throw();
135                   Message * handleStopAllProvidersRequest(const Message * message) throw();
136 kumpf    1.3      Message * handleInitializeProviderRequest(const Message * message);
137 carolann.graves 1.11     Message * handleSubscriptionInitCompleteRequest (const Message * message);
138 schuur          1.1  
139 kumpf           1.2      ProviderName _resolveProviderName(const ProviderIdContainer & providerId);
140 schuur          1.1  };
141                      
142                      PEGASUS_NAMESPACE_END
143                      
144                      #endif

No CVS admin address has been configured
Powered by
ViewCVS 0.9.2