version 1.37, 2002/09/19 16:17:36
|
version 1.41, 2003/03/24 19:42:46
|
|
|
PEGASUS_NAMESPACE_BEGIN | PEGASUS_NAMESPACE_BEGIN |
| |
/** | /** |
The name of the operational status property |
|
*/ |
|
static const CIMName _PROPERTY_OPERATIONALSTATUS = |
|
CIMName ("OperationalStatus"); |
|
|
|
/** |
|
The name of the name property for PG_Provider class |
|
*/ |
|
static const CIMName _PROPERTY_PROVIDER_NAME = CIMName ("Name"); |
|
|
|
/** |
|
The name of the Name property for PG_ProviderModule class |
|
*/ |
|
static const CIMName _PROPERTY_PROVIDERMODULE_NAME = CIMName ("Name"); |
|
|
|
/** |
|
The name of the Vendor property for PG_ProviderModule class |
|
*/ |
|
static const CIMName _PROPERTY_VENDOR = CIMName ("Vendor"); |
|
|
|
/** |
|
The name of the Version property for PG_ProviderModule class |
|
*/ |
|
static const CIMName _PROPERTY_VERSION = CIMName ("Version"); |
|
|
|
/** |
|
The name of the interface type property for PG_ProviderModule class |
|
*/ |
|
static const CIMName _PROPERTY_INTERFACETYPE = CIMName ("InterfaceType"); |
|
|
|
/** |
|
The name of the interface version property for PG_ProviderModule class |
|
*/ |
|
static const CIMName _PROPERTY_INTERFACEVERSION = CIMName ("InterfaceVersion"); |
|
|
|
/** |
|
The name of the location property for PG_ProviderModule class |
|
*/ |
|
static const CIMName _PROPERTY_LOCATION = CIMName ("Location"); |
|
|
|
/** |
|
The name of the CapabilityID property for provider capabilities class | The name of the CapabilityID property for provider capabilities class |
*/ | */ |
static const CIMName _PROPERTY_CAPABILITYID = CIMName ("CapabilityID"); | static const CIMName _PROPERTY_CAPABILITYID = CIMName ("CapabilityID"); |
| |
/** | /** |
The name of the provider module name property for provider capabilities class |
Module status |
*/ |
|
static const CIMName _PROPERTY_PROVIDERMODULENAME = |
|
CIMName ("ProviderModuleName"); |
|
|
|
/** |
|
The name of the provider name property for provider capabilities class |
|
*/ |
|
static const CIMName _PROPERTY_PROVIDERNAME = CIMName ("ProviderName"); |
|
|
|
/** |
|
The name of the classname property for provider capabilities class |
|
*/ |
|
static const CIMName _PROPERTY_CLASSNAME = CIMName ("ClassName"); |
|
|
|
/** |
|
The name of the Namespace property for provider capabilities class |
|
*/ | */ |
static const CIMName _PROPERTY_NAMESPACES = CIMName ("Namespaces"); |
static const Uint16 _MODULE_OK = 2; |
|
|
/** |
|
The name of the provider type property for provider capabilities class |
|
*/ |
|
static const CIMName _PROPERTY_PROVIDERTYPE = CIMName ("ProviderType"); |
|
|
|
/** |
|
The name of the supported properties property for provider capabilities class |
|
*/ |
|
static const CIMName _PROPERTY_SUPPORTEDPROPERTIES = |
|
CIMName ("SupportedProperties"); |
|
|
|
/** |
|
The name of the supported methods property for provider capabilities class |
|
*/ |
|
static const CIMName _PROPERTY_SUPPORTEDMETHODS = CIMName ("SupportedMethods"); |
|
|
|
/** |
|
Registered instance provider type |
|
*/ |
|
static const Uint16 _INSTANCE_PROVIDER = 2; |
|
|
|
/** |
|
Registered association provider type |
|
*/ |
|
static const Uint16 _ASSOCIATION_PROVIDER = 3; |
|
|
|
/** |
|
Registered indication provider type |
|
*/ |
|
static const Uint16 _INDICATION_PROVIDER = 4; |
|
|
|
/** |
|
Registered method provider type |
|
*/ |
|
static const Uint16 _METHOD_PROVIDER = 5; |
|
| |
/** | /** |
stopping provider method | stopping provider method |
|
|
/** | /** |
Provider status | Provider status |
*/ | */ |
static const Uint16 _MODULE_OK = 2; |
|
|
|
static const Uint16 _MODULE_STOPPING = 9; | static const Uint16 _MODULE_STOPPING = 9; |
| |
static const Uint16 _MODULE_STOPPED = 10; | static const Uint16 _MODULE_STOPPED = 10; |
|
|
"Missing Version which is required property in PG_ProviderModule class."); | "Missing Version which is required property in PG_ProviderModule class."); |
} | } |
| |
if (instanceObject.findProperty(_PROPERTY_INTERFACETYPE) == |
Uint32 ifcTypeIndex = |
PEG_NOT_FOUND) |
instanceObject.findProperty(_PROPERTY_INTERFACETYPE); |
|
if (ifcTypeIndex == PEG_NOT_FOUND) |
{ | { |
throw PEGASUS_CIM_EXCEPTION(CIM_ERR_FAILED, | throw PEGASUS_CIM_EXCEPTION(CIM_ERR_FAILED, |
"Missing InterfaceType which is required property in PG_ProviderModule class."); | "Missing InterfaceType which is required property in PG_ProviderModule class."); |
} | } |
|
String ifcTypeString; |
|
instanceObject.getProperty(ifcTypeIndex).getValue(). |
|
get(ifcTypeString); |
|
if (ifcTypeString != "C++Default") |
|
{ |
|
throw PEGASUS_CIM_EXCEPTION(CIM_ERR_NOT_SUPPORTED, |
|
"Unsupported InterfaceType value: \"" + ifcTypeString + "\""); |
|
} |
| |
if (instanceObject.findProperty(_PROPERTY_INTERFACEVERSION) == |
Uint32 ifcVersionIndex = |
PEG_NOT_FOUND) |
instanceObject.findProperty(_PROPERTY_INTERFACEVERSION); |
|
if (ifcVersionIndex == PEG_NOT_FOUND) |
{ | { |
throw PEGASUS_CIM_EXCEPTION(CIM_ERR_FAILED, | throw PEGASUS_CIM_EXCEPTION(CIM_ERR_FAILED, |
"Missing InterfaceVersion which is required property in PG_ProviderModule class."); | "Missing InterfaceVersion which is required property in PG_ProviderModule class."); |
} | } |
|
String ifcVersionString; |
|
instanceObject.getProperty(ifcVersionIndex).getValue(). |
|
get(ifcVersionString); |
|
if ((ifcVersionString != "2.1.0") && |
|
(ifcVersionString != "2.2.0")) |
|
{ |
|
throw PEGASUS_CIM_EXCEPTION(CIM_ERR_NOT_SUPPORTED, |
|
"Unsupported InterfaceVersion value: \"" + ifcVersionString + |
|
"\""); |
|
} |
| |
if (instanceObject.findProperty(_PROPERTY_LOCATION) == PEG_NOT_FOUND) | if (instanceObject.findProperty(_PROPERTY_LOCATION) == PEG_NOT_FOUND) |
{ | { |