version 1.21, 2009/12/15 10:52:34
|
version 1.22, 2010/02/04 08:53:04
|
|
|
// Get an instance of the PG_ComputerSystem class produced by the | // Get an instance of the PG_ComputerSystem class produced by the |
// ComputerSystem provider in the root/cimv2 namespace. | // ComputerSystem provider in the root/cimv2 namespace. |
// | // |
// @param includeQualifiers Boolean |
// @param opContext Operation context. |
// @param includeClassOrigin Boolean |
|
// @param propertylist CIMPropertyList |
|
// | // |
// @return CIMInstance of PG_ComputerSystem class. | // @return CIMInstance of PG_ComputerSystem class. |
// | // |
// @exception ObjectNotFound exception if a ComputerSystem instance cannot | // @exception ObjectNotFound exception if a ComputerSystem instance cannot |
// be retrieved. | // be retrieved. |
// | // |
CIMInstance InteropProvider::getComputerSystemInstance() |
CIMInstance InteropProvider::getComputerSystemInstance( |
|
const OperationContext &opContext) |
{ | { |
PEG_METHOD_ENTER(TRC_CONTROLPROVIDER, | PEG_METHOD_ENTER(TRC_CONTROLPROVIDER, |
"InteropProvider::getComputerSystemInstance"); | "InteropProvider::getComputerSystemInstance"); |
|
|
CIMInstance instance; | CIMInstance instance; |
AutoMutex mut(interopMut); | AutoMutex mut(interopMut); |
Array<CIMInstance> tmpInstances = cimomHandle.enumerateInstances( | Array<CIMInstance> tmpInstances = cimomHandle.enumerateInstances( |
OperationContext(), |
opContext, |
PEGASUS_NAMESPACENAME_CIMV2, | PEGASUS_NAMESPACENAME_CIMV2, |
PEGASUS_CLASSNAME_PG_COMPUTERSYSTEM, true, false, false, false, | PEGASUS_CLASSNAME_PG_COMPUTERSYSTEM, true, false, false, false, |
CIMPropertyList()); | CIMPropertyList()); |
|
|
// Returns an instance of the HostedObjectManager association linking the | // Returns an instance of the HostedObjectManager association linking the |
// ObjectManager and ComputerSystem instances managed by this provider. | // ObjectManager and ComputerSystem instances managed by this provider. |
// | // |
CIMInstance InteropProvider::getHostedObjectManagerInstance() |
CIMInstance InteropProvider::getHostedObjectManagerInstance( |
|
const OperationContext &opContext) |
{ | { |
PEG_METHOD_ENTER(TRC_CONTROLPROVIDER, | PEG_METHOD_ENTER(TRC_CONTROLPROVIDER, |
"InteropProvider::getHostedObjectManagerInstance"); | "InteropProvider::getHostedObjectManagerInstance"); |
|
|
CIMInstance instance; | CIMInstance instance; |
bool found = false; | bool found = false; |
| |
CIMObjectPath csPath = getComputerSystemInstance().getPath(); |
CIMObjectPath csPath = getComputerSystemInstance(opContext).getPath(); |
CIMObjectPath omPath = getObjectManagerInstance().getPath(); | CIMObjectPath omPath = getObjectManagerInstance().getPath(); |
String csPathString = csPath.toString(); | String csPathString = csPath.toString(); |
String omPathString = omPath.toString(); | String omPathString = omPath.toString(); |
|
|
// instances for this CIMOM. One will be produced for every instance of | // instances for this CIMOM. One will be produced for every instance of |
// CIMXMLCommunicatiomMechanism managed by this provider. | // CIMXMLCommunicatiomMechanism managed by this provider. |
// | // |
Array<CIMInstance> InteropProvider::enumHostedAccessPointInstances() |
Array<CIMInstance> InteropProvider::enumHostedAccessPointInstances( |
|
const OperationContext &opContext) |
{ | { |
PEG_METHOD_ENTER(TRC_CONTROLPROVIDER, | PEG_METHOD_ENTER(TRC_CONTROLPROVIDER, |
"InteropProvider::enumHostedAccessPointInstance"); | "InteropProvider::enumHostedAccessPointInstance"); |
Array<CIMInstance> instances; | Array<CIMInstance> instances; |
| |
CIMObjectPath csPath = getComputerSystemInstance().getPath(); |
CIMObjectPath csPath = getComputerSystemInstance(opContext).getPath(); |
Array<CIMInstance> commMechs = enumCIMXMLCommunicationMechanismInstances(); | Array<CIMInstance> commMechs = enumCIMXMLCommunicationMechanismInstances(); |
CIMClass hapClass = repository->getClass(PEGASUS_NAMESPACENAME_INTEROP, | CIMClass hapClass = repository->getClass(PEGASUS_NAMESPACENAME_INTEROP, |
PEGASUS_CLASSNAME_PG_HOSTEDACCESSPOINT, false, true, false); | PEGASUS_CLASSNAME_PG_HOSTEDACCESSPOINT, false, true, false); |
|
|
const OperationContext &opContext) | const OperationContext &opContext) |
{ | { |
Array<CIMInstance> instances; | Array<CIMInstance> instances; |
CIMInstance cInst = getComputerSystemInstance(); |
CIMInstance cInst = getComputerSystemInstance(opContext); |
| |
// Get CIM_IndicationService instance | // Get CIM_IndicationService instance |
Array<CIMObjectPath> servicePaths = cimomHandle.enumerateInstanceNames( | Array<CIMObjectPath> servicePaths = cimomHandle.enumerateInstanceNames( |