CIM provider

class PEGASUS_PROVIDER_LINKAGE CIMMethodProvider

Functions that support the invocation of methods defined for a CIM class.

Documentation

Functions that support the invocation of methods defined for a CIM class.

The Method Provider supports the client InvokeMethod operation that invokes any method(s) defined on a CIM class of object. In addition to the methods from the CIMProvider interface that the functions inherit, the Method Provider interface defines one function:

The arguments to invokeMethod specify the instance that the method invokes, the method name, and its parameters.

Providers that derive from this class must implement all of these functions. A minimal implementation of invokeMethod may throw a CIMNotSupportedException exception.

A method provider is not required to implement all of the CIM methods defined for a class; there can be more than one method provider for a class. Each provider may implement a subset of the defined methods, leaving other methods providers to implemente methods. No method can be implemented by more than one provider. The methods that are implemented by a provider must be specified to the CIM Server through provider registration in the SupportedMethods property of an instance of the PG_ProviderCapabilities class.


Inheritance:


Public Methods

[more] CIMMethodProvider (void)
Constructs a CIMMethodProvider object with null values (default constructor)
[more]virtual ~CIMMethodProvider (void)
CIMMethodProvider destructor
[more]virtual void invokeMethod ( const OperationContext & context, const CIMObjectPath & objectReference, const CIMName & methodName, const Array< CIMParamValue> & inParameters, MethodResultResponseHandler & handler)
Invoke the specified method on the specified instance.


Inherited from CIMProvider:

Public Methods

ovirtual void initialize(CIMOMHandle & cimom) ovirtual void terminate(void) ovirtual Boolean tryTerminate(void)

o CIMMethodProvider(void)
Constructs a CIMMethodProvider object with null values (default constructor)

o virtual ~CIMMethodProvider(void)
CIMMethodProvider destructor

o virtual void invokeMethod( const OperationContext & context, const CIMObjectPath & objectReference, const CIMName & methodName, const Array< CIMParamValue> & inParameters, MethodResultResponseHandler & handler) = 0
Invoke the specified method on the specified instance.

Instructs the provider to invoke the method specified in the methodName parameter on the object specified in the objectReference parameter.

Throws:
CIMNotSupportedException If the method is not supported.
CIMInvalidParameterException If the parameter is invalid.
CIMObjectNotFoundException If the object is not found.
CIMAccessDeniedException If the user requesting the action is not authorized to perform the action.
CIMOperationFailedException If the operation fails.
Parameters:
context - Specifies the client user's context for this operation, including the user ID.
objectReference - Specifies the fully qualified object path of the class or instance of interest.
methodName - Specifies the name of the method of interest.
inParameters - Specifies the input parameters of the method.
handler - A ResponseHandler object used to deliver results to the CIM Server.


This class has no child classes. In file ../../src/Pegasus/Provider/CIMInstanceProvider.h:

class PEGASUS_PROVIDER_LINKAGE CIMInstanceProvider

This class defines a set of functions that support the manipulation of instances of a CIM object class and their properties.

Documentation

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 requests from CIM clients. Instance providers may be implemented for any CIM class, including Association classes.

In addition to functions inherited from the CIMProvider interface, the functions in the Instance Provider interface are:

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.


Inheritance:


Public Methods

[more] CIMInstanceProvider (void)
Constructor.
[more]virtual ~CIMInstanceProvider (void)
Destructor.
[more]virtual void getInstance ( const OperationContext & context, const CIMObjectPath & instanceReference, const Boolean includeQualifiers, const Boolean includeClassOrigin, const CIMPropertyList & propertyList, InstanceResponseHandler & handler)
Return a single instance.
[more]virtual void enumerateInstances ( const OperationContext & context, const CIMObjectPath & classReference, const Boolean includeQualifiers, const Boolean includeClassOrigin, const CIMPropertyList & propertyList, InstanceResponseHandler & handler)
Return all instances of the specified class.
[more]virtual void enumerateInstanceNames ( const OperationContext & context, const CIMObjectPath & classReference, ObjectPathResponseHandler & handler)
Return all instance names of a single class.
[more]virtual void modifyInstance ( const OperationContext & context, const CIMObjectPath & instanceReference, const CIMInstance & instanceObject, const Boolean includeQualifiers, const CIMPropertyList & propertyList, ResponseHandler & handler)
Replace the current instance specified in the instanceReference parameter.
[more]virtual void createInstance ( const OperationContext & context, const CIMObjectPath & instanceReference, const CIMInstance & instanceObject, ObjectPathResponseHandler & handler)
Create a new instance.
[more]virtual void deleteInstance ( const OperationContext & context, const CIMObjectPath & instanceReference, ResponseHandler & handler)
Delete the instance specified by the instanceReference parameter.


Inherited from CIMProvider:

Public Methods

ovirtual void initialize(CIMOMHandle & cimom) ovirtual void terminate(void) ovirtual Boolean tryTerminate(void)

o CIMInstanceProvider(void)
Constructor. The constructor should not do anything.

