次の方法で共有


3.2.4.2.7 Invoking Semisynchronous Methods That Return a Single Object

If the client wants to invoke any of the following WMI methods semisynchronously, the client MUST set WBEM_FLAG_RETURN_IMMEDIATELY when it makes the method calls.

When the method returns success, the IWbemCallResult parameter MUST be used to get the result of the actual semisynchronous operation. The client MUST call the methods of IWbemCallResult, as specified in the following table, to obtain the results of the semisynchronous operation that is initiated by the client. The client MUST NOT call other methods of IWbemCallResult except as specified in the following table.

Method

Rule

IWbemServices::OpenNamespace

The IWbemCallResult::GetResultServices method MUST be called to retrieve the IWbemServices pointer.

IWbemServices::PutInstance

The IWbemCallResult::GetResultString method MUST be called to obtain the CIM path that was assigned to the CIM instance.

IWbemServices::GetObject

The IWbemCallResult::GetResultObject method MUST be called to retrieve the CIM object.

IWbemServices::PutClass

IWbemServices::DeleteClass

IWbemServices::DeleteInstance

The IWbemCallResult::GetCallStatus method MUST be called to return the call status.

IWbemServices::ExecMethod

The IWbemCallResult::GetResultObject method MUST be called to retrieve the output parameters.

When the semisynchronous IWbemServices method fails, the output parameter does not have the IWbemCallResult interface.