In file ../../src/Pegasus/Common/ResponseHandler.h:

class PEGASUS_COMMON_LINKAGE ResponseHandler

The ResponseHandler class allows a provider to report operation progress and results to the CIM Server.


Documentation

The ResponseHandler class allows a provider to report operation progress and results to the CIM Server. Subclasses are defined for each of the types of object that a provider can deliver to the CIM Server. A ResponseHandler object of the appropriate type is passed to provider functions that are invoked to process client requests (it is not passed to the initialize or terminate functions). It contains the following public member functions that may be used to deliver results to the CIM Server:

  • processing - inform the CIM Server that delivery of results is beginning.
  • deliver - deliver an incremental result to the CIM Server; the CIM Server accumulates results as they are received from the provider.
  • complete - inform the CIM Server that process of the request is complete and that no further results will be delivered.

Inheritance:


Public Methods

[more]virtual ~ResponseHandler (void)
ResponseHandler destructor
[more]virtual void processing (void)
Inform the CIM server that delivery of results will begin.
[more]virtual void complete (void)
Inform the CIM server that delivery of results is complete.
[more]virtual void setContext (const OperationContext & context)
Experimental Interface
Set the context for the results delivered to the CIM Server.

Protected Methods

[more]OperationContext getContext (void) const
Gets the context for the results delivered to the CIM server

ovirtual ~ResponseHandler(void)
ResponseHandler destructor

ovirtual void processing(void) = 0
Inform the CIM server that delivery of results will begin.

The provider must call processing before attempting to call deliver.

ovirtual void complete(void) = 0
Inform the CIM server that delivery of results is complete.

The provider must call complete when all results have been delivered. The provider must not call deliver after calling complete.

ovirtual void setContext(const OperationContext & context)
Experimental Interface
Set the context for the results delivered to the CIM Server.

The setContext function is used by providers to set a context for the response, in the form of an OperationContext object. The context of the response contains the settings that apply to all the results delivered to the CIM Server. An example context is the language of the response, in the form of a ContentLanguageListContainer in the OperationContext.

This method may be called at any point in the response processing before complete is called.

Currently supported OperationContext containers:

  • ContentLanguageListContainer: used to set the ContentLanguages of the results.
  • Implementation Note: This method is concrete to preserve binary compatibility with previous releases of the CIMServer

    oOperationContext getContext(void) const
    Gets the context for the results delivered to the CIM server


    Direct child classes:
    ObjectResponseHandler
    ObjectPathResponseHandler
    MethodResultResponseHandler
    InstanceResponseHandler
    IndicationResponseHandler

    Alphabetic index HTML hierarchy of classes or Java