o virtual ~CIMInstanceProvider(void)
Destructor. The destructor should not do anything.

o virtual void getInstance( const OperationContext & context, const CIMObjectPath & instanceReference, const Boolean includeQualifiers, const Boolean includeClassOrigin, const CIMPropertyList & propertyList, InstanceResponseHandler & handler) = 0
Return a single instance.

getInstance is called with an instanceReference specifying a CIM instance to be returned. The provider should determine whether the specification corresponds to a valid instance. If so, it will construct a CIMInstance and deliver this to the CIM Server via the ResponseHandler callback. If the specified instance does not exist, this function should throw an CIMObjectNotFoundException.

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, care must be taken to return the same set of key values regardless of which class was specified in the operation.

Throws:
CIMNotSupportedException
CIMInvalidParameterException
CIMObjectNotFoundException
CIMAccessDeniedException
CIMOperationFailedException
Parameters:
context - specifies the client user's context for this operation, including the User ID.
instanceReference - specifies the fully qualified object path of the instance of interest.
includeQualifiers - indicates whether the returned instance must include the qualifiers for the instance and properties. Qualifiers may be included even if this flag is false.
includeClassOrigin - indicates whether the returned instance must include the class origin for each of the instance elements.
propertyList - if not null, this parameter specifies the minimum set of properties required in instances returned by this operation. Because support for this parameter is optional, the instances may contain additional properties not specified in the list. NOTE: The provider does NOT receive the client filtering parameter localOnly. This is resolved in the CIMOM into the propertyList so that the property list represents the complete set of properties to be returned. If the propertyList is NULL all properties are returned. If it is nonNULL but empty, no properites are to be returned.
handler - a ResponseHandler object used to deliver results to the CIM Server.

o virtual void enumerateInstances( const OperationContext & context, const CIMObjectPath & classReference, const Boolean includeQualifiers, const Boolean includeClassOrigin, const CIMPropertyList & propertyList, InstanceResponseHandler & handler) = 0
Return all instances of the specified class.

A typical implementation of this function will call the processing function in the handler object, then iterate over the system resources representing instances of the CIM object, calling deliver on each iteration. It must call deliver with an argument of type CIMInstance. Finally, it will call complete to inform the CIM Server that it has delivered all known instances.

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 that specified in the classReference.

Throws:
CIMNotSupportedException
CIMInvalidParameterException
CIMObjectNotFoundException
should never be thrown by this function; if there are no instances to return, this function should deliver an empty set of instances by calling the handler's processing and complete functions without calling deliver.
CIMAccessDeniedException
CIMOperationFailedException
Parameters:
context - specifies the client user's context for this operation, including the User ID.
classReference - specifies the fully qualified object path to the class of interest.
includeQualifiers - indicates whether the returned instances must include the qualifiers for the instance and properties. Qualifiers may be included even if this flag is false.
includeClassOrigin - indicates whether the returned instances must include the class origin for each of the instance elements.
propertyList - If not null, this parameter specifies the minimum set of properties required in instances returned by this operation. Because support for this parameter is optional, the instances may contain additional properties not specified in the list. NOTE: The provider does NOT receive the client filtering parameters localOnly or deepInheritance. These are resolved in the CIMOM into the propertyList.
handler - ResponseHandler object for delivery of results.

o virtual void enumerateInstanceNames( const OperationContext & context, const CIMObjectPath & classReference, ObjectPathResponseHandler & handler) = 0
Return all instance names of a single class.

Like enumerateInstances, a typical implementation of enumerateInstanceNames will call the processing function in the handler object, then iterate over the system resources representing instances of the CIM object, calling deliver on each iteration. It must call deliver with an argument of type CIMObjectPath containing the information that uniquely identifies each instance. Finally, it will call complete to inform the CIM Server that it has delivered all known instances.

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 instance names only for the deepest class for which it is registered, since the CIM Server will invoke enumerateInstanceNames for all classes at and beneath that specified in the classReference.

Throws:
CIMNotSupportedException
CIMInvalidParameterException
CIMObjectNotFoundException
CIMAccessDeniedException
CIMOperationFailedException
Parameters:
context - specifies the client user's context for this operation, including the User ID.
classReference - specifies the fully qualified object path to the class of interest.
handler - ResponseHandler object for delivery of results.

o virtual void modifyInstance( const OperationContext & context, const CIMObjectPath & instanceReference, const CIMInstance & instanceObject, const Boolean includeQualifiers, const CIMPropertyList & propertyList, ResponseHandler & handler) = 0
Replace the current instance specified in the instanceReference parameter.

modifyInstance sets the values of properties of the instance specified by the instanceReference parameter to those specified in the instanceObject parameter, as controlled by the propertyList parameter. If the propertyList is NULL, then the operation sets all properties. Otherwise, it sets only those specified in the propertyList. Properties specified in the propertyList but not present in the instanceObject are replaced by the class default values or left null.

Ideally, modifyInstance is intended to be an atomic operation on values of the instance. That is, concurrent accesses to the instance by other threads should be blocked during the operation, so that all of the affected property values can be changed without intervening accesses by concurrent requests. Otherwise, other requests could obtain intermediate, and possibly inconsistent, results.

