CIMInstanceProvider Class Reference
#include <CIMInstanceProvider.h>
Inheritance diagram for CIMInstanceProvider:![]()
Public Member Functions
CIMInstanceProvider () virtual ~CIMInstanceProvider () virtual void getInstance (const OperationContext &context, const CIMObjectPath &instanceReference, const Boolean includeQualifiers, const Boolean includeClassOrigin, const CIMPropertyList &propertyList, InstanceResponseHandler &handler)=0 virtual void enumerateInstances (const OperationContext &context, const CIMObjectPath &classReference, const Boolean includeQualifiers, const Boolean includeClassOrigin, const CIMPropertyList &propertyList, InstanceResponseHandler &handler)=0 virtual void enumerateInstanceNames (const OperationContext &context, const CIMObjectPath &classReference, ObjectPathResponseHandler &handler)=0 virtual void modifyInstance (const OperationContext &context, const CIMObjectPath &instanceReference, const CIMInstance &instanceObject, const Boolean includeQualifiers, const CIMPropertyList &propertyList, ResponseHandler &handler)=0 virtual void createInstance (const OperationContext &context, const CIMObjectPath &instanceReference, const CIMInstance &instanceObject, ObjectPathResponseHandler &handler)=0 virtual void deleteInstance (const OperationContext &context, const CIMObjectPath &instanceReference, ResponseHandler &handler)=0 Detailed Description
This class defines a set of functions that support the manipulation of instances of a CIM object class and their properties.
The Instance Provider is the most common provider, and is the provider interface used by the CIM Server to perform instance and property manipulation operations.
The Instance Provider receives operation requests from clients through calls to these functions by the CIM Server. Its purpose is to convert these to calls to system services, operations on system resources, or whatever platform-specific behavior is required to perform the operation modeled by the request. The specific requirements for each of the interface functions are discussed in their respective sections.
Constructor & Destructor Documentation
CIMInstanceProvider::CIMInstanceProvider ( ) Constructs a default CIMInstanceProvider object.
virtual CIMInstanceProvider::~CIMInstanceProvider ( ) [virtual]
Destructs a CIMInstanceProvider object.
Member Function Documentation
virtual void CIMInstanceProvider::createInstance ( const OperationContext & context, const CIMObjectPath & instanceReference, const CIMInstance & instanceObject, ObjectPathResponseHandler & handler ) [pure virtual]
Creates a new instance.
- Parameters:
context An OperationContext object containing the context for the processing of the operation. The context includes the name of the requesting user, language information, and other data. instanceReference Specifies the namespace and class name of the instance to create. The key bindings are not present in the instanceReference, because an instance name is not defined until after the instance has been created. instanceObject The CIM instance to create. If a key property is null, the provider must supply a valid value for the property or throw a CIMInvalidParameterException. If any property value is invalid, the provider should throw a CIMInvalidParameterException. handler ResponseHandler object for delivery of results. On a successful operation, the name of the newly created instance must be delivered.
virtual void CIMInstanceProvider::deleteInstance ( const OperationContext & context, const CIMObjectPath & instanceReference, ResponseHandler & handler ) [pure virtual]
Deletes a specified instance.
- Parameters:
context An OperationContext object containing the context for the processing of the operation. The context includes the name of the requesting user, language information, and other data. instanceReference A fully qualified CIMObjectPath specifying the instance to be deleted. handler ResponseHandler object for delivery of results.
virtual void CIMInstanceProvider::enumerateInstanceNames ( const OperationContext & context, const CIMObjectPath & classReference, ObjectPathResponseHandler & handler ) [pure virtual]
Returns the names of all instances of a specified class.
A typical implementation of this method will call the
processing
method in theResponseHandler
object, then iterate over the system resources representing instances of the CIM object, callingdeliver
on each iteration. Finally, it will callcomplete
to inform the CIM Server that it has delivered all known instances. It is correct to callcomplete
without callingdeliver
if no instances exist.A provider can be implemented and registered to perform operations for several levels of the same line of descent (e.g., CIM_ComputerSystem and CIM_UnitaryComputerSystem). When this is done, the provider must return instances only for the deepest class for which it is registered, since the CIM Server will invoke
enumerateInstanceNames
for all classes at and beneath the class specified by the client.
- Parameters:
context An OperationContext object containing the context for the processing of the operation. The context includes the name of the requesting user, language information, and other data. classReference A fully qualified CIMObjectPath specifying the class for which to retrieve the instance names. handler ResponseHandler object for delivery of results. The delivered CIMObjectPath values should not contain host or namespace information, as these attributes are not included in the WBEM protocol.
virtual void CIMInstanceProvider::enumerateInstances ( const OperationContext & context, const CIMObjectPath & classReference, const Boolean includeQualifiers, const Boolean includeClassOrigin, const CIMPropertyList & propertyList, InstanceResponseHandler & handler ) [pure virtual]
Returns all instances of a specified class.
A typical implementation of this method will call the
processing
method in theResponseHandler
object, then iterate over the system resources representing instances of the CIM object, callingdeliver
on each iteration. Finally, it will callcomplete
to inform the CIM Server that it has delivered all known instances. It is correct to callcomplete
without callingdeliver
if no instances exist.A provider can be implemented and registered to perform operations for several levels of the same line of descent (e.g., CIM_ComputerSystem and CIM_UnitaryComputerSystem). When this is done, the provider must return instances only for the deepest class for which it is registered, since the CIM Server will invoke
enumerateInstances
for all classes at and beneath the class specified by the client.
- Parameters:
context An OperationContext object containing the context for the processing of the operation. The context includes the name of the requesting user, language information, and other data. classReference A fully qualified CIMObjectPath specifying the class for which to retrieve the instances. includeQualifiers A Boolean indicating whether the returned instances must include the qualifiers for the instance and its properties. Qualifiers may be included even if this flag is false. includeClassOrigin A Boolean indicating whether the returned instances must include the class origin for each of the instance elements. propertyList A CIMPropertyList specifying the minimum set of properties required in the returned instance. Support for this parameter is optional.This parameter can be used by the provider to optimize their code and not fill properties which are not requested.The cimserver will filter all properties using an efficient algorithm hence the returned instance may contain properties not specified in the list.A null propertyList indicates that all properties must be included. A non-null, but empty, propertyList indicates that no properites are required. Note: The client PropertyList and LocalOnly parameters are consolidated by the CIM Server into this single parameter. handler ResponseHandler object for delivery of results.
virtual void CIMInstanceProvider::getInstance ( const OperationContext & context, const CIMObjectPath & instanceReference, const Boolean includeQualifiers, const Boolean includeClassOrigin, const CIMPropertyList & propertyList, InstanceResponseHandler & handler ) [pure virtual]
Returns a specified CIM instance.
- Parameters:
context An OperationContext object containing the context for the processing of the operation. The context includes the name of the requesting user, language information, and other data. instanceReference A fully qualified CIMObjectPath specifying the instance to be retrieved. includeQualifiers A Boolean indicating whether the returned instance must include the qualifiers for the instance and its properties. Qualifiers may be included even if this flag is false. includeClassOrigin A Boolean indicating whether the returned instance must include the class origin for each of the instance elements. propertyList A CIMPropertyList specifying the minimum set of properties required in the returned instance. Support for this parameter is optional.This parameter can be used by the provider to optimize their code and not fill properties which are not requested.The cimserver will filter all properties using an efficient algorithm hence the returned instance may contain properties not specified in the list.A null propertyList indicates that all properties must be included. A non-null, but empty, propertyList indicates that no properites are required. Note: The client PropertyList and LocalOnly parameters are consolidated by the CIM Server into this single parameter. handler ResponseHandler object for delivery of results.
virtual void CIMInstanceProvider::modifyInstance ( const OperationContext & context, const CIMObjectPath & instanceReference, const CIMInstance & instanceObject, const Boolean includeQualifiers, const CIMPropertyList & propertyList, ResponseHandler & handler ) [pure virtual]
Replaces all or part of a specified instance.
This method is intended to be atomic. Intermediate states should not be visible to other operations that access the instance.
- Parameters:
context An OperationContext object containing the context for the processing of the operation. The context includes the name of the requesting user, language information, and other data. instanceReference A fully qualified CIMObjectPath specifying the instance to be modified. instanceObject A CIMInstance containing the properties and qualifiers with which to update the instance. includeQualifiers A Boolean indicating whether the instance qualifiers are to be updated in the instance and its properties. If false, no qualifiers are explicitly modified by this operation. propertyList A CIMPropertyList specifying the set of properties to be updated in the instance. Support for this parameter is NOT optional. If the propertyList cannot be honored, a CIMNotSupportedException must be thrown. A null propertyList indicates that all properties must be updated. Properties specified in the propertyList but not present in the instanceObject
are to be replaced by the class default values or left null.handler ResponseHandler object for delivery of results.
The documentation for this class was generated from the following file:
- /builddir/build/BUILD/pegasus/src/Pegasus/Provider/CIMInstanceProvider.h