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

  1 martin 1.12 //%LICENSE////////////////////////////////////////////////////////////////
  2 martin 1.13 //
  3 martin 1.12 // 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.13 //
 10 martin 1.12 // 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.13 //
 17 martin 1.12 // The above copyright notice and this permission notice shall be included
 18             // in all copies or substantial portions of the Software.
 19 martin 1.13 //
 20 martin 1.12 // THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS
 21 martin 1.13 // OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
 22 martin 1.12 // 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.13 //
 28 martin 1.12 //////////////////////////////////////////////////////////////////////////
 29 schuur 1.1  //
 30             // Author:      Adrian Schuur, schuur@de.ibm.com
 31             //
 32             // Modified By:
 33             //
 34             //%/////////////////////////////////////////////////////////////////////////////
 35             
 36             #include <Pegasus/Common/Config.h>
 37             #include <Pegasus/Common/String.h>
 38             
 39             #include "JMPIProviderManager.h"
 40             
 41             PEGASUS_USING_PEGASUS;
 42 schuur 1.2  PEGASUS_USING_STD;
 43 schuur 1.1  
 44             extern "C" PEGASUS_EXPORT ProviderManager * PegasusCreateProviderManager(
 45                const String & providerManagerName)
 46             {
 47 mark.hamzy 1.7  #ifdef PEGASUS_DEBUG
 48 marek      1.9      PEGASUS_STD(cerr)<<"--- PegasusCreateProviderManager ("
 49                                      <<providerManagerName<<")"<<PEGASUS_STD(endl);
 50 mark.hamzy 1.7  #endif
 51                 
 52                     if (  String::equalNoCase(providerManagerName, "JMPI")
 53                        || String::equalNoCase(providerManagerName, "JMPIExperimental")
 54                        )
 55 schuur     1.1      {
 56 schuur     1.3  #ifdef PEGASUS_DEBUG
 57 marek      1.9          PEGASUS_STD(cerr)<<"--- JMPI Provider Manager activated"
 58                                          <<PEGASUS_STD(endl);
 59 schuur     1.3  #endif
 60 mark.hamzy 1.7  
 61 mark.hamzy 1.8          return new JMPIProviderManager ();
 62 schuur     1.1      }
 63 mark.hamzy 1.7  
 64                     return 0;
 65 schuur     1.1  }
 66 b.whiteley 1.10 
 67                 
 68                 const char *ifcNames[] = {"JMPI", "JMPIExperimental", NULL};
 69                 const char *ifcVersionsJMPI[] = {"1.0.0", "2.0.0", "2.2.0", NULL};
 70                 const char *ifcVersionsJMPIExp[] = {"0.0.1", NULL};
 71                 const char *ifcVersionsNone[] = {NULL};
 72                 
 73                 ///////////////////////////////////////////////////////////////////////////////
 74                 extern "C" PEGASUS_EXPORT const char ** getProviderManagerInterfaceNames()
 75                 {
 76                     return ifcNames;
 77                 }
 78                 
 79                 
 80                 ///////////////////////////////////////////////////////////////////////////////
 81                 extern "C" PEGASUS_EXPORT const char ** getProviderManagerInterfaceVersions(
 82                     const char *providerManagerName)
 83                 {
 84 kumpf      1.11     if (String::equalNoCase(String(providerManagerName), "JMPI"))
 85 b.whiteley 1.10     {
 86                         return ifcVersionsJMPI;
 87                     }
 88 kumpf      1.14     else if (Pegasus::String::equalNoCase(String(providerManagerName),
 89 b.whiteley 1.10         "JMPIExperimental"))
 90                     {
 91                         return ifcVersionsJMPIExp;
 92                     }
 93                     return ifcVersionsNone;
 94                 }
 95                 
 96                 
 97                 ///////////////////////////////////////////////////////////////////////////////
 98 kumpf      1.14 PEGASUS_GET_VERSION_FUNC;
 99 b.whiteley 1.10 
100                 

No CVS admin address has been configured
Powered by
ViewCVS 0.9.2