If the specified instance does not exist, the provider should throw an ObjectNotFound exception.

Throws:
CIMNotSupportedException
CIMInvalidParameterException
CIMObjectNotFoundException
CIMAccessDeniedException
CIMOperationFailedException
Parameters:
context - specifies the client user's context for this operation, including the User ID.
instanceReference - specifies the fully qualified object path of the instance of interest.
instanceObject - contains the partial or complete set of properties whose values should be changed.
includeQualifiers - indicates whether the instance qualifiers must be updated as specified in the modified instance. If false, no qualifiers are explicitly modified by this operation.
propertyList - If not null, this parameter specifies the set of properties required to be updated in the instance. Support for this parameter is NOT optional. Providers that do not support this feature must throw a CIMNotSupportedException exception. NOTE: The provider does NOT receive the client filtering parameters localOnly or deepInheritance. These are resolved in the CIMOM into the propertyList.
handler - ResponseHandler object for delivery of results.

o virtual void createInstance( const OperationContext & context, const CIMObjectPath & instanceReference, const CIMInstance & instanceObject, ObjectPathResponseHandler & handler) = 0
Create a new instance.

Create a new instance of the specified class as specified by the instanceReference and instanceObject parameters.

Throws:
CIMNotSupportedException
CIMInvalidParameterException
CIMObjectAlreadyExistsException
CIMAccessDeniedException
CIMOperationFailedException
Parameters:
context - specifies the client user's context for this operation, including the User ID.
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 - contains the partial or complete instance to create. If a key property is null, the provider must supply a valid value for the property or throw a {@link CIMInvalidParameterException CIMInvalidParameterException}. If any property value is invalid, the provider should throw a {@link CIMInvalidParameterException CIMInvalidParameterException}.
handler - ResponseHandler object for delivery of results. If the operation is successful, the provider must deliver the complete instance name of the created instance.

o virtual void deleteInstance( const OperationContext & context, const CIMObjectPath & instanceReference, ResponseHandler & handler) = 0
Delete the instance specified by the instanceReference parameter.

Throws:
CIMNotSupportedException
CIMInvalidParameterException
CIMObjectNotFoundException
CIMAccessDeniedException
CIMOperationFailedException
Parameters:
context - specifies the client user's context for this operation, including the User ID.
instanceReference - specifies the fully qualified object path of the instance to delete. If the specified object does not exist, the provider should throw an ObjectNotFound exception.
handler - ResponseHandler object for delivery of results.


This class has no child classes.

Alphabetic index HTML hierarchy of classes or Java

In file ../../src/Pegasus/Provider/CIMMethodProvider.h:

class PEGASUS_PROVIDER_LINKAGE CIMMethodProvider

Functions that support the invocation of methods defined for a CIM class.

Documentation

Functions that support the invocation of methods defined for a CIM class.

The Method Provider supports the client InvokeMethod operation that invokes any method(s) defined on a CIM class of object. In addition to the methods from the CIMProvider interface that the functions inherit, the Method Provider interface defines one function:

The arguments to invokeMethod specify the instance that the method invokes, the method name, and its parameters.

Providers that derive from this class must implement all of these functions. A minimal implementation of invokeMethod may throw a CIMNotSupportedException exception.

A method provider is not required to implement all of the CIM methods defined for a class; there can be more than one method provider for a class. Each provider may implement a subset of the defined methods, leaving other methods providers to implemente methods. No method can be implemented by more than one provider. The methods that are implemented by a provider must be specified to the CIM Server through provider registration in the SupportedMethods property of an instance of the PG_ProviderCapabilities class.


Inheritance:


Public Methods

[more] CIMMethodProvider (void)
Constructs a CIMMethodProvider object with null values (default constructor)
[more]virtual ~CIMMethodProvider (void)
CIMMethodProvider destructor
[more]virtual void invokeMethod ( const OperationContext & context, const CIMObjectPath & objectReference, const CIMName & methodName, const Array< CIMParamValue> & inParameters, MethodResultResponseHandler & handler)
Invoke the specified method on the specified instance.


Inherited from CIMProvider:

Public Methods

ovirtual void initialize(CIMOMHandle & cimom) ovirtual void terminate(void) ovirtual Boolean tryTerminate(void)

o CIMMethodProvider(void)
Constructs a CIMMethodProvider object with null values (default constructor)

o virtual ~CIMMethodProvider(void)
CIMMethodProvider destructor

o virtual void invokeMethod( const OperationContext & context, const CIMObjectPath & objectReference, const CIMName & methodName, const Array< CIMParamValue> & inParameters, MethodResultResponseHandler & handler) = 0
Invoke the specified method on the specified instance.

Instructs the provider to invoke the method specified in the methodName parameter on the object specified in the objectReference parameter.

Throws:
CIMNotSupportedException If the method is not supported.
CIMInvalidParameterException If the parameter is invalid.
CIMObjectNotFoundException If the object is not found.
CIMAccessDeniedException If the user requesting the action is not authorized to perform the action.
CIMOperationFailedException If the operation fails.
Parameters:
context - Specifies the client user's context for this operation, including the user ID.
objectReference - Specifies the fully qualified object path of the class or instance of interest.
methodName - Specifies the name of the method of interest.
inParameters - Specifies the input parameters of the method.
handler - A ResponseHandler object used to deliver results to the CIM Server.
In file ../../src/Pegasus/Provider/CIMProvider.h:

class PEGASUS_PROVIDER_LINKAGE CIMProvider

Parent class for all provider interfaces.

Documentation

Parent class for all provider interfaces.

The CIMProvider is the parent class for all provider interface types. The currently supported interfaces are:

  • CIMInstanceProvider - supports manipulation of CIM instances and their properties
  • CIMMethodProvider - supports invocation of methods defined on CIM instances
  • CIMAssociationProvider - supports query of CIM Associaitons and their properties. This provider interfaces provides both reference and associatior query operations in accordance with the DMTF Cim Operation specifications

A provider may inherit from any of these interface classes or all of them. A provider MUST implement every function in the chosen interface(s). However, it is not required that all operations be supported. If an operation is not supported, then a minimal implementation of the corresponding function must throw a {@link NotSupported NotSupported} exception.

Certain parameters are passed in several of the functions in the provider interfaces. These are also described in their own sections, and include:

  • OperationContext - contains information about the client's context, including the User ID. The provider must determine whether the specified user should be permitted to perform the operation. If the operation should not be permitted, the provider must throw an AccessDenied exception.

  • CIMObjectPath - specifies the CIM object on which the operation is to be performed. This parameter specifies the hostname, namespace, classname, and key values that uniquely identify an instance of a CIM object.

    hostname - specifies the name of the system on which the object resides. This does not need to be the system that the CIM server is running on, but it generally will be the same system.

    namespace - this CIMNamespaceName object specifies the namespace on the aforementioned host in which the object resides.

    classname - specifies the class on which the requested operation is to be performed.

    keybindings - this CIMKeyBinging object specifies the set of key properties for the aforementioned class. The set of keys uniquely identifies a CIM instance in the host and namespace. It is permissible for clients to specify, and providers should accept, empty strings for key values when this would not be ambiguous. If the specification is ambiguous, or if a key name is invalid or missing, the provider should throw an InvalidParameter exception.

  • CIMInstance - contains a representation of an instance of a CIM object to be used by the requested operation. This parameter should contain all of the key properties, as well as all properties necessary to perform the requested operation.

  • CIMPropertyList - specifies the properties on which this operation should be performed. The exact use of this parameter depends on the specific operation, and is described in the respective section.

  • ResponseHandler - a callback handle used to return results to the CIM Server for subsequent return to the client.

Certain exceptions can be thrown by several of the functions in the provider interfaces. These are described in their own sections, and include:

The CIMProvider interface contains two functions that are inherited by all provider interfaces:

  • initialize - Called before the first call to any client-requested operation; the provider should perform any processing that may be required before normal operation can begin.
  • terminate - Called prior to the provider being stopped; the provider should perform any final processing that may be required.

Providers must implement these functions. A minimal implementation may simply return to the caller.


Inheritance:


Public Methods

[more] CIMProvider (void)
Creates a CIMProvider instance with null values (default constructor)
[more]virtual ~CIMProvider (void)
CIMProvider destructor
[more]virtual void initialize (CIMOMHandle & cimom)
Performs any setup required before normal operation of the provider.
[more]virtual void terminate (void)
Performs any cleanup required before termination.
[more]virtual Boolean tryTerminate (void)
Allows a provider to decline a terminate call.

o CIMProvider(void)
Creates a CIMProvider instance with null values (default constructor)

o virtual ~CIMProvider(void)
CIMProvider destructor

o virtual void initialize(CIMOMHandle & cimom) = 0
Performs any setup required before normal operation of the provider.

The initialize() function allows the provider to conduct the necessary preparations to handle requests. The initialize function is called only once during the lifetime of the provider. Note, however, that with the Pegasus automatic unload function enabled, a provider many be unloaded and loaded many times during one cycle of the CIMOM. This function must complete before the CIM server invokes any other function of the provider, other than terminate.

Parameters:
cimom - Reserved for future use.

o virtual void terminate(void) = 0
Performs any cleanup required before termination.

The terminate function allows the provider to conduct the necessary preparations for termination. This function may be called by the CIM Server at any time, including initialization. Once invoked, no other provider functions are invoked until after a call to initialize.

The provider may, for example, do the following in the terminate function:

  • close files or I/O streams
  • release resources such as shared memory
  • inform concurrently executing requests to complete immediately (this may be done by setting a global flag)
  • kill subprocesses
  • and others

If the provider instance was created on the heap with new in PegasusCreateProvider, then it must be deleted in terminate:

void MyProvider::terminate()
    {
    ...
    delete this;
    ...
    return;
    }

o virtual Boolean tryTerminate(void)
Allows a provider to decline a terminate call. If the provider is unable to terminate, it should return false. Otherwise, it calls its terminate() function and then returns true, as in the default implementation.
Returns:
False If the provider is unable to terminate; Otherwise, return true.


Direct child classes:
CIMMethodProvider
CIMInstanceProvider
CIMIndicationProvider
CIMAssociationProvider
In file ../../src/Pegasus/Provider/CIMIndicationProvider.h:

class PEGASUS_PROVIDER_LINKAGE CIMIndicationProvider

This class defines the set of methods implemented by an indication provider.

Documentation

This class defines the set of methods implemented by an indication provider. A provider that derives from this class must implement all methods. A minimal method implementation simply throws a CIMNotSupportedException.

Inheritance:


Public Methods

[more] CIMIndicationProvider (void)
Constructs a CIMIndicationProvider instance with null values (default constructor)
[more]virtual ~CIMIndicationProvider (void)
Destructs the CIMIndicationProvider
[more]virtual void enableIndications ( IndicationResponseHandler & handler)
Instructs the provider to begin generating indications.
[more]virtual void disableIndications (void)
Tells the provider to stop generating indications.
[more]virtual void createSubscription ( const OperationContext & context, const CIMObjectPath & subscriptionName, const Array< CIMObjectPath> & classNames, const CIMPropertyList & propertyList, const Uint16 repeatNotificationPolicy)
Tells the provider to monitor for indications matching the specified subscription.
[more]virtual void modifySubscription ( const OperationContext & context, const CIMObjectPath & subscriptionName, const Array< CIMObjectPath> & classNames, const CIMPropertyList & propertyList, const Uint16 repeatNotificationPolicy)
Informs the provider that the specified subscription instance has changed.
[more]virtual void deleteSubscription ( const OperationContext & context, const CIMObjectPath & subscriptionName, const Array< CIMObjectPath> & classNames)
Instructs the provider to stop monitoring for indications matching the specified subscription.


Inherited from CIMProvider:

Public Methods

ovirtual void initialize(CIMOMHandle & cimom) ovirtual void terminate(void) ovirtual Boolean tryTerminate(void)

o CIMIndicationProvider(void)
Constructs a CIMIndicationProvider instance with null values (default constructor)

o virtual ~CIMIndicationProvider(void)
Destructs the CIMIndicationProvider

o virtual void enableIndications( IndicationResponseHandler & handler) = 0
Instructs the provider to begin generating indications. One or more createSubscription calls may precede the call to this method. (On start-up, createSubscription is called for each active subscription before the enableIndications method is called, so that the provider knows about all outstanding subscriptions before it begins generating indications.)

The provider must set the namespace and class name in the object path of the generated indication instance (to allow the Indication Processor to filter generated indications based on the Filter SourceNamespace and Query indication class name), as in the following example:

         CIMObjectPath path(String::EMPTY,
                           CIMNamespaceName("root/IndicationSource"),
                           CIMName("IndicationClassName"),
                           Array
           
           
            
            ());
        indicationInstance.setPath(path);
        
           
           

where "root/IndicationSource" is the namespace from which the indication was generated, and "IndicationClassName" is the class name of the generated indication. Note that indication instance paths never have key bindings.

An exception thrown by this method is considered a provider error and does not affect CIM Server behavior.

Parameters:
handler - An IndicationResponseHandler used by the provider to deliver the indications it generates. The IndicationResponseHandler object remains valid until the disableIndications method is called. After disableIndications is called, the behavior of the IndicationResponseHandler is undefined.

o virtual void disableIndications(void) = 0
Tells the provider to stop generating indications. After this call, the IndicationResponseHandler given to the provider in the enableIndications method is no longer valid and its behavior is undefined. Information regarding active subscriptions no longer applies to the provider and should be discarded at this time. (The provider will receive new createSubscription calls to restore necessary state before enableIndications is called again.)

An exception thrown by this method is considered a provider error and does not affect CIM Server behavior.

o virtual void createSubscription( const OperationContext & context, const CIMObjectPath & subscriptionName, const Array< CIMObjectPath> & classNames, const CIMPropertyList & propertyList, const Uint16 repeatNotificationPolicy) = 0
Tells the provider to monitor for indications matching the specified subscription. The provider may reject the subscription by throwing a CIMNotSupportedException. An indication provider must reject the subscription as not supported if the provider cannot carry out the specified RepeatNotificationPolicy with the specified RepeatNotificationInterval, RepeatNotificationGap and RepeatNotificationCount.

Note that it is not necessary for a simple indication provider to take any action on createSubscription, modifySubscription, or deleteSubscription. It may simply generate indications (or not) based on the enableIndications and disableIndications calls.

An indication provider is not required to retain or make use of any specific subscription information. (A provider that accepts a subscription with a RepeatNotificationPolicy value other than "None", however, requires this data for proper operation.)

An indication should only be generated once regardless of the number of active subscriptions. The indication will be sent to each applicable handler. If an indication should not be sent to all subscribers (such as when the provider has accepted one or more subscriptions with a RepeatNotificationPolicy defined), the provider must include in a SubscriptionInstanceNamesContainer the list of subscriptions for which the indication is intended.

Parameters:
context - Similar to that in the other provider interfaces. Of particular interest to indication providers are the SubscriptionInstanceContainer and SubscriptionFilterConditionContainer containers. The SubscriptionInstanceContainer contains the full CIM_IndicationSubscription instance (including, for example, more information about repeat notification policies). The SubscriptionFilterConditionContainer contains the query string and query language from the CIM_IndicationFilter instance.
subscriptionName - Specifies the object path of the CIM_IndicationSubscription instance for which this provider is requested to generate indications.
classNames - Contains a list of indication class names for which this provider has registered as an indication provider and are included in the CIM_IndicationFilter for this subscription instance. A provider may use this as medium-level data for controlling which indications it generates.
propertyList - Specifies which properties of the specified class names must be (minimally) included in the indications generated for this subscription.
repeatNotificationPolicy - Contains the value of the property with the same name in the CIM_IndicationSubscription instance. Most providers will probably not support repeat notification policies, and should throw a CIMNotSupportedException if the value is anything other than "None".

o virtual void modifySubscription( const OperationContext & context, const CIMObjectPath & subscriptionName, const Array< CIMObjectPath> & classNames, const CIMPropertyList & propertyList, const Uint16 repeatNotificationPolicy) = 0
Informs the provider that the specified subscription instance has changed.

Parameters:
context - Similar to that in the other provider interfaces. Of particular interest to indication providers are the SubscriptionInstanceContainer and SubscriptionFilterConditionContainer containers. The SubscriptionInstanceContainer contains the full CIM_IndicationSubscription instance (including, for example, more information about repeat notification policies). The SubscriptionFilterConditionContainer contains the query string and query language from the CIM_IndicationFilter instance.
subscriptionName - Specifies the object path of the CIM_IndicationSubscription instance that is being modified and for which this provider has been requested to generate indications.
classNames - Contains a list of indication class names for which this provider has registered as an indication provider and are included in the CIM_IndicationFilter for this subscription instance. A provider can use this as medium-level data for controlling which indications it generates.
propertyList - Specifies which properties of the specified class names must be (minimally) included in the indications generated for this subscription.
repeatNotificationPolicy - Contains the value of the property with the same name in the CIM_IndicationSubscription instance. Most providers will probably not support repeat notification policies, and should throw a CIMNotSupportedException if the value is anything other than "None".

o virtual void deleteSubscription( const OperationContext & context, const CIMObjectPath & subscriptionName, const Array< CIMObjectPath> & classNames) = 0
Instructs the provider to stop monitoring for indications matching the specified subscription.

An exception thrown by this method is considered a provider error and does not affect CIM Server behavior.

Parameters:
context - Similar to that in the other provider interfaces. Of particular interest to indication providers are the SubscriptionInstanceContainer and SubscriptionFilterConditionContainer containers. The SubscriptionInstanceContainer contains the full CIM_IndicationSubscription instance (including, for example, more information about repeat notification policies). The SubscriptionFilterConditionContainer contains the query string and query language from the CIM_IndicationFilter instance.
subscriptionName - Specifies the object path of the CIM_IndicationSubscription instance for which this provider is requested to stop generating indications.
classNames - Contains a list of indication class names for which this provider has registered as an indication provider and are included in the CIM_IndicationFilter for this subscription instance. A provider can use this as medium-level data for controlling which indications it generates.

In file ../../src/Pegasus/Provider/CIMAssociationProvider.h:

class PEGASUS_PROVIDER_LINKAGE CIMAssociationProvider

This class defines the set of methods implemented by an association provider.

Documentation

This class defines the set of methods implemented by an association provider. A providers that derives from this class must implement all of the methods. The minimal method implementation simply throws the NotSupported exception. The methods implemented match the association operations defined for the client:
  • referenceNames
  • references
  • associatorNames
  • associators
Note that the major difference is that the attributes implemented are not exactly the same as the attributes of the operations implemented for the client.

Inheritance:


Public Methods

[more]virtual void associators ( const OperationContext & context, const CIMObjectPath & objectName, const CIMName & associationClass, const CIMName & resultClass, const String & role, const String & resultRole, const Boolean includeQualifiers, const Boolean includeClassOrigin, const CIMPropertyList & propertyList, ObjectResponseHandler & handler)
Enumerates CIM Objects (Instances only) that are associated to a particular source CIM Object.
[more]virtual void associatorNames ( const OperationContext & context, const CIMObjectPath & objectName, const CIMName & associationClass, const CIMName & resultClass, const String & role, const String & resultRole, ObjectPathResponseHandler & handler)
Enumerate the names of CIM Objects (Instances) associated to a particular source CIM Object.
[more]virtual void references ( const OperationContext & context, const CIMObjectPath & objectName, const CIMName & resultClass, const String & role, const Boolean includeQualifiers, const Boolean includeClassOrigin, const CIMPropertyList & propertyList, ObjectResponseHandler & handler)
Enumerate the association objects that refer to a particular target CIM Object (Instance).
[more]virtual void referenceNames ( const OperationContext & context, const CIMObjectPath & objectName, const CIMName & resultClass, const String & role, ObjectPathResponseHandler & handler)
Enumerate the association object names that refer to a particular target CIM Object (Instance).


Inherited from CIMProvider:

Public Methods

ovirtual void initialize(CIMOMHandle & cimom) ovirtual void terminate(void) ovirtual Boolean tryTerminate(void)

o virtual void associators( const OperationContext & context, const CIMObjectPath & objectName, const CIMName & associationClass, const CIMName & resultClass, const String & role, const String & resultRole, const Boolean includeQualifiers, const Boolean includeClassOrigin, const CIMPropertyList & propertyList, ObjectResponseHandler & handler) = 0
Enumerates CIM Objects (Instances only) that are associated to a particular source CIM Object. Returns CIM Objects. NOTE: if the objects do not include the host and namespace information this information will be inserted by the CIMOM based on the name of the host in which the cimom resides and the namespace in the request.

Throws:
NotSupported Methods not all supported by the provider return this exception.
InvalidParameter If a parameter is not specified correctly.
Parameters:
context - Contains security and locale information relevant for the lifetime of this operation.
objectName - The ObjectName input parameter defines the source CIM Object whose associated Objects are to be returned. This may be either a Class name or Instance name (CIMObjectpath).
associationClass - The AssocClass input parameter, if not NULL, MUST be a valid CIM Association Class name. It acts as a filter on the returned set of Objects by mandating that each returned Object MUST be associated to the source Object via an Instance of this Class or one of its subclasses.
resultClass - If not NULL, this parameter MUST be a valid CIM class name. It act as a filter on the returned set of Objects by mandating that each returned Object MUST be either an Instance of this Class (or one of its subclasses).
role - If not NULL, this parameter MUST be a valid Property name. It acts as a filter on the returned set of Objects by mandating that each returned Object MUST be associated to the source Object via an Association in which the source Object plays the specified role (i.e. the name of the Property in the Association Class that refers to the source Object MUST match the value of this parameter).
resultRole - If not NULL, this parameter MUST be a valid Property name. It acts as a filter on the returned set of Objects by mandating that each returned Object MUST be associated to the source Object via an Association in which the returned Object plays the specified role (i.e. the name of the Property in the Association Class that refers to the returned Object MUST match the value of this parameter).
includeQualifiers - If true, this specifies that all Qualifiers for each Object (including Qualifiers on the Object and on any returned Properties) MUST be included as elements in the response. If false no elements are present in each returned Object.
includeClassOrigin - If true, this specifies that the CLASSORIGIN attribute MUST be present on all appropriate elements in each returned Object. If false, no CLASSORIGIN attributes are present in each returned Object.
propertyList - If not NULL, the members of the array define one or more roperty names. Each returned Object MUST NOT include elements for any Properties missing from this list. If the PropertyList input parameter is an empty array this signifies that no Properties are included in each returned Object. If the PropertyList input parameter is NULL this specifies that all Properties (subject to the conditions expressed by the other parameters) are included in each returned Object.
handler - Asynchronously processes the results of this operation.

o virtual void associatorNames( const OperationContext & context, const CIMObjectPath & objectName, const CIMName & associationClass, const CIMName & resultClass, const String & role, const String & resultRole, ObjectPathResponseHandler & handler) = 0
Enumerate the names of CIM Objects (Instances) associated to a particular source CIM Object. Returns multiple CIMObjectPath objects through the handler. The returned CIMObjectPaths are expected to be absolute including host name and namespace. If these fields are not supplied by the provider they will be inserted by the CIMOM based on the host in which the CIMOM resides and the namespace in the request.

Throws:
NotSupported returned by methods that are not implemented by the provider..
InvalidParameter If a parameter is not specified correctly.
Parameters:
context - Contains security and locale information relevant for the lifetime of this operation.
objectName - The ObjectName input parameter defines the source CIM Object whose associated Objects are to be returned. This may be either a Class name or Instance name (CIMObjectpath).
associationClass - The AssocClass input parameter, if not NULL, MUST be a valid CIM Association Class name. It acts as a filter on the returned set of Objects by mandating that each returned Object MUST be associated to the source Object via an Instance of this Class or one of its subclasses.
resultClass - If not NULL, MUST be a valid CIM Class name. It acts as a filter on the returned set of Objects by mandating that each returned Object MUST be either an Instance of this Class (or one of its subclasses).
role - If not NULL, this parameter MUST be a valid Property name. It acts as a filter on the returned set of Objects by mandating that each returned Object MUST be associated to the source Object via an Association in which the source Object plays the specified role (i.e. the name of the Property in the Association Class that refers to the source Object MUST match the value of this parameter).
resultRole - If not NULL, this parameter MUST be a valid Property name. It acts as a filter on the returned set of Objects by mandating that each returned Object MUST be associated to the source Object via an Association in which the returned Object plays the specified role (i.e. the name of the Property in the Association Class that refers to the returned Object MUST match the value of this parameter).
handler - Asynchronously processes the results of this operation.

o virtual void references( const OperationContext & context, const CIMObjectPath & objectName, const CIMName & resultClass, const String & role, const Boolean includeQualifiers, const Boolean includeClassOrigin, const CIMPropertyList & propertyList, ObjectResponseHandler & handler) = 0
Enumerate the association objects that refer to a particular target CIM Object (Instance). Returns multiple CIMObjectPath objects through the handler. The returned CIMObjectPaths are expected to be absolute including host name and namespace. If these fields are not supplied by the provider they will be inserted by the CIMOM based on the host in which the CIMOM resides and the namespace in the request.

Throws:
NotSupported Returned for any methods not implemented by the provider.
InvalidParameter If a parameter is not specified correctly.
Parameters:
context - Contains security and locale information relevant for the lifetime of this operation.
objectName - The target CIM Object whose referring object names are to be returned. Note that only instances will be forwarded to the provider. All class level requests are handled by the CIM Server internally.
resultClass - If not NULL, MUST be a valid CIM Class name. It acts as a filter on the returned set of Object Names by mandating that each returned Object Name MUST identify an Instance of this Class (or one of its subclasses).
role - The Role input parameter, if not NULL, MUST be a valid Property name. It acts as a filter on the returned set of Objects by mandating that each returned Object MUST be associated to the source Object via an Association in which the source Object plays the specified role (i.e. the name of the Property in the Association Class that refers to the source Object MUST match the value of this parameter.
resultRole - If not NULL, MUST be a valid Property name. It acts as a filter on the returned set of Objects by mandating that each returned Object MUST be associated to the source Object via an Association in which the returned Object plays the specified role (i.e. the name of the Property in the Association Class that refers to the returned Object MUST match the value of this parameter).
includeQualifiers - If true, this specifies that all Qualifiers for each Object (including Qualifiers on the Object and on any returned Properties) MUST be included as elements in the response. If false no elements are present in each returned Object.
includeClassOrigin - If true, this specifies that the CLASSORIGIN attribute MUST be present on all appropriate elements in each returned Object. If false, no CLASSORIGIN attributes are present in each returned Object.
propertyList - - If not NULL, the members of the array define one or more Property names. Each returned Object MUST NOT include elements for any Properties missing from this list. If the PropertyList input parameter is an empty array this signifies that no Properties are included in each returned Object. If the PropertyList input parameter is NULL this specifies that all Properties (subject to the conditions expressed by the other parameters) are included in each returned Object.
handler - Asynchronously processes the results of this operation.

o virtual void referenceNames( const OperationContext & context, const CIMObjectPath & objectName, const CIMName & resultClass, const String & role, ObjectPathResponseHandler & handler) = 0
Enumerate the association object names that refer to a particular target CIM Object (Instance). Returns CIMOobjectPath objects via the handler. The returned CIMObjectPaths are expected to be absolute including host name and namespace. If these fields are not supplied by the provider they will be inserted by the CIMOM based on the host in which the CIMOM resides and the namespace in the request.

Throws:
NotSupported xception returned for any method not implemented by the provider.
InvalidParameter If the parameter is not specified correctly.
Parameters:
context - Contains security and locale information relevant for the lifetime of this operation.
objectName - The target CIM Object whose referring object names are to be returned. Note that only instances will be forwarded to the provider. All class level requests are handled by the CIM Server internally.
resultClass - If not NULL, MUST be a valid CIM Class name. It acts as a filter on the returned set of Object Names by mandating that each returned Object Name MUST identify an Instance of this Class (or one of its subclasses), or this Class (or one of its subclasses)
role - The Role input parameter, if not NULL, MUST be a valid Property name. It acts as a filter on the returned set of Objects by mandating that each returned Object MUST be associated to the source Object via an Association in which the source Object plays the specified role (i.e. the name of the Property in the Association Class that refers to the source Object MUST match the value of this parameter.
handler - Asynchronously processes the results of this operation.

In file ../../src/Pegasus/Consumer/CIMIndicationConsumer.h:

class CIMIndicationConsumer

This class defines the set of methods implemented by an indication consumer provider.

Documentation

This class defines the set of methods implemented by an indication consumer provider. A provider that derives from this class must implement all methods. The minimal method implementation simply throw the NotSupported exception.

Inheritance:


Public Methods

[more] CIMIndicationConsumer (void)
constructor
[more]virtual ~CIMIndicationConsumer (void)
[more]virtual void consumeIndication ( const OperationContext & context, const String & url, const CIMInstance& indicationInstance)

o CIMIndicationConsumer(void)
constructor

o virtual ~CIMIndicationConsumer(void)

o virtual void consumeIndication( const OperationContext & context, const String & url, const CIMInstance& indicationInstance) = 0
Parameters:
context - contains security and locale information relevant for the lifetime of this operation.
url -
indicationInstance -

评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值