4040 lines
185 KiB
HTML
4040 lines
185 KiB
HTML
<html>
|
||
|
||
<head>
|
||
<title>Interface IWbemServices</title>
|
||
<meta name="GENERATOR" content="Microsoft FrontPage 3.0">
|
||
</head>
|
||
|
||
<body bgcolor="#F9FCBA">
|
||
<font FACE="Arial Narrow" SIZE="6" COLOR="#800000">
|
||
|
||
<p></font><font FACE="Arial Narrow" SIZE="6"><b>Interface IWbemServices</b></font><font
|
||
SIZE="2" COLOR="#ff00ff"></p>
|
||
</font>
|
||
|
||
<p><font face="Arial" size="2"><em>Rev 1.07, 26-Aug-98, RayMcc</em></font></p>
|
||
|
||
<p><font face="Arial" size="2">CIMOM exports the <b>IWbemServices</b> interface. It is
|
||
used by clients and providers to access WBEM services. It is also exported by dynamic
|
||
class and instance providers to expose their CIM objects to CIMOM (WinMgmt).</font></p>
|
||
<font FACE="Arial Narrow" SIZE="3"><b>
|
||
|
||
<p></b></font><font size="2"><font face="Arial">Providers implementing this interface must
|
||
obey the documented semantics of each method that they implement. Also, providers must
|
||
support the specified error return codes. While CIMOM implements all of the methods, each
|
||
provider usually implements a small subset of the available functionality on this
|
||
interface. A provider must return WBEM_E_PROVIDER_NOT_CAPABLE for any method that it does
|
||
not implement.</font></p>
|
||
|
||
<p></font><font face="Arial" size="2"><strong>Note:</strong> All outbound interface
|
||
pointers from any IWbemServices method should be initialized to NULL before calling the
|
||
interface method. For example, IWbemServices::GetObject returns an IWbemClassObject
|
||
interface pointer. This pointer should be pre-initialized to NULL (or zero) before making
|
||
the call:</font><font FACE="Arial Narrow" SIZE="3"></p>
|
||
|
||
<blockquote>
|
||
<p></font><font face="Courier New" size="2">IWbemClassObject *pObj = 0;<br>
|
||
pWbemSvc->GetObject(strPath, 0, 0, &pObj, 0);</font><font size="2"></p>
|
||
<p> </p>
|
||
</blockquote>
|
||
</font>
|
||
|
||
<table CELLSPACING="0" BORDER="0" WIDTH="692">
|
||
<tr>
|
||
<td WIDTH="180" VALIGN="TOP"><font face="Arial" size="2"><b>IWbemServices Methods</b></font></td>
|
||
<td WIDTH="508" VALIGN="TOP"><font face="Arial" size="2"><b>Description</b></font></td>
|
||
</tr>
|
||
<tr>
|
||
<td WIDTH="180" VALIGN="TOP"><u><a href="#OpenNamespace"><font face="Arial" size="2"><b>OpenNamespace</b></font></a></u></td>
|
||
<td WIDTH="508" VALIGN="TOP"><font face="Arial" size="2">Opens a particular child
|
||
namespace for operations.</font></td>
|
||
</tr>
|
||
<tr>
|
||
<td WIDTH="180" VALIGN="TOP"><font face="Arial" size="2"><b>CancelAsyncCall</b></font></td>
|
||
<td WIDTH="508" VALIGN="TOP"><font face="Arial" size="2">Cancels a currently executing
|
||
asynchronous call.</font></td>
|
||
</tr>
|
||
<tr>
|
||
<td WIDTH="180" VALIGN="TOP"><font face="Arial" size="2"><b>QueryObjectSink</b></font></td>
|
||
<td WIDTH="508" VALIGN="TOP"><font face="Arial" size="2">Allows the caller to obtain a
|
||
notification handler sink.</font></td>
|
||
</tr>
|
||
<tr>
|
||
<td WIDTH="180" VALIGN="TOP"><font face="Arial" size="2"><b>GetObject</b></font></td>
|
||
<td WIDTH="508" VALIGN="TOP"><font face="Arial" size="2">Retrieves an object, whether an
|
||
instance or class definition.</font></td>
|
||
</tr>
|
||
<tr>
|
||
<td WIDTH="180" VALIGN="TOP"><font face="Arial" size="2"><b>GetObjectAsync</b></font></td>
|
||
<td WIDTH="508" VALIGN="TOP"><font face="Arial" size="2">Asynchronously retrieves an
|
||
object (an instance or class definition).</font></td>
|
||
</tr>
|
||
<tr>
|
||
<td WIDTH="180" VALIGN="TOP"><font face="Arial" size="2"><b>PutClass</b></font></td>
|
||
<td WIDTH="508" VALIGN="TOP"><font face="Arial" size="2">Creates or updates a class
|
||
definition.</font></td>
|
||
</tr>
|
||
<tr>
|
||
<td WIDTH="180" VALIGN="TOP"><font face="Arial" size="2"><b>PutClassAsync</b></font></td>
|
||
<td WIDTH="508" VALIGN="TOP"><font face="Arial" size="2">Asynchronously creates or updates
|
||
a class definition.</font></td>
|
||
</tr>
|
||
<tr>
|
||
<td WIDTH="180" VALIGN="TOP"><font face="Arial" size="2"><b>DeleteClass</b></font></td>
|
||
<td WIDTH="508" VALIGN="TOP"><font face="Arial" size="2">Deletes a class.</font></td>
|
||
</tr>
|
||
<tr>
|
||
<td WIDTH="180" VALIGN="TOP"><font face="Arial" size="2"><b>DeleteClassAsync</b></font></td>
|
||
<td WIDTH="508" VALIGN="TOP"><font face="Arial" size="2">Deletes a class and receives
|
||
confirmation asynchronously.</font></td>
|
||
</tr>
|
||
<tr>
|
||
<td WIDTH="180" VALIGN="TOP"><font face="Arial" size="2"><b>CreateClassEnum</b></font></td>
|
||
<td WIDTH="508" VALIGN="TOP"><font face="Arial" size="2">Creates a class enumerator.</font></td>
|
||
</tr>
|
||
<tr>
|
||
<td WIDTH="180" VALIGN="TOP"><font face="Arial" size="2"><b>CreateClassEnumAsync</b></font></td>
|
||
<td WIDTH="508" VALIGN="TOP"><font face="Arial" size="2">Creates a class enumerator that
|
||
executes asynchronously.</font></td>
|
||
</tr>
|
||
<tr>
|
||
<td WIDTH="180" VALIGN="TOP"><font face="Arial" size="2"><b>PutInstance</b></font></td>
|
||
<td WIDTH="508" VALIGN="TOP"><font face="Arial" size="2">Creates or updates an instance of
|
||
a particular class.</font></td>
|
||
</tr>
|
||
<tr>
|
||
<td WIDTH="180" VALIGN="TOP"><font face="Arial" size="2"><b>PutInstanceAsync</b></font></td>
|
||
<td WIDTH="508" VALIGN="TOP"><font face="Arial" size="2">Asynchronously creates or updates
|
||
an instance of a particular class.</font></td>
|
||
</tr>
|
||
<tr>
|
||
<td WIDTH="180" VALIGN="TOP"><font face="Arial" size="2"><b>DeleteInstance</b></font></td>
|
||
<td WIDTH="508" VALIGN="TOP"><font face="Arial" size="2">Deletes a particular instance of
|
||
a class.</font></td>
|
||
</tr>
|
||
<tr>
|
||
<td WIDTH="180" VALIGN="TOP"><font face="Arial" size="2"><b>DeleteInstanceAsync</b></font></td>
|
||
<td WIDTH="508" VALIGN="TOP"><font face="Arial" size="2">Deletes an instance and provides
|
||
confirmation asynchronously.</font></td>
|
||
</tr>
|
||
<tr>
|
||
<td WIDTH="180" VALIGN="TOP"><font face="Arial" size="2"><b>CreateInstanceEnum</b></font></td>
|
||
<td WIDTH="508" VALIGN="TOP"><font face="Arial" size="2">Creates an instance enumerator.</font></td>
|
||
</tr>
|
||
<tr>
|
||
<td WIDTH="180" VALIGN="TOP"><font face="Arial" size="2"><b>CreateInstanceEnumAsync</b></font></td>
|
||
<td WIDTH="508" VALIGN="TOP"><font face="Arial" size="2">Creates an instance enumerator
|
||
that executes asynchronously.</font></td>
|
||
</tr>
|
||
<tr>
|
||
<td WIDTH="180" VALIGN="TOP"><font face="Arial" size="2"><b>ExecQuery</b></font></td>
|
||
<td WIDTH="508" VALIGN="TOP"><font face="Arial" size="2">Executes a query to retrieve
|
||
classes or instances.</font></td>
|
||
</tr>
|
||
<tr>
|
||
<td WIDTH="180" VALIGN="TOP"><font face="Arial" size="2"><b>ExecQueryAsync</b></font></td>
|
||
<td WIDTH="508" VALIGN="TOP"><font face="Arial" size="2">Executes a query to retrieve
|
||
classes or instances asynchronously.</font></td>
|
||
</tr>
|
||
<tr>
|
||
<td WIDTH="180" VALIGN="TOP"><font face="Arial" size="2"><b>ExecNotificationQuery</b></font></td>
|
||
<td WIDTH="508" VALIGN="TOP"><font face="Arial" size="2">Executes a query to receive
|
||
events.</font></td>
|
||
</tr>
|
||
<tr>
|
||
<td WIDTH="180" VALIGN="TOP"><font face="Arial" size="2"><b>ExecNotificationQueryAsync</b></font></td>
|
||
<td WIDTH="508" VALIGN="TOP"><font face="Arial" size="2">Executes a query to receive
|
||
events asynchronously.</font></td>
|
||
</tr>
|
||
<tr>
|
||
<td WIDTH="180" VALIGN="TOP"><font face="Arial" size="2"><b>ExecMethod</b></font></td>
|
||
<td WIDTH="508" VALIGN="TOP"><font face="Arial" size="2">Executes an object method.</font></td>
|
||
</tr>
|
||
<tr>
|
||
<td WIDTH="180" VALIGN="TOP"><font face="Arial" size="2"><b>ExecMethodAsync</b></font></td>
|
||
<td WIDTH="508" VALIGN="TOP"><font face="Arial" size="2">Executes an object method
|
||
asynchronously.</font></td>
|
||
</tr>
|
||
</table>
|
||
|
||
<p><font FACE="Arial" SIZE="1"> </p>
|
||
</font>
|
||
|
||
<hr>
|
||
<font FACE="Arial Narrow" SIZE="5" COLOR="#800000">
|
||
|
||
<p></font><a name="OpenNamespace"></a><font FACE="Arial Narrow" SIZE="5"><b>IWbemServices::OpenNamespace</b></font><font
|
||
SIZE="2" COLOR="#ff00ff"></p>
|
||
</font><font FACE="Arial" SIZE="2">
|
||
|
||
<p>The <b>IWbemServices::OpenNamespace</b> method provides the caller with a new <b>IWbemServices</b>
|
||
pointer that has the specified child namespace as its operating context. All operations
|
||
through the new pointer, such as class or instance creation, only affect that namespace.
|
||
The namespace must be a child namespace of the current object through which this method is
|
||
called.</font><b><font FACE="Lucida Sans Typewriter" SIZE="2"></p>
|
||
|
||
<p></font><font FACE="Lucida Sans Typewriter" SIZE="2" color="#008000">HRESULT
|
||
IWbemServices::OpenNamespace(<br>
|
||
[in] BSTR<i> strNamespace</i>, <br>
|
||
[in] LONG<i> lFlags</i>, </font><br>
|
||
<font FACE="Lucida Sans Typewriter" SIZE="2" color="#008000"> [in]
|
||
IWbemContext<i> *pCtx</i>, </font><br>
|
||
<font FACE="Lucida Sans Typewriter" SIZE="2" color="#008000"> [out,
|
||
OPTIONAL] IWbemServices<i> **ppWorkingNamespace</i><br>
|
||
[out, OPTIONAL] IWbemCallResult<i> **ppResult <br>
|
||
</i> );</font><font FACE="Lucida Sans Typewriter" SIZE="2"></p>
|
||
</b>
|
||
|
||
<p></font><font FACE="Arial Narrow"><b> </p>
|
||
|
||
<p>Parameters</b></font><font FACE="Arial" SIZE="2"><i></p>
|
||
|
||
<p>strNamespace<br>
|
||
</i>The object path to the target namespace. This namespace path can only be relative to
|
||
the current namespace associated with the <b>IWbemServices</b> interface pointer. This
|
||
parameter cannot be an absolute path or NULL.</p>
|
||
|
||
<p><i>lFlags<br>
|
||
</i>This parameter can be set to zero to make this a synchronous call. Otherwise, to make
|
||
this a semisynchronous call set lFlags to WBEM_FLAG_RETURN_IMMEDIATELY, provide a valid
|
||
pointer for the ppResult parameter and this call will return immediately. </p>
|
||
<i>
|
||
|
||
<p>pCtx<br>
|
||
</i>Reserved. Must be NULL.<i></p>
|
||
|
||
<p>ppWorkingNamespace<br>
|
||
</i>Receives the object representing the new namespace context. The returned pointer has a
|
||
positive reference count. The caller must call <b>Release</b> on this pointer when it is
|
||
no longer needed. This pointer is not modified when an error code is returned.</p>
|
||
<i>
|
||
|
||
<p>ppResult<br>
|
||
</i>Typically NULL. If not NULL, then ppWorkingNamespace must be NULL. In this case, the
|
||
parameter receives a pointer to a new <b>IWbemCallResult</b> object. If the lFlags
|
||
parameter is set to WBEM_FLAG_RETURN_IMMEDIATELY this call will return immediately. Then
|
||
the caller can periodically poll the <b>IWbemCallResult::GetResultServices</b> method
|
||
until the pointer for the requested namespace becomes available. This parameter is set to
|
||
point to NULL when there is an error and a new object is not returned.</p>
|
||
|
||
<p>It is important to note that when you use this parameter, you must set <i>ppResult </i>to
|
||
point to NULL before calling the method. This is a DCOM rule.</p>
|
||
</font><font FACE="Arial Narrow"><b>
|
||
|
||
<p>Return Values</b></font></p>
|
||
|
||
<table CELLSPACING="0" BORDER="0" WIDTH="578">
|
||
<tr>
|
||
<td WIDTH="230" VALIGN="TOP"><font FACE="Arial" SIZE="2">WBEM_E_ACCESS_DENIED</font></td>
|
||
<td WIDTH="344" VALIGN="TOP"><font FACE="Arial" SIZE="2">The user does not have permission
|
||
to access the requested namespace.</font></td>
|
||
</tr>
|
||
<tr>
|
||
<td WIDTH="230" VALIGN="TOP"><font FACE="Arial" SIZE="2">WBEM_E_FAILED</font></td>
|
||
<td WIDTH="344" VALIGN="TOP"><font FACE="Arial" SIZE="2">This indicates other unspecified
|
||
errors.</font></td>
|
||
</tr>
|
||
<tr>
|
||
<td WIDTH="230" VALIGN="TOP"><font FACE="Arial" SIZE="2">WBEM_E_INVALID_NAMESPACE</font></td>
|
||
<td WIDTH="344" VALIGN="TOP"><font FACE="Arial" SIZE="2">The specified namespace does not
|
||
exist.</font></td>
|
||
</tr>
|
||
<tr>
|
||
<td WIDTH="230" VALIGN="TOP"><font FACE="Arial" SIZE="2">WBEM_E_INVALID_PARAMETER</font></td>
|
||
<td WIDTH="344" VALIGN="TOP"><font FACE="Arial" SIZE="2">An invalid parameter was
|
||
specified or the namespace could not be parsed.</font></td>
|
||
</tr>
|
||
<tr>
|
||
<td WIDTH="230" VALIGN="TOP"><font FACE="Arial" SIZE="2">WBEM_E_OUT_OF_MEMORY</font></td>
|
||
<td WIDTH="344" VALIGN="TOP"><font FACE="Arial" SIZE="2">There was not enough memory to
|
||
complete the operation.</font></td>
|
||
</tr>
|
||
<tr>
|
||
<td WIDTH="230" VALIGN="TOP"><font FACE="Arial" SIZE="2">WBEM_E_TRANSPORT_FAILURE</font></td>
|
||
<td WIDTH="344" VALIGN="TOP"><font FACE="Arial" SIZE="2">The communications link between
|
||
the current process and CIMOM has failed.</font></td>
|
||
</tr>
|
||
<tr>
|
||
<td WIDTH="230" VALIGN="TOP"><font FACE="Arial" SIZE="2">WBEM_S_NO_ERROR</font></td>
|
||
<td WIDTH="344" VALIGN="TOP"><font FACE="Arial" SIZE="2">The call succeeded.</font></td>
|
||
</tr>
|
||
</table>
|
||
<font FACE="Arial" SIZE="2">
|
||
|
||
<p>On failure, you can obtain any available information from the COM function <b>GetErrorInfo</b>.</p>
|
||
|
||
<p>DCOM-specific error codes may also be returned if network problems cause you to lose
|
||
the remote connection to CIMOM.</font><b><font FACE="Arial Narrow"></p>
|
||
|
||
<p>Remarks</font><font FACE="Arial" SIZE="2"></p>
|
||
|
||
<p>IWbemLocator::ConnectServer</b> can also be used to open the same namespace. The only
|
||
difference is that the <b>OpenNamespace</b> method allows you to place relative object
|
||
paths in the <i>Namespace</i> parameter to open child namespaces. <b>IWbemLocator::ConnectServer</b>
|
||
requires a full object path and does user and password authentication.</p>
|
||
|
||
<p>For example, if the current namespace associated with the <b>IWbemServices</b>
|
||
interface pointer is <em>Root</em>, then using <em>Default</em> in the <i>Namespace</i>
|
||
parameter yields a new pointer bound to the <em>Root\Default</em> namespace.</p>
|
||
|
||
<p>The namespace is closed when <b>Release</b> is called and the reference count reaches
|
||
zero. </font><font FACE="Arial Narrow"><b></p>
|
||
|
||
<p>See Also</b></font><font FACE="Arial" SIZE="2"></p>
|
||
|
||
<p><b>IWbemLocator::ConnectServer</b></font><font FACE="Arial Narrow" SIZE="5"
|
||
COLOR="#800000"></p>
|
||
|
||
<hr>
|
||
|
||
<p></font><a name="CancelAsyncCall"></a><font FACE="Arial Narrow" SIZE="5"><b>IWbemServices::CancelAsyncCall</b></font><font
|
||
SIZE="2" COLOR="#ff00ff"></p>
|
||
</font><font face="Arial" size="2">
|
||
|
||
<p>The <b>IWbemServices::CancelAsyncCall</b> method cancels any currently pending
|
||
asynchronous call based on the <b>IWbemObjectSink</b><i> </i>pointer originally passed to
|
||
an asynchronous method of <strong>IWbemServices</strong>. Before this method returns, it
|
||
calls the <b>Release </b>method on the outstanding <b>IWbemObjectSink</b> pointer that was
|
||
passed to the original asynchronous call. If the same <strong>IWbemObjectSink </strong>instance
|
||
was used in multiple calls, <em>all </em>of those calls will be canceled simultaneously.</font><b><font
|
||
FACE="Lucida Sans Typewriter" SIZE="2"></p>
|
||
|
||
<p><font color="#008000">HRESULT IWbemServices::CancelAsyncCall(<br>
|
||
[in] IWbemObjectSink<i> *pSink </i><br>
|
||
);</font></p>
|
||
</font><font FACE="Arial Narrow">
|
||
|
||
<p>Parameters</font></b><font face="Arial" size="2"><i></p>
|
||
|
||
<p>pSink<br>
|
||
</i>The pointer to the<b> IWbemObjectSink</b> implementation provided by the client to any
|
||
of the asynchronous methods of <b>IWbemServices</b>.<i></p>
|
||
</i></font><font FACE="Arial Narrow"><b>
|
||
|
||
<p>Return Values</b></font></p>
|
||
|
||
<table CELLSPACING="0" BORDER="0" WIDTH="588">
|
||
<tr>
|
||
<td WIDTH="239" VALIGN="TOP"><font face="Arial" size="2">WBEM_E_FAILED</font></td>
|
||
<td WIDTH="345" VALIGN="TOP"><font face="Arial" size="2">This is an unspecified error.</font></td>
|
||
</tr>
|
||
<tr>
|
||
<td WIDTH="239" VALIGN="TOP"><font face="Arial" size="2">WBEM_E_INVALID_PARAMETER</font></td>
|
||
<td WIDTH="345" VALIGN="TOP"><font face="Arial" size="2">The supplied interface in <i>pSink</i>
|
||
did not correspond to a pending asynchronous request</font></td>
|
||
</tr>
|
||
<tr>
|
||
<td WIDTH="239" VALIGN="TOP"><font face="Arial" size="2">WBEM_E_OUT_OF_MEMORY</font></td>
|
||
<td WIDTH="345" VALIGN="TOP"><font face="Arial" size="2">There was not enough memory to
|
||
complete the operation.</font></td>
|
||
</tr>
|
||
<tr>
|
||
<td WIDTH="239" VALIGN="TOP"><font face="Arial" size="2">WBEM_E_TRANSPORT_FAILURE</font></td>
|
||
<td WIDTH="345" VALIGN="TOP"><font face="Arial" size="2">This indicates the failure of the
|
||
remote procedure call (RPC) link between the current process and CIMOM.</font></td>
|
||
</tr>
|
||
<tr>
|
||
<td WIDTH="239" VALIGN="TOP"><font face="Arial" size="2">WBEM_S_NO_ERROR</font></td>
|
||
<td WIDTH="345" VALIGN="TOP"><font face="Arial" size="2">The call succeeded.</font></td>
|
||
</tr>
|
||
</table>
|
||
|
||
<p><font face="Arial" size="2"> </p>
|
||
|
||
<p>On failure, you can obtain any available information from the COM function <b>GetErrorInfo</b>.</p>
|
||
|
||
<p>DCOM-specific error codes also may be returned if network problems cause you to lose
|
||
the remote connection to CIMOM.</font><font FACE="Arial Narrow" SIZE="3"><b></p>
|
||
<font FACE="Arial" SIZE="2">
|
||
|
||
<p></b>It is possible to make numerous asynchronous calls using the same object sink. In
|
||
this case the<strong> IWbemServices::CancelAsyncCall</strong> method will cancel all
|
||
asynchronous calls sharing this object sink. It is strongly recommend that there is one
|
||
instance of the of an object sink for each asynchronous call outstanding.</font></p>
|
||
</font><b><font FACE="Arial Narrow">
|
||
|
||
<p>See Also</font></b><font FACE="Arial" SIZE="2"></p>
|
||
|
||
<p><b>IWbemObjectSink</b></font><font FACE="Arial Narrow" SIZE="5" COLOR="#800000"></p>
|
||
|
||
<hr>
|
||
|
||
<p></font><a name="QueryObjectSink"></a><font FACE="Arial Narrow" SIZE="5"><b>IWbemServices::QueryObjectSink</b></font><font
|
||
SIZE="2" COLOR="#ff00ff"></p>
|
||
</font><font FACE="Arial" SIZE="2">
|
||
|
||
<p>The <b>IWbemServices::QueryObjectSink</b> method allows the caller to obtain a
|
||
notification handler that is exported by CIMOM. This allows the caller to write
|
||
notifications and events directly to CIMOM. The caller should only write<em> </em><strong>extrinsic</strong>
|
||
event types to CIMOM. This API consumes many resources and it no designed for
|
||
a large number of events. Rather, it is provided so that client applications,
|
||
especially setup and configuration applications, can quickly provide individual events to
|
||
activate WBEM event consumers during installation and configuration sessions.
|
||
If many events must be provided with low overhead, an event provider must be constructed.</font><b><font
|
||
FACE="Lucida Sans Typewriter" SIZE="2"></p>
|
||
|
||
<p><font color="#008000">HRESULT IWbemServices::QueryObjectSink(<br>
|
||
[in] LONG <i>lFlags</i>,<i> </i><br>
|
||
[out] IWbemObjectSink<i> **ppResponseHandler</i> <br>
|
||
);</font></p>
|
||
</font><font FACE="Arial Narrow">
|
||
|
||
<p>Parameters</font></b><font FACE="Arial" SIZE="2"><i></p>
|
||
|
||
<p>lFlags<br>
|
||
</i>Reserved. It must be zero.<i></p>
|
||
|
||
<p>ppResponseHandler<br>
|
||
</i>May not be NULL. This parameter receives the interface pointer to the
|
||
notification handler. The returned pointer has a positive reference count, and the
|
||
caller must call <b>Release</b> on the pointer when it is no longer needed. </p>
|
||
</font><font FACE="Arial Narrow"><b>
|
||
|
||
<p>Return Values</b></font></p>
|
||
|
||
<table CELLSPACING="0" BORDER="0" WIDTH="647">
|
||
<tr>
|
||
<td WIDTH="230" VALIGN="TOP"><font FACE="Arial" SIZE="2">WBEM_E_ACCESS_DENIED</font></td>
|
||
<td WIDTH="413" VALIGN="TOP"><font FACE="Arial" SIZE="2">The caller does not have
|
||
permission to provide notifications to CIMOM.</font></td>
|
||
</tr>
|
||
<tr>
|
||
<td WIDTH="230" VALIGN="TOP"><font FACE="Arial" SIZE="2">WBEM_E_FAILED</font></td>
|
||
<td WIDTH="413" VALIGN="TOP"><font FACE="Arial" SIZE="2">This is an unspecified error.</font></td>
|
||
</tr>
|
||
<tr>
|
||
<td WIDTH="230" VALIGN="TOP"><font FACE="Arial" SIZE="2">WBEM_E_INVALID_PARAMETER</font></td>
|
||
<td WIDTH="413" VALIGN="TOP"><font FACE="Arial" SIZE="2">An invalid parameter was
|
||
specified.</font></td>
|
||
</tr>
|
||
<tr>
|
||
<td WIDTH="230" VALIGN="TOP"><font FACE="Arial" SIZE="2">WBEM_E_OUT_OF_MEMORY</font></td>
|
||
<td WIDTH="413" VALIGN="TOP"><font FACE="Arial" SIZE="2">There was not enough memory to
|
||
complete the operation.</font></td>
|
||
</tr>
|
||
<tr>
|
||
<td WIDTH="230" VALIGN="TOP"><font FACE="Arial" SIZE="2">WBEM_E_TRANSPORT_FAILURE</font></td>
|
||
<td WIDTH="413" VALIGN="TOP"><font FACE="Arial" SIZE="2">This indicates the failure of the
|
||
remote procedure call (RPC) link between the current process and CIMOM.</font></td>
|
||
</tr>
|
||
<tr>
|
||
<td WIDTH="230" VALIGN="TOP"><font FACE="Arial" SIZE="2">WBEM_S_NO_ERROR</font></td>
|
||
<td WIDTH="413" VALIGN="TOP"><font FACE="Arial" SIZE="2">The call succeeded.</font></td>
|
||
</tr>
|
||
</table>
|
||
<font FACE="Arial" SIZE="2">
|
||
|
||
<p>DCOM-specific error codes also may be returned if network problems cause you to lose
|
||
the remote connection to CIMOM.</font><font FACE="Arial Narrow"><b></p>
|
||
|
||
<p>See Also</b></font><font FACE="Arial" SIZE="2"></p>
|
||
|
||
<p><b>IWbemObjectSink</b></font><font FACE="Arial Narrow" SIZE="5" COLOR="#800000"></p>
|
||
|
||
<hr>
|
||
|
||
<p>‹^</font><font FACE="Arial Narrow" SIZE="5"><b># $ K + </b></font><font
|
||
FACE="Arial Narrow" SIZE="5" COLOR="#800000">›</font><b><font FACE="Arial Narrow"
|
||
SIZE="5">IWbemServices::GetObject</font><font FACE="Arial Narrow" SIZE="1" COLOR="#800000"><EFBFBD>@<40></font></b><font
|
||
SIZE="2" COLOR="#ff00ff"></p>
|
||
|
||
<p><span style=color:#FF0000></font><font FACE="Arial" SIZE="2" COLOR="#ff0000">[This
|
||
is preliminary documentation and subject to change.]</font><font SIZE="2" COLOR="#ff00ff"></span></font><font
|
||
FACE="Arial" SIZE="2"> </p>
|
||
|
||
<p>The <b>IWbemServices::GetObject</b> method retrieves a class or instance.</p>
|
||
|
||
<p>This method only retrieves objects from the namespace associated with the current <b>IWbemServices</b>
|
||
object.</font><font FACE="Lucida Sans Typewriter" SIZE="2"><b></p>
|
||
|
||
<p>HRESULT IWbemServices::GetObject(</p>
|
||
|
||
<p>[in] BSTR</b><i> strObjectPath</i><b>, </p>
|
||
|
||
<p>[in] LONG</b><i> lFlags</i><b>, </p>
|
||
|
||
<p>[in] IWbemContext</b><i> *pCtx</i><b>, </p>
|
||
|
||
<p>[out, OPTIONAL] IWbemClassObject</b><i> **ppObject</i><b>, </p>
|
||
|
||
<p>[out, OPTIONAL] IWbemCallResult</b><i> **ppCallResult </i><b></p>
|
||
|
||
<p>);</b></p>
|
||
|
||
<p></font><font FACE="Arial Narrow"><b> </p>
|
||
|
||
<p>Parameters</b></font><font FACE="Arial" SIZE="2"><i></p>
|
||
|
||
<p>strObjectPath</p>
|
||
|
||
<blockquote>
|
||
</i><p>The object path of the object to retrieve. If this is NULL, an empty object is
|
||
returned that can become a new class. See Class Creation</font><font FACE="Arial" SIZE="2"
|
||
COLOR="#800000">_hmm_Declaring_Classes</font><font FACE="Arial" SIZE="2">.</p>
|
||
</blockquote>
|
||
|
||
<p><i> </p>
|
||
|
||
<p>lFlags</p>
|
||
|
||
<blockquote>
|
||
</i><p>This parameter can be set to zero to make this a synchronous call. Otherwise, to
|
||
make this a semisynchronous call set <i>lFlags</i> to WBEM_FLAG_RETURN_IMMEDIATELY,
|
||
provide a valid pointer for the <i>ppCallResult</i> parameter and this call will return
|
||
immediately. See Making a Semisynchronous Call</font><font FACE="Arial" SIZE="2"
|
||
COLOR="#800000">_hmm_Making_a_Semisynchronous_Call</font><font FACE="Arial" SIZE="2"> for
|
||
more information on semisynchronous calls.</p>
|
||
</blockquote>
|
||
|
||
<p><i> </p>
|
||
|
||
<p>pCtx</p>
|
||
|
||
<blockquote>
|
||
</i><p>Typically NULL. Otherwise, this is a pointer to an <b>IWbemContext</b> object that
|
||
may be used by the provider that is producing the requested class or instance. The values
|
||
in the context object must be specified in the documentation for the provider in question.
|
||
See Making Calls to CIMOM</font><font FACE="Arial" SIZE="2" COLOR="#800000">_hmm_Making_Calls_to_CIMOM</font><font
|
||
FACE="Arial" SIZE="2"> for more information about this parameter.</p>
|
||
</blockquote>
|
||
|
||
<p><i> </p>
|
||
|
||
<p>ppObject</p>
|
||
|
||
<blockquote>
|
||
</i><p>If not NULL, this receives the object, if it is found. The returned object has a
|
||
positive reference count. The caller must use <b>Release</b> when the object is no longer
|
||
needed. In all cases of error, this parameter is set to point to NULL.</p>
|
||
</blockquote>
|
||
|
||
<p><i> </p>
|
||
|
||
<p>ppCallResult</p>
|
||
|
||
<blockquote>
|
||
</i><p>If NULL, this parameter is not used. If the <i>lFlags </i>parameter contains
|
||
WBEM_FLAG_RETURN_IMMEDIATELY, this call will return immediately with WBEM_S_NO_ERROR. The <i>ppCallResult
|
||
</i>parameter<i> </i>will receive a pointer to a new <b>IWbemCallResult</b></font><font
|
||
FACE="Arial" SIZE="2" COLOR="#800000">_hmm_IWbemCallResult</font><font FACE="Arial"
|
||
SIZE="2"> object, which can then be polled to obtain the result using the <b>GetCallStatus</b></font><font
|
||
FACE="Arial" SIZE="2" COLOR="#800000">_hmm_IWbemCallresult_GetCallStatus</font><font
|
||
FACE="Arial" SIZE="2"><i> </i>method. The caller can call <b>IWbemCallResult::GetResultObject</b></font><font
|
||
FACE="Arial" SIZE="2" COLOR="#800000">_hmm_IWbemCallResult_GetResultObject</font><font
|
||
FACE="Arial" SIZE="2"><i> </i>to retrieve the object when it becomes available. </p>
|
||
</font><font FACE="Arial" SIZE="1"><p></font> </p>
|
||
</blockquote>
|
||
|
||
<p><font FACE="Arial Narrow"><b> </p>
|
||
|
||
<p>Return Values</b></font></p>
|
||
|
||
<table CELLSPACING="0" BORDER="0" WIDTH="463">
|
||
<tr>
|
||
<td WIDTH="50%" VALIGN="TOP"><font FACE="Arial" SIZE="2">WBEM_E_ACCESS_DENIED</font></td>
|
||
<td WIDTH="50%" VALIGN="TOP"><font FACE="Arial" SIZE="2">The current user does not have
|
||
permission to access the object.</font></td>
|
||
</tr>
|
||
<tr>
|
||
<td WIDTH="50%" VALIGN="TOP"><font FACE="Arial" SIZE="2">WBEM_E_FAILED</font></td>
|
||
<td WIDTH="50%" VALIGN="TOP"><font FACE="Arial" SIZE="2">This indicates other unspecified
|
||
errors.</font></td>
|
||
</tr>
|
||
<tr>
|
||
<td WIDTH="50%" VALIGN="TOP"><font FACE="Arial" SIZE="2">WBEM_E_INVALID_CLASS</font></td>
|
||
<td WIDTH="50%" VALIGN="TOP"><font FACE="Arial" SIZE="2">The specified class does not
|
||
exist.</font></td>
|
||
</tr>
|
||
<tr>
|
||
<td WIDTH="50%" VALIGN="TOP"><font FACE="Arial" SIZE="2">WBEM_E_INVALID_PARAMETER</font></td>
|
||
<td WIDTH="50%" VALIGN="TOP"><font FACE="Arial" SIZE="2">An invalid parameter was
|
||
specified.</font></td>
|
||
</tr>
|
||
<tr>
|
||
<td WIDTH="50%" VALIGN="TOP"><font FACE="Arial" SIZE="2">WBEM_E_INVALID_PATH</font></td>
|
||
<td WIDTH="50%" VALIGN="TOP"><font FACE="Arial" SIZE="2">The specified path was invalid.</font></td>
|
||
</tr>
|
||
<tr>
|
||
<td WIDTH="50%" VALIGN="TOP"><font FACE="Arial" SIZE="2">WBEM_E_NOT_FOUND</font></td>
|
||
<td WIDTH="50%" VALIGN="TOP"><font FACE="Arial" SIZE="2">The requested object could not be
|
||
found.</font></td>
|
||
</tr>
|
||
<tr>
|
||
<td WIDTH="50%" VALIGN="TOP"><font FACE="Arial" SIZE="2">WBEM_E_OUT_OF_MEMORY</font></td>
|
||
<td WIDTH="50%" VALIGN="TOP"><font FACE="Arial" SIZE="2">There was not enough memory to
|
||
complete the operation.</font></td>
|
||
</tr>
|
||
<tr>
|
||
<td WIDTH="50%" VALIGN="TOP"><font FACE="Arial" SIZE="2">WBEM_E_TRANSPORT_FAILURE</font></td>
|
||
<td WIDTH="50%" VALIGN="TOP"><font FACE="Arial" SIZE="2">This indicates the failure of the
|
||
remote procedure call (RPC) link between the current process and CIMOM.</font></td>
|
||
</tr>
|
||
<tr>
|
||
<td WIDTH="50%" VALIGN="TOP"><font FACE="Arial" SIZE="2">WBEM_S_NO_ERROR</font></td>
|
||
<td WIDTH="50%" VALIGN="TOP"><font FACE="Arial" SIZE="2">The call succeeded.</font></td>
|
||
</tr>
|
||
</table>
|
||
|
||
<p><font FACE="Arial" SIZE="2"> </p>
|
||
|
||
<p>On failure, you can obtain any available information from the COM function <b>GetErrorInfo</b>.
|
||
</p>
|
||
|
||
<p>DCOM-specific error codes also may be returned if network problems cause you to lose
|
||
the remote connection to CIMOM.</font><font FACE="Arial Narrow"><b></p>
|
||
|
||
<p>See Also</b></font><font FACE="Arial" SIZE="2"></p>
|
||
|
||
<p>Class Creation</font><font FACE="Arial" SIZE="2" COLOR="#800000">_hmm_Declaring_Classes</font><font
|
||
FACE="Arial" SIZE="2">, Error Handling for Applications</font><font FACE="Arial" SIZE="2"
|
||
COLOR="#800000">_hmm_Error_Handling_for_Applications</font><font FACE="Arial" SIZE="2">, <b>IWbemCallResult</b></font><font
|
||
FACE="Arial" SIZE="2" COLOR="#800000">_hmm_IWbemCallResult</font><font FACE="Arial"
|
||
SIZE="2">, <b>IWbemServices::GetObjectAsync</b></font><font FACE="Arial" SIZE="2"
|
||
COLOR="#800000">_hmm_IWbemServices_GetObjectAsync</font><font FACE="Arial" SIZE="2">,
|
||
Object Paths</font><font FACE="Arial" SIZE="2" COLOR="#800000">_hmm_Object_Paths</font><font
|
||
FACE="Arial Narrow" SIZE="5" COLOR="#800000"></p>
|
||
|
||
<p>‹^</font><font FACE="Arial Narrow" SIZE="5"><b># $ K + </b></font><font
|
||
FACE="Arial Narrow" SIZE="5" COLOR="#800000">›</font><b><font FACE="Arial Narrow"
|
||
SIZE="5">IWbemServices::GetObjectAsync</font><font FACE="Arial Narrow" SIZE="1"
|
||
COLOR="#800000"><EFBFBD>@<40></font></b><font SIZE="2" COLOR="#ff00ff"></p>
|
||
|
||
<p><span style=color:#FF0000></font><font FACE="Arial" SIZE="2" COLOR="#ff0000">[This
|
||
is preliminary documentation and subject to change.]</font><font SIZE="2" COLOR="#ff00ff"></span></font><font
|
||
FACE="Arial" SIZE="2"> </p>
|
||
|
||
<p>The <b>IWbemServices::GetObjectAsync</b> method retrieves an object, either a class
|
||
definition or instance, based on its path. This is similar to <b>IWbemServices::GetObject</b></font><font
|
||
FACE="Arial" SIZE="2" COLOR="#800000">_hmm_IWbemServices_GetObject</font><font
|
||
FACE="Arial" SIZE="2"> except that the call returns immediately, and the object is
|
||
provided to the supplied object sink.</p>
|
||
|
||
<p>Currently, this method retrieves objects only from the namespace associated with the <b>IWbemServices</b>
|
||
pointer. </font><font FACE="Lucida Sans Typewriter" SIZE="2"><b></p>
|
||
|
||
<p>HRESULT IWbemServices::GetObjectAsync(</p>
|
||
|
||
<p>[in] BSTR</b><i> strObjectPath</i><b>,</p>
|
||
|
||
<p>[in] LONG</b><i> lFlags</i><b>,</p>
|
||
|
||
<p>[in] IWbemContext</b><i> *pCtx</i><b>,</p>
|
||
|
||
<p>[in] IWbemObjectSink</b><i> *pResponseHandler</i><b> </p>
|
||
|
||
<p>);</b></p>
|
||
|
||
<p></font><font FACE="Arial Narrow"><b> </p>
|
||
|
||
<p>Parameters</b></font><font FACE="Arial" SIZE="2"><i></p>
|
||
|
||
<p>strObjectPath</p>
|
||
|
||
<blockquote>
|
||
</i><p>The object path of the object to retrieve. If this is NULL, an empty object, which
|
||
can become a new class, is returned. See Class Creation</font><font FACE="Arial" SIZE="2"
|
||
COLOR="#800000">_hmm_Declaring_Classes</font><font FACE="Arial" SIZE="2">.</p>
|
||
</blockquote>
|
||
|
||
<p><i> </p>
|
||
|
||
<p>lFlags</p>
|
||
|
||
<blockquote>
|
||
</i><p>WBEM_FLAG_SEND_STATUS registers with CIMOM a request to receive intermediate status
|
||
reports through the clients implementation of <b>IWbemObjectSink::SetStatus</b>.</p>
|
||
</blockquote>
|
||
|
||
<p><i> </p>
|
||
|
||
<p>pCtx</p>
|
||
|
||
<blockquote>
|
||
</i><p>Typically NULL. Otherwise, this is a pointer to an <b>IWbemContext</b> object that
|
||
may be used by the provider that is producing the requested class or instance. The values
|
||
in the context object must be specified in the documentation for the provider in question.
|
||
See Making Calls to CIMOM</font><font FACE="Arial" SIZE="2" COLOR="#800000">_hmm_Making_Calls_to_CIMOM</font><font
|
||
FACE="Arial" SIZE="2"> for more information about this parameter.</p>
|
||
</blockquote>
|
||
|
||
<p><i> </p>
|
||
|
||
<p>pResponseHandler</p>
|
||
|
||
<blockquote>
|
||
</i><p>Points to the caller's implementation of <b>IWbemObjectSink</b></font><font
|
||
FACE="Arial" SIZE="2" COLOR="#800000">_hmm_IWbemObjectSink</font><font FACE="Arial"
|
||
SIZE="2">. This handler receives the requested object when it becomes available through
|
||
the <b>IWbemObjectSink::SetStatus</b></font><font FACE="Arial" SIZE="2" COLOR="#800000">_hmm_IWbemObjectSink_SetStatus</font><font
|
||
FACE="Arial" SIZE="2"> method. The <i>pObjParam </i>parameter contains the object. If any
|
||
error code is returned, then the supplied <b>IWbemObjectSink</b> pointer will not be used.
|
||
If WBEM_S_NO_ERROR is returned, then the user's <b>IWbemObjectSink</b> implementation will
|
||
be called to indicate the result of the operation. CIMOM only calls <b>AddRef</b> to the
|
||
pointer in cases where WBEM_S_NO_ERROR returns. In cases where an error code returns, the
|
||
reference count is the same as on entry. For a detailed explanation of this parameter, see
|
||
also Asynchronous Methods</font><font FACE="Arial" SIZE="2" COLOR="#800000">_hmm_making_an_asynchronous_call</font><font
|
||
FACE="Arial" SIZE="2">.</p>
|
||
</font><font FACE="Arial" SIZE="1"><p></font> </p>
|
||
</blockquote>
|
||
|
||
<p><font FACE="Arial Narrow"><b> </p>
|
||
|
||
<p>Return Values</b></font></p>
|
||
|
||
<table CELLSPACING="0" BORDER="0" WIDTH="463">
|
||
<tr>
|
||
<td WIDTH="50%" VALIGN="TOP"><font FACE="Arial" SIZE="2">WBEM_E_FAILED</font></td>
|
||
<td WIDTH="50%" VALIGN="TOP"><font FACE="Arial" SIZE="2">Other error codes are returned
|
||
asynchronously to the <b>IWbemObjectSink</b>.</font></td>
|
||
</tr>
|
||
<tr>
|
||
<td WIDTH="50%" VALIGN="TOP"><font FACE="Arial" SIZE="2">WBEM_E_INVALID_PARAMETER</font></td>
|
||
<td WIDTH="50%" VALIGN="TOP"><font FACE="Arial" SIZE="2">An invalid parameter was
|
||
specified.</font></td>
|
||
</tr>
|
||
<tr>
|
||
<td WIDTH="50%" VALIGN="TOP"><font FACE="Arial" SIZE="2">WBEM_E_INVALID_CLASS</font></td>
|
||
<td WIDTH="50%" VALIGN="TOP"><font FACE="Arial" SIZE="2">The specified class does not
|
||
exist.</font></td>
|
||
</tr>
|
||
<tr>
|
||
<td WIDTH="50%" VALIGN="TOP"><font FACE="Arial" SIZE="2">WBEM_E_INVALID_PATH</font></td>
|
||
<td WIDTH="50%" VALIGN="TOP"><font FACE="Arial" SIZE="2">The specified object path was
|
||
invalid.</font></td>
|
||
</tr>
|
||
<tr>
|
||
<td WIDTH="50%" VALIGN="TOP"><font FACE="Arial" SIZE="2">WBEM_S_NO_ERROR</font></td>
|
||
<td WIDTH="50%" VALIGN="TOP"><font FACE="Arial" SIZE="2">The call succeeded.</font></td>
|
||
</tr>
|
||
</table>
|
||
|
||
<p><font FACE="Arial" SIZE="2"> </p>
|
||
|
||
<p>On failure, you can obtain any available information from the COM function <b>GetErrorInfo</b>.</p>
|
||
|
||
<p>DCOM-specific error codes also may be returned if network problems cause you to lose
|
||
the remote connection to CIMOM.</font><font FACE="Arial Narrow"><b></p>
|
||
|
||
<p>See Also</b></font><font FACE="Arial" SIZE="2"></p>
|
||
|
||
<p>Making an Asynchronous Call</font><font FACE="Arial" SIZE="2" COLOR="#800000">_hmm_Making_an_Asynchronous_Call</font><font
|
||
FACE="Arial" SIZE="2">, Class Creation</font><font FACE="Arial" SIZE="2" COLOR="#800000">_hmm_Declaring_Classes</font><font
|
||
FACE="Arial" SIZE="2">, <b>IWbemServices::GetObject</b></font><font FACE="Arial" SIZE="2"
|
||
COLOR="#800000">_hmm_IWbemServices_GetObject</font><font FACE="Arial" SIZE="2">, Object
|
||
Paths</font><font FACE="Arial" SIZE="2" COLOR="#800000">_hmm_Object_Paths</font><font
|
||
FACE="Arial Narrow" SIZE="5" COLOR="#800000"></p>
|
||
|
||
<p>‹^</font><font FACE="Arial Narrow" SIZE="5"><b># $ K + </b></font><font
|
||
FACE="Arial Narrow" SIZE="5" COLOR="#800000">›</font><b><font FACE="Arial Narrow"
|
||
SIZE="5">IWbemServices::PutClass</font><font FACE="Arial Narrow" SIZE="1" COLOR="#800000"><EFBFBD>@<40></font></b><font
|
||
SIZE="2" COLOR="#ff00ff"></p>
|
||
|
||
<p><span style=color:#FF0000></font><font FACE="Arial" SIZE="2" COLOR="#ff0000">[This
|
||
is preliminary documentation and subject to change.]</font><font SIZE="2" COLOR="#ff00ff"></span></font><font
|
||
FACE="Arial" SIZE="2"> </p>
|
||
|
||
<p>The <b>IWbemServices::PutClass</b> method creates a new class or updates an existing
|
||
one. The class specified by the <i>pObject</i> parameter must have been correctly
|
||
initialized with all of the required property values.</p>
|
||
|
||
<p>The user may not create classes with names that begin or end with an underscore. This
|
||
is reserved for system classes.</font><font FACE="Lucida Sans Typewriter" SIZE="2"><b></p>
|
||
|
||
<p>HRESULT IWbemServices::PutClass(</p>
|
||
|
||
<p>[in] IWbemClassObject</b><i> *pObject</i><b>, </p>
|
||
|
||
<p>[in] LONG</b><i> lFlags</i><b>, </p>
|
||
|
||
<p>[in] IWbemContext</b><i> *pCtx</i><b>, </p>
|
||
|
||
<p>[out, OPTIONAL] IWbemCallResult</b><i> **ppCallResult </i><b></p>
|
||
|
||
<p>);</b></p>
|
||
|
||
<p></font><font FACE="Arial Narrow"><b> </p>
|
||
|
||
<p>Parameters</b></font><font FACE="Arial" SIZE="2"><i></p>
|
||
|
||
<p>pObject</p>
|
||
|
||
<blockquote>
|
||
</i><p>Must point to a valid class definition. The reference count is not changed.</p>
|
||
</blockquote>
|
||
|
||
<p><i> </p>
|
||
|
||
<p>lFlags</p>
|
||
|
||
<blockquote>
|
||
</i><p>The following flags affect the behavior of this method.</font></p>
|
||
</blockquote>
|
||
|
||
<p ALIGN="LEFT"> </p>
|
||
|
||
<table CELLSPACING="0" BORDER="0" WIDTH="445">
|
||
<tr>
|
||
<td WIDTH="53%" VALIGN="TOP"><font FACE="Arial" SIZE="2"><b>Flag</b> </font></td>
|
||
<td WIDTH="47%" VALIGN="TOP"><font FACE="Arial" SIZE="2"><b>Description</b></font></td>
|
||
</tr>
|
||
<tr>
|
||
<td WIDTH="53%" VALIGN="TOP"><font FACE="Arial" SIZE="2">WBEM_FLAG_CREATE_OR_UPDATE</font></td>
|
||
<td WIDTH="47%" VALIGN="TOP"><font FACE="Arial" SIZE="2">This flag causes the class to be
|
||
created if it does not exist or overwritten if it exists already.</font></td>
|
||
</tr>
|
||
<tr>
|
||
<td WIDTH="53%" VALIGN="TOP"><font FACE="Arial" SIZE="2">WBEM_FLAG_UPDATE_ONLY</font></td>
|
||
<td WIDTH="47%" VALIGN="TOP"><font FACE="Arial" SIZE="2">This flag causes this call to
|
||
update. The class must exist for the call to be successful.</font></td>
|
||
</tr>
|
||
<tr>
|
||
<td WIDTH="53%" VALIGN="TOP"><font FACE="Arial" SIZE="2">WBEM_FLAG_CREATE_ONLY</font></td>
|
||
<td WIDTH="47%" VALIGN="TOP"><font FACE="Arial" SIZE="2">This flag is used for creation
|
||
only. The call will fail if the class already exists.</font></td>
|
||
</tr>
|
||
<tr>
|
||
<td WIDTH="53%" VALIGN="TOP"><font FACE="Arial" SIZE="2">WBEM_FLAG_RETURN_IMMEDIATELY </font></td>
|
||
<td WIDTH="47%" VALIGN="TOP"><font FACE="Arial" SIZE="2">This flag causes this to be a
|
||
semisycnronous call. See Making a Semisynchronous Call</font><font FACE="Arial" SIZE="2"
|
||
COLOR="#800000">_hmm_making_a_semisynchronous_call</font><font FACE="Arial" SIZE="2"> for
|
||
more information on semisynchronous calls.</font></td>
|
||
</tr>
|
||
<tr>
|
||
<td WIDTH="53%" VALIGN="TOP"><font FACE="Arial" SIZE="2">WBEM_FLAG_OWNER_UPDATE</font></td>
|
||
<td WIDTH="47%" VALIGN="TOP"><font FACE="Arial" SIZE="2">Push providers must specify this
|
||
flag when calling <b>PutClass</b> to indicate that this class has changed.</font></td>
|
||
</tr>
|
||
</table>
|
||
|
||
<p><font FACE="Arial" SIZE="2"><i> </p>
|
||
|
||
<p>pCtx</i></p>
|
||
|
||
<p>Typically NULL. Otherwise, this is a pointer to an <b>IWbemContext</b> object required
|
||
by the dynamic class provider that is producing the class instances. The values in the
|
||
context object must be specified in the documentation for the provider in question. See
|
||
Making Calls to CIMOM</font><font FACE="Arial" SIZE="2" COLOR="#800000">_hmm_Making_Calls_to_CIMOM</font><font
|
||
FACE="Arial" SIZE="2"> for more information about this parameter.</p>
|
||
|
||
<p><i> </p>
|
||
|
||
<p>ppCallResult</p>
|
||
|
||
<blockquote>
|
||
</i><p>If NULL, this parameter is not used. If the <i>lFlags </i>parameter contains
|
||
WBEM_FLAG_RETURN_IMMEDIATELY, this call will return immediately with WBEM_S_NO_ERROR. The <i>ppCallResult
|
||
</i>parameter<i> </i>will receive a pointer to a new <b>IWbemCallResult</b></font><font
|
||
FACE="Arial" SIZE="2" COLOR="#800000">_hmm_IWbemCallResult</font><font FACE="Arial"
|
||
SIZE="2"> object, which can then be polled to obtain the result using the <b>IWbemCallResult::GetCallStatus</b></font><font
|
||
FACE="Arial" SIZE="2" COLOR="#800000">_hmm_IWbemCallresult_GetCallStatus</font><font
|
||
FACE="Arial" SIZE="2"><i> </i>method.</p>
|
||
</font><font FACE="Arial" SIZE="1"><p></font> </p>
|
||
</blockquote>
|
||
|
||
<p><font FACE="Arial Narrow"><b> </p>
|
||
|
||
<p>Return Values</b></font></p>
|
||
|
||
<table CELLSPACING="0" BORDER="0" WIDTH="463">
|
||
<tr>
|
||
<td WIDTH="52%" VALIGN="TOP"><font FACE="Arial" SIZE="2">WBEM_E_ACCESS_DENIED</font></td>
|
||
<td WIDTH="48%" VALIGN="TOP"><font FACE="Arial" SIZE="2">The current user is not permitted
|
||
to create or modify classes.</font></td>
|
||
</tr>
|
||
<tr>
|
||
<td WIDTH="52%" VALIGN="TOP"><font FACE="Arial" SIZE="2">WBEM_E_FAILED</font></td>
|
||
<td WIDTH="48%" VALIGN="TOP"><font FACE="Arial" SIZE="2">This indicates other unspecified
|
||
errors.</font></td>
|
||
</tr>
|
||
<tr>
|
||
<td WIDTH="52%" VALIGN="TOP"><font FACE="Arial" SIZE="2">WBEM_E_INVALID_PARAMETER</font></td>
|
||
<td WIDTH="48%" VALIGN="TOP"><font FACE="Arial" SIZE="2">An invalid parameter was
|
||
specified.</font></td>
|
||
</tr>
|
||
<tr>
|
||
<td WIDTH="52%" VALIGN="TOP"><font FACE="Arial" SIZE="2">WBEM_E_INVALID_CLASS</font></td>
|
||
<td WIDTH="48%" VALIGN="TOP"><font FACE="Arial" SIZE="2">The class specified is invalid.
|
||
You will see this error if a instance object is specified in the <i>pObject </i>parameter</font></td>
|
||
</tr>
|
||
<tr>
|
||
<td WIDTH="52%" VALIGN="TOP"><font FACE="Arial" SIZE="2">WBEM_E_CLASS_HAS_CHILDREN</font></td>
|
||
<td WIDTH="48%" VALIGN="TOP"><font FACE="Arial" SIZE="2">An attempt was made to make a
|
||
change that would invalidate a subclass.</font></td>
|
||
</tr>
|
||
<tr>
|
||
<td WIDTH="52%" VALIGN="TOP"><font FACE="Arial" SIZE="2">WBEM_E_INCOMPLETE_CLASS</font></td>
|
||
<td WIDTH="48%" VALIGN="TOP"><font FACE="Arial" SIZE="2">The required properties for
|
||
classes have not all been set.</font></td>
|
||
</tr>
|
||
<tr>
|
||
<td WIDTH="52%" VALIGN="TOP"><font FACE="Arial" SIZE="2">WBEM_E_OUT_OF_MEMORY</font></td>
|
||
<td WIDTH="48%" VALIGN="TOP"><font FACE="Arial" SIZE="2">There was not enough memory to
|
||
complete the operation.</font></td>
|
||
</tr>
|
||
<tr>
|
||
<td WIDTH="52%" VALIGN="TOP"><font FACE="Arial" SIZE="2">WBEM_E_TRANSPORT_FAILURE</font></td>
|
||
<td WIDTH="48%" VALIGN="TOP"><font FACE="Arial" SIZE="2">This indicates the failure of the
|
||
remote procedure call (RPC) link between the current process and CIMOM.</font></td>
|
||
</tr>
|
||
<tr>
|
||
<td WIDTH="52%" VALIGN="TOP"><font FACE="Arial" SIZE="2">WBEM_S_NO_ERROR</font></td>
|
||
<td WIDTH="48%" VALIGN="TOP"><font FACE="Arial" SIZE="2">The call succeeded.</font></td>
|
||
</tr>
|
||
<tr>
|
||
<td WIDTH="52%" VALIGN="TOP"><font FACE="Arial" SIZE="2">WBEM_E_ALREADY_EXISTS</font></td>
|
||
<td WIDTH="48%" VALIGN="TOP"><font FACE="Arial" SIZE="2">WBEM_FLAG_CREATE_ONLY flag was
|
||
specified, but the class already exists.</font></td>
|
||
</tr>
|
||
<tr>
|
||
<td WIDTH="52%" VALIGN="TOP"><font FACE="Arial" SIZE="2">WBEM_E_NOT_FOUND</font></td>
|
||
<td WIDTH="48%" VALIGN="TOP"><font FACE="Arial" SIZE="2">WBEM_FLAG_UPDATE_ONLY was
|
||
specified in <i>lFlags</i>, and the <p>class was not found.</font></td>
|
||
</tr>
|
||
<tr>
|
||
<td WIDTH="52%" VALIGN="TOP"><font face="Arial" size="2">WBEM_E_INVALID_OPERATION</font></td>
|
||
<td WIDTH="48%" VALIGN="TOP"><font face="Arial" size="2">An invalid operation was
|
||
attempted. This would include actions such as attempting to put a class with a name
|
||
beginning with "__" characters which is reserved for system classes.</font></td>
|
||
</tr>
|
||
</table>
|
||
|
||
<p><font FACE="Arial" SIZE="2"> </p>
|
||
|
||
<p>On failure, you can obtain any available information from the COM function <b>GetErrorInfo</b>.</p>
|
||
|
||
<p>DCOM-specific error codes also may be returned if network problems cause you to lose
|
||
the remote connection to CIMOM.</font><font FACE="Arial Narrow"><b></p>
|
||
|
||
<p>See Also</b></font><font FACE="Arial" SIZE="2"></p>
|
||
|
||
<p>Class Creation and Modification Rules</font><font FACE="Arial" SIZE="2" COLOR="#800000">_hmm_Declaring_Classes</font><font
|
||
FACE="Arial" SIZE="2">, Error Handling for Applications</font><font FACE="Arial" SIZE="2"
|
||
COLOR="#800000">_hmm_Error_Handling_for_Applications</font><font FACE="Arial" SIZE="2">, <b>IWbemCallResult</b></font><font
|
||
FACE="Arial" SIZE="2" COLOR="#800000">_hmm_IWbemCallResult</font><font FACE="Arial Narrow"
|
||
SIZE="5" COLOR="#800000"></p>
|
||
|
||
<p>‹^</font><font FACE="Arial Narrow" SIZE="5"><b># $ K + </b></font><font
|
||
FACE="Arial Narrow" SIZE="5" COLOR="#800000">›</font><b><font FACE="Arial Narrow"
|
||
SIZE="5">IWbemServices::PutClassAsync</font><font FACE="Arial Narrow" SIZE="1"
|
||
COLOR="#800000"><EFBFBD>@<40></font></b><font SIZE="2" COLOR="#ff00ff"></p>
|
||
|
||
<p><span style=color:#FF0000></font><font FACE="Arial" SIZE="2" COLOR="#ff0000">[This
|
||
is preliminary documentation and subject to change.]</font><font SIZE="2" COLOR="#ff00ff"></span></font><font
|
||
FACE="Arial" SIZE="2"> </p>
|
||
|
||
<p>The <b>IWbemServices::PutClassAsync</b> method creates a new class, or it updates an
|
||
existing one. The class specified by the <i>pObject</i> parameter must be correctly
|
||
initialized with all of the required property values. The call immediately returns.
|
||
Success or failure is supplied to the object sink specified by the <i>pResponseHandler</i>
|
||
parameter.</font><font FACE="Lucida Sans Typewriter" SIZE="2"><b></p>
|
||
|
||
<p>HRESULT IWbemServices::PutClassAsync(</p>
|
||
|
||
<p>[in] IWbemClassObject</b><i> *pObject</i><b>, </p>
|
||
|
||
<p>[in] LONG</b><i> lFlags</i><b>, </p>
|
||
|
||
<p>[in] IWbemContext</b><i> *pCtx</i><b>, </p>
|
||
|
||
<p>[in] IWbemObjectSink</b><i> *pResponseHandler </i><b></p>
|
||
|
||
<p>);</b></p>
|
||
|
||
<p></font><font FACE="Arial Narrow"><b> </p>
|
||
|
||
<p>Parameters</b></font><font FACE="Arial" SIZE="2"><i></p>
|
||
|
||
<p>pObject</p>
|
||
|
||
<blockquote>
|
||
</i><p>Points to the object containing the class definition.</p>
|
||
</blockquote>
|
||
|
||
<p><i> </p>
|
||
|
||
<p>lFlags</i></font></p>
|
||
|
||
<p ALIGN="LEFT"> </p>
|
||
|
||
<table CELLSPACING="0" BORDER="0" WIDTH="445">
|
||
<tr>
|
||
<td WIDTH="53%" VALIGN="TOP"><font FACE="Arial" SIZE="2"><b>Flag</b></font></td>
|
||
<td WIDTH="47%" VALIGN="TOP"><font FACE="Arial" SIZE="2"><b>Description</b></font></td>
|
||
</tr>
|
||
<tr>
|
||
<td WIDTH="53%" VALIGN="TOP"><font FACE="Arial" SIZE="2">WBEM_FLAG_CREATE_OR_UPDATE</font></td>
|
||
<td WIDTH="47%" VALIGN="TOP"><font FACE="Arial" SIZE="2">This flag causes this class to be
|
||
created if it does not exist or be overwritten if it exists already. </font></td>
|
||
</tr>
|
||
<tr>
|
||
<td WIDTH="53%" VALIGN="TOP"><font FACE="Arial" SIZE="2">WBEM_FLAG_UPDATE_ONLY</font></td>
|
||
<td WIDTH="47%" VALIGN="TOP"><font FACE="Arial" SIZE="2">Updates an existing class</font></td>
|
||
</tr>
|
||
<tr>
|
||
<td WIDTH="53%" VALIGN="TOP"><font FACE="Arial" SIZE="2">WBEM_FLAG_CREATE_ONLY</font></td>
|
||
<td WIDTH="47%" VALIGN="TOP"><font FACE="Arial" SIZE="2">This flag is for class creation
|
||
only. The call will fail if the class already exists.</font></td>
|
||
</tr>
|
||
<tr>
|
||
<td WIDTH="53%" VALIGN="TOP"><font FACE="Arial" SIZE="2">WBEM_FLAG_SEND_STATUS </font></td>
|
||
<td WIDTH="47%" VALIGN="TOP"><font FACE="Arial" SIZE="2">registers with CIMOM a request to
|
||
receive intermediate status reports through the clients implementation of <b>IWbemObjectSink::SetStatus</b>.</font></td>
|
||
</tr>
|
||
<tr>
|
||
<td WIDTH="53%" VALIGN="TOP"><font FACE="Arial" SIZE="2">WBEM_FLAG_OWNER_UPDATE</font></td>
|
||
<td WIDTH="47%" VALIGN="TOP"><font FACE="Arial" SIZE="2">Push providers must specify this
|
||
flag when calling <b>PutClassAsync</b> to indicate that this class has changed.</font></td>
|
||
</tr>
|
||
</table>
|
||
|
||
<p><font FACE="Arial" SIZE="2"><i> </p>
|
||
|
||
<p>pCtx</p>
|
||
|
||
<blockquote>
|
||
</i><p>Typically NULL. Otherwise, this is a pointer to an <b>IWbemContext</b> object that
|
||
may be used by the provider that is receiving the requested class. The values in the
|
||
context object must be specified in the documentation for the provider in question. See
|
||
Making Calls to CIMOM</font><font FACE="Arial" SIZE="2" COLOR="#800000">_hmm_Making_Calls_to_CIMOM</font><font
|
||
FACE="Arial" SIZE="2"> for more information about this parameter.</p>
|
||
</blockquote>
|
||
|
||
<p><i> </p>
|
||
|
||
<p>pResponseHandler</p>
|
||
|
||
<blockquote>
|
||
</i><p>Points to the caller's implementation of <b>IWbemObjectSink</b></font><font
|
||
FACE="Arial" SIZE="2" COLOR="#800000">_hmm_IWbemObjectSink</font><font FACE="Arial"
|
||
SIZE="2">. This handler receives the status of the <b>Put</b> request when the status
|
||
becomes available using the <b>SetStatus</b></font><font FACE="Arial" SIZE="2"
|
||
COLOR="#800000">_hmm_IWbemObjectSink_SetStatus</font><font FACE="Arial" SIZE="2"> method.
|
||
If any error code is returned, then the supplied IWbemObjectSink pointer will not be used.
|
||
If WBEM_S_NO_ERROR is returned, then the user's IWbemObjectSink implementation will be
|
||
called to indicate the result of the operation. CIMOM only calls <b>AddRef</b> to the
|
||
pointer in cases where WBEM_S_NO_ERROR returns. In cases where an error code returns, the
|
||
reference count is the same as on entry. For a detailed explanation of this parameter, see
|
||
Making an Asynchronous Call</font><font FACE="Arial" SIZE="2" COLOR="#800000">_hmm_Making_an_Asynchronous_Call</font><font
|
||
FACE="Arial" SIZE="2">. </p>
|
||
</font><font FACE="Arial" SIZE="1"><p></font> </p>
|
||
</blockquote>
|
||
|
||
<p><font FACE="Arial Narrow"><b> </p>
|
||
|
||
<p>Return Values</b></font></p>
|
||
|
||
<table CELLSPACING="0" BORDER="0" WIDTH="463">
|
||
<tr>
|
||
<td WIDTH="52%" VALIGN="TOP"><font FACE="Arial" SIZE="2">WBEM_E_ACCESS_DENIED</font></td>
|
||
<td WIDTH="48%" VALIGN="TOP"><font FACE="Arial" SIZE="2">The current user does not have
|
||
permission to create classes.</font></td>
|
||
</tr>
|
||
<tr>
|
||
<td WIDTH="52%" VALIGN="TOP"><font FACE="Arial" SIZE="2">WBEM_E_ALREADY_EXISTS</font></td>
|
||
<td WIDTH="48%" VALIGN="TOP"><font FACE="Arial" SIZE="2">WBEM_FLAG_CREATE_ONLY flag was
|
||
specified, but the class already exists.</font></td>
|
||
</tr>
|
||
<tr>
|
||
<td WIDTH="52%" VALIGN="TOP"><font FACE="Arial" SIZE="2">WBEM_E_FAILED</font></td>
|
||
<td WIDTH="48%" VALIGN="TOP"><font FACE="Arial" SIZE="2">This is an unspecified failure.</font></td>
|
||
</tr>
|
||
<tr>
|
||
<td WIDTH="52%" VALIGN="TOP"><font FACE="Arial" SIZE="2">WBEM_E_INVALID_CLASS</font></td>
|
||
<td WIDTH="48%" VALIGN="TOP"><font FACE="Arial" SIZE="2">The class specified is invalid.
|
||
You will see this error if a instance object is specified in the <i>pObject </i>parameter</font></td>
|
||
</tr>
|
||
<tr>
|
||
<td WIDTH="52%" VALIGN="TOP"><font FACE="Arial" SIZE="2">WBEM_E_CLASS_HAS_CHILDREN</font></td>
|
||
<td WIDTH="48%" VALIGN="TOP"><font FACE="Arial" SIZE="2">An attempt was made to make a
|
||
change that would invalidate a subclass.</font></td>
|
||
</tr>
|
||
<tr>
|
||
<td WIDTH="52%" VALIGN="TOP"><font FACE="Arial" SIZE="2">WBEM_E_INCOMPLETE_CLASS</font></td>
|
||
<td WIDTH="48%" VALIGN="TOP"><font FACE="Arial" SIZE="2">The required properties for
|
||
classes have not all been set.</font></td>
|
||
</tr>
|
||
<tr>
|
||
<td WIDTH="52%" VALIGN="TOP"><font FACE="Arial" SIZE="2">WBEM_E_INVALID_PARAMETER</font></td>
|
||
<td WIDTH="48%" VALIGN="TOP"><font FACE="Arial" SIZE="2">An invalid parameter was
|
||
specified.</font></td>
|
||
</tr>
|
||
<tr>
|
||
<td WIDTH="52%" VALIGN="TOP"><font FACE="Arial" SIZE="2">WBEM_E_NOT_FOUND</font></td>
|
||
<td WIDTH="48%" VALIGN="TOP"><font FACE="Arial" SIZE="2">WBEM_FLAG_UPDATE_ONLY flag was
|
||
specified, but the class does not exist.</font></td>
|
||
</tr>
|
||
<tr>
|
||
<td WIDTH="52%" VALIGN="TOP"><font FACE="Arial" SIZE="2">WBEM_E_OUT_OF_MEMORY</font></td>
|
||
<td WIDTH="48%" VALIGN="TOP"><font FACE="Arial" SIZE="2">There was not enough memory to
|
||
complete the operation.</font></td>
|
||
</tr>
|
||
<tr>
|
||
<td WIDTH="52%" VALIGN="TOP"><font FACE="Arial" SIZE="2">WBEM_E_TRANSPORT_FAILURE</font></td>
|
||
<td WIDTH="48%" VALIGN="TOP"><font FACE="Arial" SIZE="2">This indicates the failure of the
|
||
remote procedure call (RPC) link between the current process and CIMOM.</font></td>
|
||
</tr>
|
||
<tr>
|
||
<td WIDTH="52%" VALIGN="TOP"><font FACE="Arial" SIZE="2">WBEM_S_NO_ERROR </font></td>
|
||
<td WIDTH="48%" VALIGN="TOP"><font FACE="Arial" SIZE="2">The call succeeded.</font></td>
|
||
</tr>
|
||
</table>
|
||
|
||
<p><font FACE="Arial" SIZE="2"> </p>
|
||
|
||
<p>Other status or error codes are reported to the object sink specified by the <i>pReponseHandler</i>
|
||
parameter.</p>
|
||
|
||
<p>DCOM-specific error codes also may be returned if network problems cause you to lose
|
||
the remote connection to CIMOM.</font><font FACE="Arial Narrow"><b></p>
|
||
|
||
<p>See Also</b></font><font FACE="Arial" SIZE="2"></p>
|
||
|
||
<p>Making an Asynchronous Call</font><font FACE="Arial" SIZE="2" COLOR="#800000">_hmm_Making_an_Asynchronous_Call</font><font
|
||
FACE="Arial" SIZE="2">, Class Creation and Modification Rules</font><font FACE="Arial"
|
||
SIZE="2" COLOR="#800000">_hmm_Declaring_Classes</font><font FACE="Arial" SIZE="2">, <b>IWbemServices::PutClass</b></font><font
|
||
FACE="Arial" SIZE="2" COLOR="#800000">_hmm_IWbemServices_PutClass</font><font
|
||
FACE="Arial Narrow" SIZE="5" COLOR="#800000"></p>
|
||
|
||
<p>‹^</font><font FACE="Arial Narrow" SIZE="5"><b># $ K + </b></font><font
|
||
FACE="Arial Narrow" SIZE="5" COLOR="#800000">›</font><b><font FACE="Arial Narrow"
|
||
SIZE="5">IWbemServices::DeleteClass</font><font FACE="Arial Narrow" SIZE="1"
|
||
COLOR="#800000"><EFBFBD>@<40></font></b><font SIZE="2" COLOR="#ff00ff"></p>
|
||
|
||
<p><span style=color:#FF0000></font><font FACE="Arial" SIZE="2" COLOR="#ff0000">[This
|
||
is preliminary documentation and subject to change.]</font><font SIZE="2" COLOR="#ff00ff"></span></font><font
|
||
FACE="Arial" SIZE="2"> </p>
|
||
|
||
<p>The <b>IWbemServices::DeleteClass</b> method deletes the specified class from the
|
||
current namespace. If a dynamic instance provider is associated with the class, the
|
||
provider is unregistered, and it is no longer called for by that class. Any classes that
|
||
derive from the deleted class are also deleted, and their associated providers are
|
||
unregistered. All outstanding static instances of the specified class and its subclasses
|
||
are also deleted when the class is deleted.</p>
|
||
|
||
<p>If a dynamic class provider provides the class, the success of the deletion depends on
|
||
whether the provider supports class deletion. </font><font FACE="Arial Narrow" SIZE="3"><b></p>
|
||
|
||
<p>Note</p>
|
||
|
||
<blockquote>
|
||
</b></font><font FACE="Arial" SIZE="2"><p>System classes cannot be deleted.</p>
|
||
</font>
|
||
</blockquote>
|
||
|
||
<p><font FACE="Lucida Sans Typewriter" SIZE="2"><b> </p>
|
||
|
||
<p>HRESULT IWbemServices::DeleteClass(</p>
|
||
|
||
<p>[in] BSTR</b><i> strClass</i><b>, </p>
|
||
|
||
<p>[in] LONG</b><i> lFlags</i><b>, </p>
|
||
|
||
<p>[in] IWbemContext</b><i> *pCtx</i><b>, </p>
|
||
|
||
<p>[out, OPTIONAL] IWbemCallResult</b><i> **ppCallResult </i><b></p>
|
||
|
||
<p>);</b></p>
|
||
|
||
<p></font><font FACE="Arial Narrow"><b> </p>
|
||
|
||
<p>Parameters</b></font><font FACE="Arial" SIZE="2"><i></p>
|
||
|
||
<p>strClass</p>
|
||
|
||
<blockquote>
|
||
</i><p>The name of the class targeted for deletion.</p>
|
||
</blockquote>
|
||
|
||
<p><i> </p>
|
||
|
||
<p>lFlags</p>
|
||
|
||
<blockquote>
|
||
</i><p>One of the following values can be set:</font></p>
|
||
</blockquote>
|
||
|
||
<p ALIGN="LEFT"> </p>
|
||
|
||
<table CELLSPACING="0" BORDER="0" WIDTH="445">
|
||
<tr>
|
||
<td WIDTH="53%" VALIGN="TOP"><font FACE="Arial" SIZE="2"><b>Flag</b></font></td>
|
||
<td WIDTH="47%" VALIGN="TOP"><font FACE="Arial" SIZE="2"><b>Description</b></font></td>
|
||
</tr>
|
||
<tr>
|
||
<td WIDTH="53%" VALIGN="TOP"><font FACE="Arial" SIZE="2">WBEM_FLAG_RETURN_IMMEDIATELY </font></td>
|
||
<td WIDTH="47%" VALIGN="TOP"><font FACE="Arial" SIZE="2">This flag causes this to be a
|
||
semisychronous call. See Making a Semisynchronous Call</font><font FACE="Arial" SIZE="2"
|
||
COLOR="#800000">_hmm_making_a_semisynchronous_call</font><font FACE="Arial" SIZE="2"> for
|
||
more information on semisynchronous calls.</font></td>
|
||
</tr>
|
||
<tr>
|
||
<td WIDTH="53%" VALIGN="TOP"><font FACE="Arial" SIZE="2">WBEM_FLAG_OWNER_UPDATE</font></td>
|
||
<td WIDTH="47%" VALIGN="TOP"><font FACE="Arial" SIZE="2">Indicates that the caller is a
|
||
push or push-verify provider.</font></td>
|
||
</tr>
|
||
</table>
|
||
|
||
<p><font FACE="Arial" SIZE="2"><i> </p>
|
||
|
||
<p>pCtx</p>
|
||
|
||
<blockquote>
|
||
</i><p>Typically NULL. Otherwise, this is a pointer to an <b>IWbemContext</b> object that
|
||
may be used by the provider that is deleting the class. The values in the context object
|
||
must be specified in the documentation for the provider in question. See Making Calls to
|
||
CIMOM</font><font FACE="Arial" SIZE="2" COLOR="#800000">_hmm_Making_Calls_to_CIMOM</font><font
|
||
FACE="Arial" SIZE="2"> for more information about this parameter.</p>
|
||
</blockquote>
|
||
|
||
<p>ppCallResult</p>
|
||
|
||
<blockquote>
|
||
<p>If NULL, this parameter is not used. If <i>ppCallResult</i> is specified, it must be
|
||
set to point to NULL on entry. If the <i>lFlags </i>parameter contains
|
||
WBEM_FLAG_RETURN_IMMEDIATELY, this call will return immediately with WBEM_S_NO_ERROR. The <i>ppCallResult
|
||
</i>parameter<i> </i>will receive a pointer to a new <b>IWbemCallResult</b></font><font
|
||
FACE="Arial" SIZE="2" COLOR="#800000">_hmm_IWbemCallResult</font><font FACE="Arial"
|
||
SIZE="2"> object, which can then be polled to obtain the result using the <b>GetCallStatus</b></font><font
|
||
FACE="Arial" SIZE="2" COLOR="#800000">_hmm_IWbemCallresult_GetCallStatus</font><font
|
||
FACE="Arial" SIZE="2"><i> </i>method.</p>
|
||
<p></font> </p>
|
||
</blockquote>
|
||
|
||
<p><font FACE="Arial Narrow"><b> </p>
|
||
|
||
<p>See Also</p>
|
||
|
||
<blockquote>
|
||
</b></font><font FACE="Arial" SIZE="2"><p>Error Handling for Applications</font><font
|
||
FACE="Arial" SIZE="2" COLOR="#800000">_hmm_Error_Handling_for_Applications</font><font
|
||
FACE="Arial" SIZE="2">. </p>
|
||
</font><font FACE="Arial" SIZE="1"><p></font> </p>
|
||
</blockquote>
|
||
|
||
<p><font FACE="Arial Narrow"><b> </p>
|
||
|
||
<p>Return Values</b></font></p>
|
||
|
||
<table CELLSPACING="0" BORDER="0" WIDTH="463">
|
||
<tr>
|
||
<td WIDTH="52%" VALIGN="TOP" COLSPAN="2"><font FACE="Arial" SIZE="2">WBEM_E_ACCESS_DENIED</font></td>
|
||
<td WIDTH="48%" VALIGN="TOP"><font FACE="Arial" SIZE="2">The current user does not have
|
||
permission to delete classes.</font></td>
|
||
</tr>
|
||
<tr>
|
||
<td WIDTH="52%" VALIGN="TOP" COLSPAN="2"><font FACE="Arial" SIZE="2">WBEM_E_FAILED</font></td>
|
||
<td WIDTH="48%" VALIGN="TOP"><font FACE="Arial" SIZE="2">This indicates other unspecified
|
||
errors.</font></td>
|
||
</tr>
|
||
<tr>
|
||
<td WIDTH="52%" VALIGN="TOP" COLSPAN="2"><font FACE="Arial" SIZE="2">WBEM_E_INVALID_CLASS</font></td>
|
||
<td WIDTH="48%" VALIGN="TOP"><font FACE="Arial" SIZE="2">The specified class does not
|
||
exist.</font></td>
|
||
</tr>
|
||
<tr>
|
||
<td WIDTH="52%" VALIGN="TOP"><font FACE="Arial" SIZE="2">WBEM_E_CLASS_HAS_CHILDREN</font></td>
|
||
<td WIDTH="48%" VALIGN="TOP" COLSPAN="2"><font FACE="Arial" SIZE="2">Deleting this class
|
||
would invalidate a subclass.</font></td>
|
||
</tr>
|
||
<tr>
|
||
<td WIDTH="52%" VALIGN="TOP" COLSPAN="2"><font FACE="Arial" SIZE="2">WBEM_E_INVALID_OPERATION</font></td>
|
||
<td WIDTH="48%" VALIGN="TOP"><font FACE="Arial" SIZE="2">Deletion is not supported for the
|
||
specified class. It may have been a system class or a class supplied by a dynamic provider
|
||
that does not support class deletion.</font></td>
|
||
</tr>
|
||
<tr>
|
||
<td WIDTH="52%" VALIGN="TOP" COLSPAN="2"><font FACE="Arial" SIZE="2">WBEM_E_INVALID_PARAMETER</font></td>
|
||
<td WIDTH="48%" VALIGN="TOP"><font FACE="Arial" SIZE="2">An invalid parameter was
|
||
specified.</font></td>
|
||
</tr>
|
||
<tr>
|
||
<td WIDTH="52%" VALIGN="TOP" COLSPAN="2"><font FACE="Arial" SIZE="2">WBEM_E_OUT_OF_MEMORY</font></td>
|
||
<td WIDTH="48%" VALIGN="TOP"><font FACE="Arial" SIZE="2">There was not enough memory to
|
||
complete the operation.</font></td>
|
||
</tr>
|
||
<tr>
|
||
<td WIDTH="52%" VALIGN="TOP" COLSPAN="2"><font FACE="Arial" SIZE="2">WBEM_E_TRANSPORT_FAILURE</font></td>
|
||
<td WIDTH="48%" VALIGN="TOP"><font FACE="Arial" SIZE="2">This indicates the failure of the
|
||
remote procedure call (RPC) link between the current process and CIMOM.</font></td>
|
||
</tr>
|
||
<tr>
|
||
<td WIDTH="52%" VALIGN="TOP" COLSPAN="2"><font FACE="Arial" SIZE="2">WBEM_S_NO_ERROR</font></td>
|
||
<td WIDTH="48%" VALIGN="TOP"><font FACE="Arial" SIZE="2">The call succeeded.</font></td>
|
||
</tr>
|
||
</table>
|
||
|
||
<p><font FACE="Arial" SIZE="2"> </p>
|
||
|
||
<p>On failure, you can obtain any available information from the COM function <b>GetErrorInfo</b>.</p>
|
||
|
||
<p>DCOM-specific error codes may also be returned if network problems cause you to lose
|
||
the remote connection to CIMOM.</font><font FACE="Arial Narrow"><b></p>
|
||
|
||
<p>See Also</b></font><font FACE="Arial" SIZE="2"></p>
|
||
|
||
<p>Error Handling for Applications</font><font FACE="Arial" SIZE="2" COLOR="#800000">_hmm_Error_Handling_for_Applications</font><font
|
||
FACE="Arial" SIZE="2">,<b> IWbemServices::DeleteClassAsync</b></font><font FACE="Arial"
|
||
SIZE="2" COLOR="#800000">_hmm_IWbemServices_DeleteClassAsync</font><font
|
||
FACE="Arial Narrow" SIZE="5" COLOR="#800000"></p>
|
||
|
||
<p>‹^</font><font FACE="Arial Narrow" SIZE="5"><b># $ K + </b></font><font
|
||
FACE="Arial Narrow" SIZE="5" COLOR="#800000">›</font><b><font FACE="Arial Narrow"
|
||
SIZE="5">IWbemServices::DeleteClassAsync</font><font FACE="Arial Narrow" SIZE="1"
|
||
COLOR="#800000"><EFBFBD>@<40></font></b><font SIZE="2" COLOR="#ff00ff"></p>
|
||
|
||
<p><span style=color:#FF0000></font><font FACE="Arial" SIZE="2" COLOR="#ff0000">[This
|
||
is preliminary documentation and subject to change.]</font><font SIZE="2" COLOR="#ff00ff"></span></font><font
|
||
FACE="Arial" SIZE="2"> </p>
|
||
|
||
<p>The <b>IWbemServices::DeleteClassAsync</b> method deletes the specified class from the
|
||
current namespace. This method is identical to <b>IWbemServices::DeleteClass</b></font><font
|
||
FACE="Arial" SIZE="2" COLOR="#800000">_hmm_IWbemServices_DeleteClass</font><font
|
||
FACE="Arial" SIZE="2"> except that the call returns immediately. Confirmation or failure
|
||
is asynchronously reported to the specified object sink using the <b>IWbemObjectSink::SetStatus</b>
|
||
method after the operation is complete. </font><font FACE="Lucida Sans Typewriter"
|
||
SIZE="2"><b></p>
|
||
|
||
<p>HRESULT IWbemServices::DeleteClassAsync(</p>
|
||
|
||
<p>[in] BSTR</b><i> strClass</i><b>, </p>
|
||
|
||
<p>[in] LONG</b><i> lFlags</i><b>, </p>
|
||
|
||
<p>[in] IWbemContext</b><i> *pCtx</i><b>, </p>
|
||
|
||
<p>[in] IWbemObjectSink</b><i> *pResponseHandler</i> </p>
|
||
|
||
<p><b> </p>
|
||
|
||
<p>);</b></p>
|
||
|
||
<p></font><font FACE="Arial Narrow"><b> </p>
|
||
|
||
<p>Parameters</b></font><font FACE="Arial" SIZE="2"><i></p>
|
||
|
||
<p>strClass</p>
|
||
|
||
<blockquote>
|
||
</i><p>The name of the class targeted for deletion.</p>
|
||
</blockquote>
|
||
|
||
<p><i> </p>
|
||
|
||
<p>lFlags</i></font></p>
|
||
|
||
<p ALIGN="LEFT"> </p>
|
||
|
||
<table CELLSPACING="0" BORDER="0" WIDTH="445">
|
||
<tr>
|
||
<td WIDTH="53%" VALIGN="TOP"><font FACE="Arial" SIZE="2"><b>Flag</b></font></td>
|
||
<td WIDTH="47%" VALIGN="TOP"><font FACE="Arial" SIZE="2"><b>Description</b></font></td>
|
||
</tr>
|
||
<tr>
|
||
<td WIDTH="53%" VALIGN="TOP"><font FACE="Arial" SIZE="2">WBEM_FLAG_SEND_STATUS </font></td>
|
||
<td WIDTH="47%" VALIGN="TOP"><font FACE="Arial" SIZE="2">This flag registers with CIMOM a
|
||
request to receive intermediate status reports through the clients implementation of <b>IWbemObjectSink::SetStatus</b>.</font></td>
|
||
</tr>
|
||
<tr>
|
||
<td WIDTH="53%" VALIGN="TOP"><font FACE="Arial" SIZE="2">WBEM_FLAG_OWNER_UPDATE</font></td>
|
||
<td WIDTH="47%" VALIGN="TOP"><font FACE="Arial" SIZE="2">Push providers must specify this
|
||
flag when calling <b>DeleteClassAsync</b> to indicate that this class has changed.</font></td>
|
||
</tr>
|
||
</table>
|
||
|
||
<p><font FACE="Arial" SIZE="2"><i> </p>
|
||
|
||
<p>pCtx</p>
|
||
|
||
<blockquote>
|
||
</i><p>Typically NULL. Otherwise, this is a pointer to an <b>IWbemContext</b> object that
|
||
may be used by the provider that is deleting the class. The values in the context object
|
||
must be specified in the documentation for the provider in question. See Making Calls to
|
||
CIMOM</font><font FACE="Arial" SIZE="2" COLOR="#800000">_hmm_Making_Calls_to_CIMOM</font><font
|
||
FACE="Arial" SIZE="2"> for more information about this parameter.</p>
|
||
</blockquote>
|
||
|
||
<p><i> </p>
|
||
|
||
<p>pResponseHandler</p>
|
||
|
||
<blockquote>
|
||
</i><p>Points to an implementation of <b>IWbemObjectSink</b></font><font FACE="Arial"
|
||
SIZE="2" COLOR="#800000">_hmm_IWbemObjectSink</font><font FACE="Arial" SIZE="2">
|
||
implemented by the caller. This handler receives the status of the deletion request when
|
||
it becomes available through the <b>IWbemObjectSink::SetStatus</b><i> </i>method. If any
|
||
error code is returned, then the supplied IWbemObjectSink pointer will not be used. If
|
||
WBEM_S_NO_ERROR is returned, then the user's IWbemObjectSink implementation will be called
|
||
to indicate the result of the operation. CIMOM only calls <b>AddRef</b> on the pointer in
|
||
cases where WBEM_S_NO_ERROR returns. In cases where an error code returns, the reference
|
||
count is the same as on entry. For a detailed explanation of this parameter, see Making an
|
||
Asynchronous Call</font><font FACE="Arial" SIZE="2" COLOR="#800000">_hmm_Making_an_Asynchronous_Call</font><font
|
||
FACE="Arial" SIZE="2">. </p>
|
||
</font><font FACE="Arial" SIZE="1"><p></font> </p>
|
||
</blockquote>
|
||
|
||
<p><font FACE="Arial Narrow"><b> </p>
|
||
|
||
<p>Return Values</b></font></p>
|
||
|
||
<table CELLSPACING="0" BORDER="0" WIDTH="463">
|
||
<tr>
|
||
<td WIDTH="52%" VALIGN="TOP"><font FACE="Arial" SIZE="2">WBEM_E_FAILED</font></td>
|
||
<td WIDTH="48%" VALIGN="TOP"><font FACE="Arial" SIZE="2">This indicates other unspecified
|
||
failures.</font></td>
|
||
</tr>
|
||
<tr>
|
||
<td WIDTH="52%" VALIGN="TOP"><font FACE="Arial" SIZE="2">WBEM_E_INVALID_PARAMETER</font></td>
|
||
<td WIDTH="48%" VALIGN="TOP"><font FACE="Arial" SIZE="2">An invalid parameter was
|
||
specified.</font></td>
|
||
</tr>
|
||
<tr>
|
||
<td WIDTH="52%" VALIGN="TOP"><font FACE="Arial" SIZE="2">WBEM_E_CLASS_HAS_CHILDREN</font></td>
|
||
<td WIDTH="48%" VALIGN="TOP"><font FACE="Arial" SIZE="2">Deleting this class would
|
||
invalidate a subclass.</font></td>
|
||
</tr>
|
||
<tr>
|
||
<td WIDTH="52%" VALIGN="TOP"><font FACE="Arial" SIZE="2">WBEM_E_OUT_OF_MEMORY</font></td>
|
||
<td WIDTH="48%" VALIGN="TOP"><font FACE="Arial" SIZE="2">There was not enough memory to
|
||
complete the operation.</font></td>
|
||
</tr>
|
||
<tr>
|
||
<td WIDTH="52%" VALIGN="TOP"><font FACE="Arial" SIZE="2">WBEM_E_TRANSPORT_FAILURE</font></td>
|
||
<td WIDTH="48%" VALIGN="TOP"><font FACE="Arial" SIZE="2">This indicates the failure of the
|
||
remote procedure call (RPC) link between the current process and CIMOM.</font></td>
|
||
</tr>
|
||
<tr>
|
||
<td WIDTH="52%" VALIGN="TOP"><font FACE="Arial" SIZE="2">WBEM_S_NO_ERROR</font></td>
|
||
<td WIDTH="48%" VALIGN="TOP"><font FACE="Arial" SIZE="2">The call succeeded.</font></td>
|
||
</tr>
|
||
</table>
|
||
|
||
<p><font FACE="Arial" SIZE="2"> </p>
|
||
|
||
<p>All other return codes are provided to the object sink specified by the <i>pReponseHandler</i>
|
||
parameter through the <b>SetStatus</b> method. Error conditions, such as when the class
|
||
does not exist or the user does not have permission to delete classes, are reported to the
|
||
handler. They are not reported in the return code of this method.</p>
|
||
|
||
<p>DCOM-specific error codes also may be returned if network problems cause you to lose
|
||
the remote connection to CIMOM.</font><font FACE="Arial Narrow"><b></p>
|
||
|
||
<p>Remarks</b></font><font FACE="Arial" SIZE="2"></p>
|
||
|
||
<p>If a dynamic instance provider is associated with the class, the provider is
|
||
unregistered, and is no longer called for that class. Any classes that derive from the
|
||
deleted class are also deleted, and their associated providers become unregistered. All
|
||
outstanding static instances of the specified class and its subclasses are also deleted
|
||
when the class is deleted.</p>
|
||
|
||
<p>If the class is provided by a dynamic class provider, the success of the deletion
|
||
depends on whether class deletion is supported by that provider.</font><font
|
||
FACE="Arial Narrow" SIZE="3"><b></p>
|
||
|
||
<p>Note</p>
|
||
|
||
<blockquote>
|
||
</b></font><font FACE="Arial" SIZE="2"><p>Standard system classes cannot be deleted.</p>
|
||
</font><font FACE="Arial" SIZE="1"><p></font> </p>
|
||
</blockquote>
|
||
|
||
<p><font FACE="Arial Narrow"><b> </p>
|
||
|
||
<p>See Also</b></font><font FACE="Arial" SIZE="2"></p>
|
||
|
||
<p>Error Handling for Applications</font><font FACE="Arial" SIZE="2" COLOR="#800000">_hmm_Error_Handling_for_Applications</font><font
|
||
FACE="Arial" SIZE="2">, Asynchronous Methods</font><font FACE="Arial" SIZE="2"
|
||
COLOR="#800000">_hmm_making_an_asynchronous_call</font><font FACE="Arial" SIZE="2">,<b>
|
||
IWbemServices::DeleteClass</b></font><font FACE="Arial" SIZE="2" COLOR="#800000">_hmm_IWbemServices_DeleteClass</font><font
|
||
FACE="Arial Narrow" SIZE="5" COLOR="#800000"></p>
|
||
|
||
<p>‹^</font><font FACE="Arial Narrow" SIZE="5"><b># $ K + </b></font><font
|
||
FACE="Arial Narrow" SIZE="5" COLOR="#800000">›</font><b><font FACE="Arial Narrow"
|
||
SIZE="5">IWbemServices::CreateClassEnum</font><font FACE="Arial Narrow" SIZE="1"
|
||
COLOR="#800000"><EFBFBD>@<40></font></b><font SIZE="2" COLOR="#ff00ff"></p>
|
||
|
||
<p><span style=color:#FF0000></font><font FACE="Arial" SIZE="2" COLOR="#ff0000">[This
|
||
is preliminary documentation and subject to change.]</font><font SIZE="2" COLOR="#ff00ff"></span></font><font
|
||
FACE="Arial" SIZE="2"> </p>
|
||
|
||
<p>The <b>IWbemServices::CreateClassEnum</b> method returns an enumerator for all classes
|
||
satisfying the selection criteria. </p>
|
||
|
||
<p>The caller must then use the returned enumerator to retrieve the class definitions,
|
||
calling <b>IEnumWbemClassObject::Next</b></font><font FACE="Arial" SIZE="2"
|
||
COLOR="#800000">_hmm_IEnumWbemClassObject_Next</font><font FACE="Arial" SIZE="2"> to
|
||
obtain each class or blocks of classes. It finishes by calling <b>IEnumWbemClassObject::Release</b></font><font
|
||
FACE="Arial" SIZE="2" COLOR="#800000">_hmm_IEnumWbemClassObject_Release</font><font
|
||
FACE="Arial" SIZE="2">.</font><font FACE="Arial Narrow" SIZE="3"><b></p>
|
||
|
||
<p>Note</p>
|
||
|
||
<blockquote>
|
||
</b></font><font FACE="Arial" SIZE="2"><p>It is not an error for the returned enumerator
|
||
to have zero elements.</font></p>
|
||
</blockquote>
|
||
|
||
<p><font FACE="Lucida Sans Typewriter" SIZE="2"><b> </p>
|
||
|
||
<p>HRESULT IWbemServices::CreateClassEnum(</p>
|
||
|
||
<p>[in] BSTR</b><i> strSuperclass</i><b>,</p>
|
||
|
||
<p>[in] LONG</b><i> lFlags</i><b>,</p>
|
||
|
||
<p>[in] IWbemContext</b><i> *pCtx</i><b>,</p>
|
||
|
||
<p>[out] IEnumWbemClassObject</b><i> **ppEnum</i><b></p>
|
||
|
||
<p>);</b></p>
|
||
|
||
<p></font><font FACE="Arial Narrow"><b> </p>
|
||
|
||
<p>Parameters</b></font><font FACE="Arial" SIZE="2"><i></p>
|
||
|
||
<p>strSuperclass</p>
|
||
|
||
<blockquote>
|
||
</i><p>If not NULL or blank, specifies a superclass name. Only classes that are subclasses
|
||
of this class are returned in the enumerator. If it is NULL or blank, and <i>lFlags</i> is
|
||
WBEM_FLAG_SHALLOW, only the top-level classes, that is, classes that have no parent class
|
||
or superclass, are returned. If it is NULL or blank and <i>lFlags</i> is WBEM_FLAG_DEEP,
|
||
all classes within the namespace are returned.</p>
|
||
</blockquote>
|
||
|
||
<p><i> </p>
|
||
|
||
<p>lFlags</p>
|
||
|
||
<blockquote>
|
||
</i><p>The following flags affect the behavior of this method. The suggested value for
|
||
this parameter is WBEM_FLAG_RETURN_IMMEDIATELY | WBEM_FLAG_FORWARD_ONLY for best
|
||
performance.</font></p>
|
||
</blockquote>
|
||
|
||
<p ALIGN="LEFT"> </p>
|
||
|
||
<table CELLSPACING="0" BORDER="0" WIDTH="445">
|
||
<tr>
|
||
<td WIDTH="53%" VALIGN="TOP"><font FACE="Arial" SIZE="2"><b>Flag</b> </font></td>
|
||
<td WIDTH="47%" VALIGN="TOP"><font FACE="Arial" SIZE="2"><b>Description</b></font></td>
|
||
</tr>
|
||
<tr>
|
||
<td WIDTH="53%" VALIGN="TOP"><font FACE="Arial" SIZE="2">WBEM_FLAG_DEEP </font></td>
|
||
<td WIDTH="47%" VALIGN="TOP"><font FACE="Arial" SIZE="2">This flag forces the enumeration
|
||
to include all of class in the hierarchy.</font></td>
|
||
</tr>
|
||
<tr>
|
||
<td WIDTH="53%" VALIGN="TOP"><font FACE="Arial" SIZE="2">WBEM_FLAG_SHALLOW </font></td>
|
||
<td WIDTH="47%" VALIGN="TOP"><font FACE="Arial" SIZE="2">This flag forces the enumeration
|
||
to include only immediate subclasses of the specified superclass.</font></td>
|
||
</tr>
|
||
<tr>
|
||
<td WIDTH="53%" VALIGN="TOP"><font FACE="Arial" SIZE="2">WBEM_FLAG_RETURN_IMMEDIATELY </font></td>
|
||
<td WIDTH="47%" VALIGN="TOP"><font FACE="Arial" SIZE="2">This flag causes this to be a
|
||
semisycnronous call. See Making a Semisynchronous Call</font><font FACE="Arial" SIZE="2"
|
||
COLOR="#800000">_hmm_making_a_semisynchronous_call</font><font FACE="Arial" SIZE="2"> for
|
||
more information on semisynchronous calls.</font></td>
|
||
</tr>
|
||
<tr>
|
||
<td WIDTH="53%" VALIGN="TOP"><font FACE="Arial" SIZE="2">WBEM_FLAG_FORWARD_ONLY</font></td>
|
||
<td WIDTH="47%" VALIGN="TOP"><font FACE="Arial" SIZE="2">This flag causes a forward-only
|
||
enumerator to be returned. Forward-only enumerators are generally much faster and use less
|
||
memory than conventional enumerators but do not allow calls to <b>Clone</b> or <b>Reset</b>.
|
||
</font></td>
|
||
</tr>
|
||
<tr>
|
||
<td WIDTH="53%" VALIGN="TOP"><font FACE="Arial" SIZE="2">WBEM_FLAG_BIDIRECTIONAL</font></td>
|
||
<td WIDTH="47%" VALIGN="TOP"><font FACE="Arial" SIZE="2">This flag causes CIMOM to retain
|
||
pointers to objects of the enumeration until the client releases the enumerator.</font></td>
|
||
</tr>
|
||
</table>
|
||
|
||
<p><font FACE="Arial" SIZE="2"> </p>
|
||
|
||
<p> </p>
|
||
|
||
<p><i> </p>
|
||
|
||
<p>pCtx</p>
|
||
|
||
<blockquote>
|
||
</i><p>Typically NULL. Otherwise, this is a pointer to an <b>IWbemContext</b> object that
|
||
may be used by the provider that is providing the requested classes. The values in the
|
||
context object must be specified in the documentation for the provider in question. See
|
||
Making Calls to CIMOM</font><font FACE="Arial" SIZE="2" COLOR="#800000">_hmm_Making_Calls_to_CIMOM</font><font
|
||
FACE="Arial" SIZE="2"> for more information about this parameter.</p>
|
||
</blockquote>
|
||
|
||
<p><i> </p>
|
||
|
||
<p>ppEnum</p>
|
||
|
||
<blockquote>
|
||
</i><p>Receives the pointer to the enumerator. The returned object has a positive
|
||
reference count. The caller must call <b>Release</b> on the pointer when it is no longer
|
||
required.</p>
|
||
</font><font FACE="Arial" SIZE="1"><p></font> </p>
|
||
</blockquote>
|
||
|
||
<p><font FACE="Arial Narrow"><b> </p>
|
||
|
||
<p>Return Values</b></font></p>
|
||
|
||
<table CELLSPACING="0" BORDER="0" WIDTH="463">
|
||
<tr>
|
||
<td WIDTH="53%" VALIGN="TOP"><font FACE="Arial" SIZE="2">WBEM_E_ACCESS_DENIED</font></td>
|
||
<td WIDTH="47%" VALIGN="TOP"><font FACE="Arial" SIZE="2">The current user does not have
|
||
permission to view one or more of the classes that the call can return.</font></td>
|
||
</tr>
|
||
<tr>
|
||
<td WIDTH="53%" VALIGN="TOP"><font FACE="Arial" SIZE="2">WBEM_E_FAILED</font></td>
|
||
<td WIDTH="47%" VALIGN="TOP"><font FACE="Arial" SIZE="2">This indicates other unspecified
|
||
errors.</font></td>
|
||
</tr>
|
||
<tr>
|
||
<td WIDTH="53%" VALIGN="TOP"><font FACE="Arial" SIZE="2">WBEM_E_INVALID_CLASS</font></td>
|
||
<td WIDTH="47%" VALIGN="TOP"><font FACE="Arial" SIZE="2">The specified class does not
|
||
exist.</font></td>
|
||
</tr>
|
||
<tr>
|
||
<td WIDTH="53%" VALIGN="TOP"><font FACE="Arial" SIZE="2">WBEM_E_INVALID_PARAMETER</font></td>
|
||
<td WIDTH="47%" VALIGN="TOP"><font FACE="Arial" SIZE="2">An invalid parameter was
|
||
specified.</font></td>
|
||
</tr>
|
||
<tr>
|
||
<td WIDTH="53%" VALIGN="TOP"><font FACE="Arial" SIZE="2">WBEM_E_OUT_OF_MEMORY</font></td>
|
||
<td WIDTH="47%" VALIGN="TOP"><font FACE="Arial" SIZE="2">There was not enough memory to
|
||
complete the operation.</font></td>
|
||
</tr>
|
||
<tr>
|
||
<td WIDTH="53%" VALIGN="TOP"><font FACE="Arial" SIZE="2">WBEM_E_TRANSPORT_FAILURE</font></td>
|
||
<td WIDTH="47%" VALIGN="TOP"><font FACE="Arial" SIZE="2">This indicates the failure of the
|
||
remote procedure call (RPC) link between the current process and CIMOM.</font></td>
|
||
</tr>
|
||
<tr>
|
||
<td WIDTH="53%" VALIGN="TOP"><font FACE="Arial" SIZE="2">WBEM_S_NO_ERROR</font></td>
|
||
<td WIDTH="47%" VALIGN="TOP"><font FACE="Arial" SIZE="2">The call succeeded.</font></td>
|
||
</tr>
|
||
</table>
|
||
|
||
<p><font FACE="Arial" SIZE="2"> </p>
|
||
|
||
<p>On failure, you can obtain any available information from the COM function <b>GetErrorInfo</b>.</p>
|
||
|
||
<p>DCOM-specific error codes also may be returned if network problems cause you to lose
|
||
the remote connection to CIMOM.</font><font FACE="Arial Narrow"><b></p>
|
||
|
||
<p>See Also</b></font><font FACE="Arial" SIZE="2"></p>
|
||
|
||
<p>Error Handling for Applications</font><font FACE="Arial" SIZE="2" COLOR="#800000">_hmm_Error_Handling_for_Applications</font><font
|
||
FACE="Arial" SIZE="2">,<b> IWbemServices::CreateClassEnumAsync</b></font><font
|
||
FACE="Arial" SIZE="2" COLOR="#800000">_hmm_IWbemServices_CreateClassEnumAsync</font><font
|
||
FACE="Arial" SIZE="2">, <b>IEnumWbemClassObject</b></font><font FACE="Arial" SIZE="2"
|
||
COLOR="#800000">_hmm_IEnumWbemClassObject</font><font FACE="Arial Narrow" SIZE="5"
|
||
COLOR="#800000"></p>
|
||
|
||
<p>‹^</font><font FACE="Arial Narrow" SIZE="5"><b># $ K + </b></font><font
|
||
FACE="Arial Narrow" SIZE="5" COLOR="#800000">›</font><b><font FACE="Arial Narrow"
|
||
SIZE="5">IWbemServices::CreateClassEnumAsync</font><font FACE="Arial Narrow" SIZE="1"
|
||
COLOR="#800000"><EFBFBD>@<40></font></b><font SIZE="2" COLOR="#ff00ff"></p>
|
||
|
||
<p><span style=color:#FF0000></font><font FACE="Arial" SIZE="2" COLOR="#ff0000">[This
|
||
is preliminary documentation and subject to change.]</font><font SIZE="2" COLOR="#ff00ff"></span></font><font
|
||
FACE="Arial" SIZE="2"> </p>
|
||
|
||
<p>The <b>IWbemServices::CreateClassEnumAsync</b> method performs the same function as <b>IWbemServices::CreateClassEnum</b></font><font
|
||
FACE="Arial" SIZE="2" COLOR="#800000">_hmm_IWbemServices_CreateClassEnum</font><font
|
||
FACE="Arial" SIZE="2"> except that the classes are asynchronously provided to the
|
||
specified response handler.</p>
|
||
|
||
<p>In cases where the call succeeds, CIMOM calls <b>AddRef</b> on the pointer <i>pResponseHandler</i>,
|
||
and then returns immediately. It then asynchronously calls <i>pResponseHandler</i> –
|
||
><b>Notify</b> from another thread with class definitions until the query has been
|
||
satisfied.</font><font FACE="Lucida Sans Typewriter" SIZE="2"><b></p>
|
||
|
||
<p>HRESULT IWbemServices::CreateClassEnumAsync(</p>
|
||
|
||
<p>[in] BSTR</b><i> strSuperclass</i><b>, </p>
|
||
|
||
<p>[in] LONG</b><i> lFlags</i><b>, </p>
|
||
|
||
<p>[in] IWbemContext</b><i> *pCtx</i><b>, </p>
|
||
|
||
<p>[in]IWbemObjectSink</b><i> *pResponseHandler</i><b></p>
|
||
|
||
<p>);</b></p>
|
||
|
||
<p></font><font FACE="Arial Narrow"><b> </p>
|
||
|
||
<p>Parameters</b></font><font FACE="Arial" SIZE="2"><i></p>
|
||
|
||
<p>strSuperclass</p>
|
||
|
||
<blockquote>
|
||
</i><p>If not NULL or blank, this parameter specifies a superclass name. Only classes that
|
||
are subclasses of this class are returned in the enumerator. If NULL or blank, and <i>lFlags</i>
|
||
is WBEM_FLAG_SHALLOW, only top-level classes, that is, those which have no parent class or
|
||
superclass, are returned. If it is NULL or blank and <i>lFlags</i> is WBEM_FLAG_DEEP, all
|
||
classes within the namespace are returned.</p>
|
||
</blockquote>
|
||
|
||
<p><i> </p>
|
||
|
||
<p>lFlags</i></font></p>
|
||
|
||
<p ALIGN="LEFT"> </p>
|
||
|
||
<table CELLSPACING="0" BORDER="0" WIDTH="445">
|
||
<tr>
|
||
<td WIDTH="53%" VALIGN="TOP"><font FACE="Arial" SIZE="2"><b>Flag</b></font></td>
|
||
<td WIDTH="47%" VALIGN="TOP"><font FACE="Arial" SIZE="2"><b>Description</b></font></td>
|
||
</tr>
|
||
<tr>
|
||
<td WIDTH="53%" VALIGN="TOP"><font FACE="Arial" SIZE="2">WBEM_FLAG_FORWARD_ONLY</font></td>
|
||
<td WIDTH="47%" VALIGN="TOP"><font FACE="Arial" SIZE="2">This flag causes a forward-only
|
||
enumerator to be returned. Forward-only enumerators are generally much faster and use less
|
||
memory than conventional enumerators but do not allow calls to <b>Clone</b> or <b>Reset</b>.</font></td>
|
||
</tr>
|
||
<tr>
|
||
<td WIDTH="53%" VALIGN="TOP"><font FACE="Arial" SIZE="2">WBEM_FLAG_BIDIRECTIONAL</font></td>
|
||
<td WIDTH="47%" VALIGN="TOP"><font FACE="Arial" SIZE="2">This flag causes CIMOM to retain
|
||
pointers to objects of the enumeration until the client releases the enumerator.</font></td>
|
||
</tr>
|
||
<tr>
|
||
<td WIDTH="53%" VALIGN="TOP"><font FACE="Arial" SIZE="2">WBEM_FLAG_DEEP .</font></td>
|
||
<td WIDTH="47%" VALIGN="TOP"><font FACE="Arial" SIZE="2">This flag forces recursive
|
||
enumeration into all subclasses derived from the specified superclass</font></td>
|
||
</tr>
|
||
<tr>
|
||
<td WIDTH="53%" VALIGN="TOP"><font FACE="Arial" SIZE="2">WBEM_FLAG_SHALLOW</font></td>
|
||
<td WIDTH="47%" VALIGN="TOP"><font FACE="Arial" SIZE="2">This flag forces the enumeration
|
||
to include only immediate subclasses of the specified superclass.</font></td>
|
||
</tr>
|
||
<tr>
|
||
<td WIDTH="53%" VALIGN="TOP"><font FACE="Arial" SIZE="2">WBEM_FLAG_SEND_STATUS </font></td>
|
||
<td WIDTH="47%" VALIGN="TOP"><font FACE="Arial" SIZE="2">This flag registers with CIMOM a
|
||
request to receive intermediate status reports through the clients implementation of <b>IWbemObjectSink::SetStatus</b>..</font></td>
|
||
</tr>
|
||
</table>
|
||
|
||
<p><font FACE="Arial" SIZE="1"> </p>
|
||
|
||
<p></font><font FACE="Arial Narrow" SIZE="3"><b> </p>
|
||
|
||
<p>Note</p>
|
||
|
||
<blockquote>
|
||
</b></font><font FACE="Arial" SIZE="2"><p>If <i>strSuperclass</i> is NULL or blank and
|
||
WBEM_FLAG_DEEP is specified, all classes are returned.</p>
|
||
</font>
|
||
</blockquote>
|
||
|
||
<p><font FACE="Arial" SIZE="2"><i> </p>
|
||
|
||
<p>pCtx</p>
|
||
|
||
<blockquote>
|
||
</i><p>Typically NULL. Otherwise, this is a pointer to an <b>IWbemContext</b> object that
|
||
may be used by the provider that is returning the requested classes. The values in the
|
||
context object must be specified in the documentation for the provider in question. See
|
||
Making Calls to CIMOM</font><font FACE="Arial" SIZE="2" COLOR="#800000">_hmm_Making_Calls_to_CIMOM</font><font
|
||
FACE="Arial" SIZE="2"> for more information about this parameter.</p>
|
||
</blockquote>
|
||
|
||
<p><i> </p>
|
||
|
||
<p>pResponseHandler</p>
|
||
|
||
<blockquote>
|
||
</i><p>Points to the caller's implementation of <b>IWbemObjectSink</b></font><font
|
||
FACE="Arial" SIZE="2" COLOR="#800000">_hmm_IWbemObjectSink</font><font FACE="Arial"
|
||
SIZE="2">. This handler receives the objects as they become available using the <b>IWbemObjectSink::Indicate</b></font><font
|
||
FACE="Arial" SIZE="2" COLOR="#800000">_hmm_IWbemObjectSink_Indicate</font><font
|
||
FACE="Arial" SIZE="2"> method. When no more objects are available, the <b>IWbemObjectSink::SetStatus</b><i>
|
||
</i>method is called by CIMOM. If any error code is returned, then the supplied
|
||
IWbemObjectSink pointer will not be used. If WBEM_S_NO_ERROR is returned, then the user's
|
||
IWbemObjectSink implementation will be called to indicate the result of the operation.
|
||
CIMOM only calls <b>AddRef</b> on the pointer in cases where WBEM_S_NO_ERROR returns. In
|
||
cases where an error code returns, the reference count is the same as on entry. For a
|
||
detailed explanation of this parameter, see Asynchronous Methods</font><font FACE="Arial"
|
||
SIZE="2" COLOR="#800000">_hmm_making_an_asynchronous_call</font><font FACE="Arial"
|
||
SIZE="2">. </p>
|
||
</font><font FACE="Arial" SIZE="1"><p></font> </p>
|
||
</blockquote>
|
||
|
||
<p><font FACE="Arial Narrow"><b> </p>
|
||
|
||
<p>Return Values</b></font></p>
|
||
|
||
<table CELLSPACING="0" BORDER="0" WIDTH="463">
|
||
<tr>
|
||
<td WIDTH="50%" VALIGN="TOP"><font FACE="Arial" SIZE="2">WBEM_E_FAILED</font></td>
|
||
<td WIDTH="50%" VALIGN="TOP"><font FACE="Arial" SIZE="2">This is an unspecified error.</font></td>
|
||
</tr>
|
||
<tr>
|
||
<td WIDTH="50%" VALIGN="TOP"><font FACE="Arial" SIZE="2">WBEM_E_INVALID_CLASS</font></td>
|
||
<td WIDTH="50%" VALIGN="TOP"><font FACE="Arial" SIZE="2">The specified class does not
|
||
exist.</font></td>
|
||
</tr>
|
||
<tr>
|
||
<td WIDTH="50%" VALIGN="TOP"><font FACE="Arial" SIZE="2">WBEM_E_INVALID_PARAMETER</font></td>
|
||
<td WIDTH="50%" VALIGN="TOP"><font FACE="Arial" SIZE="2">An invalid parameter was
|
||
specified.</font></td>
|
||
</tr>
|
||
<tr>
|
||
<td WIDTH="50%" VALIGN="TOP"><font FACE="Arial" SIZE="2">WBEM_E_OUT_OF_MEMORY</font></td>
|
||
<td WIDTH="50%" VALIGN="TOP"><font FACE="Arial" SIZE="2">There was not enough memory to
|
||
complete the operation.</font></td>
|
||
</tr>
|
||
<tr>
|
||
<td WIDTH="50%" VALIGN="TOP"><font FACE="Arial" SIZE="2">WBEM_E_TRANSPORT_FAILURE</font></td>
|
||
<td WIDTH="50%" VALIGN="TOP"><font FACE="Arial" SIZE="2">This indicates the failure of the
|
||
remote procedure call (RPC) link between the current process and CIMOM.</font></td>
|
||
</tr>
|
||
<tr>
|
||
<td WIDTH="50%" VALIGN="TOP"><font FACE="Arial" SIZE="2">WBEM_S_NO_ERROR</font></td>
|
||
<td WIDTH="50%" VALIGN="TOP"><font FACE="Arial" SIZE="2">The call succeeded.</font></td>
|
||
</tr>
|
||
</table>
|
||
|
||
<p><font FACE="Arial" SIZE="2"> </p>
|
||
|
||
<p>On failure, you can obtain available information from the COM function <b>GetErrorInfo</b>.</p>
|
||
|
||
<p>DCOM-specific error codes also may be returned if network problems cause you to lose
|
||
the remote connection to CIMOM.</font><font FACE="Arial Narrow"><b></p>
|
||
|
||
<p>See Also</b></font><font FACE="Arial" SIZE="2"></p>
|
||
|
||
<p>Error Handling for Applications</font><font FACE="Arial" SIZE="2" COLOR="#800000">_hmm_Error_Handling_for_Applications</font><font
|
||
FACE="Arial" SIZE="2">,Making an Asynchronous Call</font><font FACE="Arial" SIZE="2"
|
||
COLOR="#800000">_hmm_Making_an_Asynchronous_Call</font><font FACE="Arial" SIZE="2">, <b>IWbemServices::CreateClassEnum</b></font><font
|
||
FACE="Arial" SIZE="2" COLOR="#800000">_hmm_IWbemServices_CreateClassEnum</font><font
|
||
FACE="Arial" SIZE="2">, <b>IWbemObjectSink</b></font><font FACE="Arial" SIZE="2"
|
||
COLOR="#800000">_hmm_IWbemObjectSink</font><font FACE="Arial Narrow" SIZE="5"
|
||
COLOR="#800000"></p>
|
||
|
||
<p>‹^</font><font FACE="Arial Narrow" SIZE="5"><b># $ K + </b></font><font
|
||
FACE="Arial Narrow" SIZE="5" COLOR="#800000">›</font><b><font FACE="Arial Narrow"
|
||
SIZE="5">IWbemServices::PutInstance</font><font FACE="Arial Narrow" SIZE="1"
|
||
COLOR="#800000"><EFBFBD>@<40></font></b><font SIZE="2" COLOR="#ff00ff"></p>
|
||
|
||
<p><span style=color:#FF0000></font><font FACE="Arial" SIZE="2" COLOR="#ff0000">[This
|
||
is preliminary documentation and subject to change.]</font><font SIZE="2" COLOR="#ff00ff"></span></font><font
|
||
FACE="Arial" SIZE="2"> </p>
|
||
|
||
<p>The <b>IWbemServices::PutInstance</b> method creates or updates an instance of an
|
||
existing class. The instance is written to the CIMOM repository.</font><font
|
||
FACE="Lucida Sans Typewriter" SIZE="2"><b></p>
|
||
|
||
<p>HRESULT IWbemServices::PutInstance(</p>
|
||
|
||
<p>[in] IWbemClassObject</b><i> *pInst</i><b>, </p>
|
||
|
||
<p>[in] LONG</b><i> lFlags</i><b>, </p>
|
||
|
||
<p>[in] IWbemContext</b><i> *pCtx</i><b>, </p>
|
||
|
||
<p>[out, OPTIONAL] IWbemCallResult</b><i> **ppCallResult </i><b></p>
|
||
|
||
<p>);</b></p>
|
||
|
||
<p></font><font FACE="Arial Narrow"><b> </p>
|
||
|
||
<p>Parameters</b></font><font FACE="Arial" SIZE="2"><i></p>
|
||
|
||
<p>pInst</p>
|
||
|
||
<blockquote>
|
||
</i><p>Points to the instance to be written. The caller cannot make assumptions about the
|
||
reference count at the completion of this call. </p>
|
||
</blockquote>
|
||
|
||
<p><i> </p>
|
||
|
||
<p>lFlags</p>
|
||
|
||
<blockquote>
|
||
</i><p>One or more of the following values can be set:</font></p>
|
||
</blockquote>
|
||
|
||
<p ALIGN="LEFT"> </p>
|
||
|
||
<table CELLSPACING="0" BORDER="0" WIDTH="445">
|
||
<tr>
|
||
<td WIDTH="53%" VALIGN="TOP"><font FACE="Arial" SIZE="2"><b>Flag</b> </font></td>
|
||
<td WIDTH="47%" VALIGN="TOP"><font FACE="Arial" SIZE="2"><b>Description</b></font></td>
|
||
</tr>
|
||
<tr>
|
||
<td WIDTH="53%" VALIGN="TOP"><font FACE="Arial" SIZE="2">WBEM_FLAG_CREATE_OR_UPDATE</font></td>
|
||
<td WIDTH="47%" VALIGN="TOP"><font FACE="Arial" SIZE="2">This flag causes the instance to
|
||
be created if it does not exist or overwritten if it exists already.</font></td>
|
||
</tr>
|
||
<tr>
|
||
<td WIDTH="53%" VALIGN="TOP"><font FACE="Arial" SIZE="2">WBEM_FLAG_UPDATE_ONLY</font></td>
|
||
<td WIDTH="47%" VALIGN="TOP"><font FACE="Arial" SIZE="2">This flag causes this call to
|
||
update. The instance must exist for the call to be successful.</font></td>
|
||
</tr>
|
||
<tr>
|
||
<td WIDTH="53%" VALIGN="TOP"><font FACE="Arial" SIZE="2">WBEM_FLAG_CREATE_ONLY</font></td>
|
||
<td WIDTH="47%" VALIGN="TOP"><font FACE="Arial" SIZE="2">This flag is used for creation
|
||
only. The call will fail if the instance already exists.</font></td>
|
||
</tr>
|
||
<tr>
|
||
<td WIDTH="53%" VALIGN="TOP"><font FACE="Arial" SIZE="2">WBEM_FLAG_RETURN_IMMEDIATELY </font></td>
|
||
<td WIDTH="47%" VALIGN="TOP"><font FACE="Arial" SIZE="2">This flag causes this to be a
|
||
semisychronous call. See Making a Semisynchronous Call</font><font FACE="Arial" SIZE="2"
|
||
COLOR="#800000">_hmm_making_a_semisynchronous_call</font><font FACE="Arial" SIZE="2"> for
|
||
more information on semisynchronous calls.</font></td>
|
||
</tr>
|
||
<tr>
|
||
<td WIDTH="53%" VALIGN="TOP"><font FACE="Arial" SIZE="2">WBEM_FLAG_OWNER_UPDATE</font></td>
|
||
<td WIDTH="47%" VALIGN="TOP"><font FACE="Arial" SIZE="2">Push and push-verify providers
|
||
must specify this flag when calling <b>PutInstance</b> to update the repository.</font></td>
|
||
</tr>
|
||
</table>
|
||
|
||
<p><font FACE="Arial" SIZE="2"><i> </p>
|
||
|
||
<p>pCtx</p>
|
||
|
||
<blockquote>
|
||
</i><p>Typically NULL, indicating that every property in the instance is to be updated.
|
||
Otherwise, this is a pointer to an <b>IWbemContext</b></font><font FACE="Arial" SIZE="2"
|
||
COLOR="#800000">_hmm_IWbemContext</font><font FACE="Arial" SIZE="2"> object containing
|
||
additional information about the instance. The data in the context object must be
|
||
documented by the provider responsible for the instance. A non-NULL <b>IWbemContext</b>
|
||
object can indicate whether supports exists for partial instance updates. </p>
|
||
<p>For more information about how to support full and partial instance updates, see
|
||
Implementing IWbemServices::PutInstanceAsync</font><font FACE="Arial" SIZE="2"
|
||
COLOR="#800000">_hmm_Implementing_IWbemServices_PutInstanceAsync</font><font FACE="Arial"
|
||
SIZE="2">. </p>
|
||
<p>For more information about requesting a partial or full instance update operation, see
|
||
Updating an Instance</font><font FACE="Arial" SIZE="2" COLOR="#800000">_hmm_Updating_an_Instance</font><font
|
||
FACE="Arial" SIZE="2">.</p>
|
||
</blockquote>
|
||
|
||
<p><i> </p>
|
||
|
||
<p>ppCallResult</p>
|
||
|
||
<blockquote>
|
||
</i><p>If NULL, this parameter is not used. If the <i>lFlags </i>parameter contains
|
||
WBEM_FLAG_RETURN_IMMEDIATELY, this call will return immediately with WBEM_S_NO_ERROR. The <i>ppCallResult
|
||
</i>parameter<i> </i>will then receive a pointer to a new <b>IWbemCallResult</b></font><font
|
||
FACE="Arial" SIZE="2" COLOR="#800000">_hmm_IWbemCallResult</font><font FACE="Arial"
|
||
SIZE="2"> object, which can then be polled to obtain the result using the <b>IWbemCallResult::GetCallStatus</b></font><font
|
||
FACE="Arial" SIZE="2" COLOR="#800000">_hmm_IWbemCallResult_GetCallStatus</font><font
|
||
FACE="Arial" SIZE="2"> method.</p>
|
||
</font><font FACE="Arial" SIZE="1"><p></font> </p>
|
||
</blockquote>
|
||
|
||
<p><font FACE="Arial Narrow"><b> </p>
|
||
|
||
<p>Return Values</b></font></p>
|
||
|
||
<table CELLSPACING="0" BORDER="0" WIDTH="463">
|
||
<tr>
|
||
<td WIDTH="50%" VALIGN="TOP"><font FACE="Arial" SIZE="2">WBEM_E_ACCESS_DENIED</font></td>
|
||
<td WIDTH="50%" VALIGN="TOP"><font FACE="Arial" SIZE="2">The current user does not have
|
||
permission to update an instance of the specified class.</font></td>
|
||
</tr>
|
||
<tr>
|
||
<td WIDTH="50%" VALIGN="TOP"><font FACE="Arial" SIZE="2">WBEM_E_ALREADY_EXISTS</font></td>
|
||
<td WIDTH="50%" VALIGN="TOP"><font FACE="Arial" SIZE="2">WBEM_FLAG_CREATE_ONLY flag was
|
||
specified, but the instance already exists.</font></td>
|
||
</tr>
|
||
<tr>
|
||
<td WIDTH="50%" VALIGN="TOP"><font FACE="Arial" SIZE="2">WBEM_E_INVALID_CLASS</font></td>
|
||
<td WIDTH="50%" VALIGN="TOP"><font FACE="Arial" SIZE="2">The class supporting this
|
||
instance is invalid.</font></td>
|
||
</tr>
|
||
<tr>
|
||
<td WIDTH="50%" VALIGN="TOP"><font FACE="Arial" SIZE="2">WBEM_E_FAILED</font></td>
|
||
<td WIDTH="50%" VALIGN="TOP"><font FACE="Arial" SIZE="2">This indicates other unspecified
|
||
errors.</font></td>
|
||
</tr>
|
||
<tr>
|
||
<td WIDTH="50%" VALIGN="TOP"><font FACE="Arial" SIZE="2">WBEM_E_ILLEGAL_NULL</font></td>
|
||
<td WIDTH="50%" VALIGN="TOP"><font FACE="Arial" SIZE="2">A NULL value was specified for a
|
||
property that may not be NULL, such as one that is marked by a key</font><font
|
||
FACE="Arial" SIZE="2" COLOR="#800000">_hmm_standard_qualifier_reference</font><font
|
||
FACE="Arial" SIZE="2">, indexed</font><font FACE="Arial" SIZE="2" COLOR="#800000">_hmm_standard_qualifier_reference</font><font
|
||
FACE="Arial" SIZE="2">, or not_null</font><font FACE="Arial" SIZE="2" COLOR="#800000">_hmm_standard_qualifier_reference</font><font
|
||
FACE="Arial" SIZE="2"> qualifier.</font></td>
|
||
</tr>
|
||
<tr>
|
||
<td WIDTH="50%" VALIGN="TOP"><font FACE="Arial" SIZE="2">WBEM_E_INVALID_OBJECT</font></td>
|
||
<td WIDTH="50%" VALIGN="TOP"><font FACE="Arial" SIZE="2">The specified instance is invalid
|
||
(for example, <b>PutInstance</b> with a Class will invoke this return). </font></td>
|
||
</tr>
|
||
<tr>
|
||
<td WIDTH="50%" VALIGN="TOP"><font FACE="Arial" SIZE="2">WBEM_E_INVALID_PARAMETER</font></td>
|
||
<td WIDTH="50%" VALIGN="TOP"><font FACE="Arial" SIZE="2">An invalid parameter was
|
||
specified.</font></td>
|
||
</tr>
|
||
<tr>
|
||
<td WIDTH="50%" VALIGN="TOP"><font FACE="Arial" SIZE="2">WBEM_E_NOT_FOUND</font></td>
|
||
<td WIDTH="50%" VALIGN="TOP"><font FACE="Arial" SIZE="2">WBEM_FLAG_UPDATE_ONLY flag was
|
||
specified, but the instance does not exist.</font></td>
|
||
</tr>
|
||
<tr>
|
||
<td WIDTH="50%" VALIGN="TOP"><font FACE="Arial" SIZE="2">WBEM_E_OUT_OF_MEMORY</font></td>
|
||
<td WIDTH="50%" VALIGN="TOP"><font FACE="Arial" SIZE="2">There was not enough memory to
|
||
complete the operation.</font></td>
|
||
</tr>
|
||
<tr>
|
||
<td WIDTH="50%" VALIGN="TOP"><font FACE="Arial" SIZE="2">WBEM_E_TRANSPORT_FAILURE</font></td>
|
||
<td WIDTH="50%" VALIGN="TOP"><font FACE="Arial" SIZE="2">This indicates the failure of the
|
||
remote procedure call (RPC) link between the current process and CIMOM.</font></td>
|
||
</tr>
|
||
<tr>
|
||
<td WIDTH="50%" VALIGN="TOP"><font FACE="Arial" SIZE="2">WBEM_S_NO_ERROR</font></td>
|
||
<td WIDTH="50%" VALIGN="TOP"><font FACE="Arial" SIZE="2">The call succeeded.</font></td>
|
||
</tr>
|
||
</table>
|
||
|
||
<p><font FACE="Arial" SIZE="2"> </p>
|
||
|
||
<p>DCOM-specific error codes also may be returned if network problems cause you to lose
|
||
the remote connection to CIMOM.</font><font FACE="Arial Narrow"><b></p>
|
||
|
||
<p>Remarks</b></font><font FACE="Arial" SIZE="2"></p>
|
||
|
||
<p>Applications and providers call <b>PutInstance</b> to create or update an instance of
|
||
an existing class. Depending on how the <i>pCtx</i> parameter is set, either some or all
|
||
of the properties of the instance are updated. For information about how to support
|
||
partial instance updating, see Implementing IWbemServices::PutInstanceAsync</font><font
|
||
FACE="Arial" SIZE="2" COLOR="#800000">_hmm_Implementing_IWbemServices_PutInstanceAsync</font><font
|
||
FACE="Arial" SIZE="2">. For information about requesting a partial instance update, see
|
||
Updating an Instance</font><font FACE="Arial" SIZE="2" COLOR="#800000">_hmm_Updating_an_Instance</font><font
|
||
FACE="Arial" SIZE="2">.</p>
|
||
|
||
<p><b> </p>
|
||
|
||
<p>PutInstance</b> supports creating instances and updating instances only. It does not
|
||
support moving instances. That is, a caller cannot set the <i>pInst</i> parameter to an
|
||
instance that has a key that is the same as another instance in a sibling class. For
|
||
example, suppose ClassA is the base class to ClassB and ClassC. ClassA defines the KeyProp
|
||
property as its key and ClassB has an instance that has KeyProp set to 1. To create an
|
||
instance of ClassC with KeyProp set to1, an application must first delete the ClassB
|
||
instance by calling <b>DeleteInstance</b></font><font FACE="Arial" SIZE="2"
|
||
COLOR="#800000">_hmm_IWbemServices_DeleteInstance</font><font FACE="Arial" SIZE="2"> and
|
||
then save it with <b>PutInstance</b>. </p>
|
||
|
||
<p>When the instance pointed to by <i>pInst</i> belongs to a subclass, CIMOM calls all of
|
||
the providers responsible for the classes from which the subclass derives. All of these
|
||
providers must succeed in order for the original <b>PutInstance</b> request to succeed.
|
||
The provider supporting the topmost class in the hierarchy is called first. The calling
|
||
order continues with the subclass of the topmost class and proceeds from top to bottom
|
||
until CIMOM reaches the provider for the class owning the instance pointed to by <i>pInst</i>.
|
||
</p>
|
||
|
||
<p>CIMOM does not call the providers for any of the child classes of an instance.
|
||
Therefore, if an application wants to change the values of inherited properties, the
|
||
application must call PutInstance on the full instance of the child class rather than a
|
||
corresponding instance of the parent class. </p>
|
||
|
||
<p>Calling <b>PutInstance</b> on an instance of an abstract class is not allowed. </font><font
|
||
FACE="Arial Narrow"><b></p>
|
||
|
||
<p>See Also</b></font><font FACE="Arial" SIZE="2"></p>
|
||
|
||
<p>Error Handling for Applications</font><font FACE="Arial" SIZE="2" COLOR="#800000">_hmm_Error_Handling_for_Applications</font><font
|
||
FACE="Arial" SIZE="2">, <b>IWbemCallResult</b></font><font FACE="Arial" SIZE="2"
|
||
COLOR="#800000">_hmm_IWbemCallResult</font><font FACE="Arial" SIZE="2">, <b>IWbemServices::PutInstanceAsync</b></font><font
|
||
FACE="Arial" SIZE="2" COLOR="#800000">_hmm_IWbemServices_PutInstanceAsync</font><font
|
||
FACE="Arial" SIZE="2">,<b> </b>Instance Creation and Modification Rules</font><font
|
||
FACE="Arial" SIZE="2" COLOR="#800000">_hmm_creating_an_instance</font><font
|
||
FACE="Arial Narrow" SIZE="5" COLOR="#800000"></p>
|
||
|
||
<p>‹^</font><font FACE="Arial Narrow" SIZE="5"><b># $ K + </b></font><font
|
||
FACE="Arial Narrow" SIZE="5" COLOR="#800000">›</font><b><font FACE="Arial Narrow"
|
||
SIZE="5">IWbemServices::PutInstanceAsync</font><font FACE="Arial Narrow" SIZE="1"
|
||
COLOR="#800000"><EFBFBD>@<40></font></b><font SIZE="2" COLOR="#ff00ff"></p>
|
||
|
||
<p><span style=color:#FF0000></font><font FACE="Arial" SIZE="2" COLOR="#ff0000">[This
|
||
is preliminary documentation and subject to change.]</font><font SIZE="2" COLOR="#ff00ff"></span></font><font
|
||
FACE="Arial" SIZE="2"> </p>
|
||
|
||
<p>The <b>IWbemServices::PutInstanceAsync</b> method asynchronously creates or updates an
|
||
instance of an existing class. Update confirmation or error reporting is provided through
|
||
the <b>IWbemObjectSink</b></font><font FACE="Arial" SIZE="2" COLOR="#800000">_hmm_IWbemObjectSink</font><font
|
||
FACE="Arial" SIZE="2"> interface implemented by the caller. </font><font
|
||
FACE="Lucida Sans Typewriter" SIZE="2"><b></p>
|
||
|
||
<p>HRESULT IWbemServices::PutInstanceAsync(</p>
|
||
|
||
<p>[in] IWbemClassObject</b><i> pInst</i><b>, </p>
|
||
|
||
<p>[in] LONG</b><i> lFlags</i><b>, </p>
|
||
|
||
<p>[in] IWbemContext</b><i> *pCtx</i><b>, </p>
|
||
|
||
<p>[in] IWbemObjectSink</b><i> *pResponseHandler</i><b> </p>
|
||
|
||
<p>);</b></p>
|
||
|
||
<p></font><font FACE="Arial Narrow"><b> </p>
|
||
|
||
<p>Parameters</b></font><font FACE="Arial" SIZE="2"><i></p>
|
||
|
||
<p>pInst</p>
|
||
|
||
<blockquote>
|
||
</i><p>Points to the instance to be written to the CIMOM repository. The caller cannot
|
||
make assumptions about the reference count at the completion of this call. .</p>
|
||
</blockquote>
|
||
|
||
<p><i> </p>
|
||
|
||
<p>lFlags</p>
|
||
|
||
<blockquote>
|
||
</i><p>One or more of the following values can be specified:</font></p>
|
||
</blockquote>
|
||
|
||
<p ALIGN="LEFT"> </p>
|
||
|
||
<table CELLSPACING="0" BORDER="0" WIDTH="445">
|
||
<tr>
|
||
<td WIDTH="53%" VALIGN="TOP"><font FACE="Arial" SIZE="2"><b>Flag</b></font></td>
|
||
<td WIDTH="47%" VALIGN="TOP"><font FACE="Arial" SIZE="2"><b>Description</b></font></td>
|
||
</tr>
|
||
<tr>
|
||
<td WIDTH="53%" VALIGN="TOP"><font FACE="Arial" SIZE="2">WBEM_FLAG_CREATE_OR_UPDATE</font></td>
|
||
<td WIDTH="47%" VALIGN="TOP"><font FACE="Arial" SIZE="2">This flag causes this instance to
|
||
be created if it does not exist or be overwritten if it exists already. </font></td>
|
||
</tr>
|
||
<tr>
|
||
<td WIDTH="53%" VALIGN="TOP"><font FACE="Arial" SIZE="2">WBEM_FLAG_UPDATE_ONLY</font></td>
|
||
<td WIDTH="47%" VALIGN="TOP"><font FACE="Arial" SIZE="2">Updates an existing instance </font></td>
|
||
</tr>
|
||
<tr>
|
||
<td WIDTH="53%" VALIGN="TOP"><font FACE="Arial" SIZE="2">WBEM_FLAG_CREATE_ONLY</font></td>
|
||
<td WIDTH="47%" VALIGN="TOP"><font FACE="Arial" SIZE="2">This flag is for instance
|
||
creation only. The call will fail if the class already exists.</font></td>
|
||
</tr>
|
||
<tr>
|
||
<td WIDTH="53%" VALIGN="TOP"><font FACE="Arial" SIZE="2">WBEM_FLAG_SEND_STATUS </font></td>
|
||
<td WIDTH="47%" VALIGN="TOP"><font FACE="Arial" SIZE="2">This flag registers with CIMOM a
|
||
request to receive intermediate status reports through the clients implementation of <b>IWbemObjectSink::SetStatus</b>.</font></td>
|
||
</tr>
|
||
<tr>
|
||
<td WIDTH="53%" VALIGN="TOP"><font FACE="Arial" SIZE="2">WBEM_FLAG_OWNER_UPDATE</font></td>
|
||
<td WIDTH="47%" VALIGN="TOP"><font FACE="Arial" SIZE="2">Push providers must specify this
|
||
flag when calling <b>PutInstanceAsync</b> to indicate that this class has changed.</font></td>
|
||
</tr>
|
||
</table>
|
||
|
||
<p><font FACE="Arial" SIZE="2"><i> </p>
|
||
|
||
<p>pCtx</p>
|
||
|
||
<blockquote>
|
||
</i><p>Typically NULL. Otherwise, this is a pointer to an <b>IWbemContext</b> object
|
||
required by the dynamic class provider that is producing the class instances. The values
|
||
in the context object must be specified in the documentation for the provider in question.
|
||
See Making Calls to CIMOM</font><font FACE="Arial" SIZE="2" COLOR="#800000">_hmm_Making_Calls_to_CIMOM</font><font
|
||
FACE="Arial" SIZE="2"> for more information about this parameter.</p>
|
||
</blockquote>
|
||
|
||
<p><i> </p>
|
||
|
||
<p>pResponseHandler</p>
|
||
|
||
<blockquote>
|
||
</i><p>Points to the caller's implementation of <b>IWbemObjectSink</b></font><font
|
||
FACE="Arial" SIZE="2" COLOR="#800000">_hmm_IWbemObjectSink</font><font FACE="Arial"
|
||
SIZE="2">. This handler receives the status of this call when it becomes available using
|
||
the <b>IWbemObjectSink::SetStatus</b></font><font FACE="Arial" SIZE="2" COLOR="#800000">_hmm_IWbemObjectSink_SetStatus</font><font
|
||
FACE="Arial" SIZE="2"> method. If any error code is returned, then the supplied <b>IWbemObjectSink</b>
|
||
pointer will not be used. If WBEM_S_NO_ERROR is returned, then the user's <b>IWbemObjectSink</b>
|
||
implementation will be called to indicate the result of the operation. CIMOM only calls <b>AddRef</b>
|
||
on the pointer in cases where WBEM_S_NO_ERROR returns. In cases where an error code
|
||
returns, the reference count is the same as on entry. For a detailed explanation of how to
|
||
make asychronous calls, see Making an Asynchronous Call</font><font FACE="Arial" SIZE="2"
|
||
COLOR="#800000">_hmm_Making_an_Asynchronous_Call</font><font FACE="Arial" SIZE="2">.</p>
|
||
</font><font FACE="Arial" SIZE="1"><p></font> </p>
|
||
</blockquote>
|
||
|
||
<p><font FACE="Arial Narrow"><b> </p>
|
||
|
||
<p>Return Values</b></font></p>
|
||
|
||
<table CELLSPACING="0" BORDER="0" WIDTH="463">
|
||
<tr>
|
||
<td WIDTH="50%" VALIGN="TOP"><font FACE="Arial" SIZE="2">WBEM_E_ALREADY_EXISTS</font></td>
|
||
<td WIDTH="50%" VALIGN="TOP"><font FACE="Arial" SIZE="2">WBEM_FLAG_CREATE_ONLY flag was
|
||
specified, but the instance already exists.</font></td>
|
||
</tr>
|
||
<tr>
|
||
<td WIDTH="50%" VALIGN="TOP"><font FACE="Arial" SIZE="2">WBEM_E_FAILED</font></td>
|
||
<td WIDTH="50%" VALIGN="TOP"><font FACE="Arial" SIZE="2">This indicates other unspecified
|
||
errors.</font></td>
|
||
</tr>
|
||
<tr>
|
||
<td WIDTH="50%" VALIGN="TOP"><font FACE="Arial" SIZE="2">WBEM_E_ACCESS_DENIED</font></td>
|
||
<td WIDTH="50%" VALIGN="TOP"><font FACE="Arial" SIZE="2">The user does not have permission
|
||
to add or update the instance specified.</font></td>
|
||
</tr>
|
||
<tr>
|
||
<td WIDTH="50%" VALIGN="TOP"><font FACE="Arial" SIZE="2">WBEM_E_INVALID_OBJECT</font></td>
|
||
<td WIDTH="50%" VALIGN="TOP"><font FACE="Arial" SIZE="2">The specified instance is
|
||
invalid. You will see this error if the supplied object is not an instance object.</font></td>
|
||
</tr>
|
||
<tr>
|
||
<td WIDTH="50%" VALIGN="TOP"><font FACE="Arial" SIZE="2">WBEM_E_ILLEGAL_NULL</font></td>
|
||
<td WIDTH="50%" VALIGN="TOP"><font FACE="Arial" SIZE="2">A NULL value was specified for a
|
||
property that is not NULL, such as one marked by a key</font><font FACE="Arial" SIZE="2"
|
||
COLOR="#800000">_hmm_standard_qualifier_reference</font><font FACE="Arial" SIZE="2">,
|
||
indexed</font><font FACE="Arial" SIZE="2" COLOR="#800000">_hmm_standard_qualifier_reference</font><font
|
||
FACE="Arial" SIZE="2">, or not_null</font><font FACE="Arial" SIZE="2" COLOR="#800000">_hmm_standard_qualifier_reference</font><font
|
||
FACE="Arial" SIZE="2"> qualifier.</font></td>
|
||
</tr>
|
||
<tr>
|
||
<td WIDTH="50%" VALIGN="TOP"><font FACE="Arial" SIZE="2">WBEM_E_INVALID_CLASS</font></td>
|
||
<td WIDTH="50%" VALIGN="TOP"><font FACE="Arial" SIZE="2">The specified class was invalid.</font></td>
|
||
</tr>
|
||
<tr>
|
||
<td WIDTH="50%" VALIGN="TOP"><font FACE="Arial" SIZE="2">WBEM_E_INVALID_PARAMETER</font></td>
|
||
<td WIDTH="50%" VALIGN="TOP"><font FACE="Arial" SIZE="2">An invalid parameter was
|
||
specified.</font></td>
|
||
</tr>
|
||
<tr>
|
||
<td WIDTH="50%" VALIGN="TOP"><font FACE="Arial" SIZE="2">WBEM_E_NOT_FOUND</font></td>
|
||
<td WIDTH="50%" VALIGN="TOP"><font FACE="Arial" SIZE="2">WBEM_FLAG_UPDATE_ONLY flag was
|
||
specified, but the instance does not exist.</font></td>
|
||
</tr>
|
||
<tr>
|
||
<td WIDTH="50%" VALIGN="TOP"><font FACE="Arial" SIZE="2">WBEM_E_OUT_OF_MEMORY</font></td>
|
||
<td WIDTH="50%" VALIGN="TOP"><font FACE="Arial" SIZE="2">There was not enough memory to
|
||
complete the operation.</font></td>
|
||
</tr>
|
||
<tr>
|
||
<td WIDTH="50%" VALIGN="TOP"><font FACE="Arial" SIZE="2">WBEM_E_TRANSPORT_FAILURE</font></td>
|
||
<td WIDTH="50%" VALIGN="TOP"><font FACE="Arial" SIZE="2">This indicates the failure of the
|
||
remote procedure call (RPC) link between the current process and CIMOM.</font></td>
|
||
</tr>
|
||
<tr>
|
||
<td WIDTH="50%" VALIGN="TOP"><font FACE="Arial" SIZE="2">WBEM_S_NO_ERROR</font></td>
|
||
<td WIDTH="50%" VALIGN="TOP"><font FACE="Arial" SIZE="2">The call succeeded.</font></td>
|
||
</tr>
|
||
</table>
|
||
|
||
<p><font FACE="Arial" SIZE="2"> </p>
|
||
|
||
<p>DCOM-specific error codes also may be returned if network problems cause you to lose
|
||
the remote connection to CIMOM.</font><font FACE="Arial Narrow"><b></p>
|
||
|
||
<p>Remarks</b></font><font FACE="Arial" SIZE="2"></p>
|
||
|
||
<p>Clients that call <b>PutInstanceAsync</b> must always expect the results of the call to
|
||
be reported using their <b>IWbemObjectSink::Indicate</b></font><font FACE="Arial" SIZE="2"
|
||
COLOR="#800000">_hmm_IWbemObjectSink_Indicate</font><font FACE="Arial" SIZE="2"> method. </p>
|
||
|
||
<p>When the instance pointed to by <i>pInst</i> belongs to a class that is derived from
|
||
other classes, the success of <b>PutInstanceAsync</b> depends on the success of the
|
||
providers responsible for the superclasses. For example, if <i>pInst</i> belongs to ClassB
|
||
and ClassB derives from ClassA, a call to the <b>PutInstanceAsync</b> method implemented
|
||
by the provider for ClassA must succeed in order for the update operation on ClassB to
|
||
succeed. For more information, see the <b>Remarks</b> section for <b>IWbemServices::PutInstance</b></font><font
|
||
FACE="Arial" SIZE="2" COLOR="#800000">_hmm_IWbemServices_PutInstance</font><font
|
||
FACE="Arial" SIZE="2">. </font><font FACE="Arial Narrow"><b></p>
|
||
|
||
<p>See Also</b></font><font FACE="Arial" SIZE="2"></p>
|
||
|
||
<p>Asynchronous Methods</font><font FACE="Arial" SIZE="2" COLOR="#800000">_hmm_making_an_asynchronous_call</font><font
|
||
FACE="Arial" SIZE="2">, <b>IWbemContext</b></font><font FACE="Arial" SIZE="2"
|
||
COLOR="#800000">_hmm_IWbemContext</font><font FACE="Arial" SIZE="2">, Instance Creation
|
||
and Modification Rules</font><font FACE="Arial" SIZE="2" COLOR="#800000">_hmm_creating_an_instance</font><font
|
||
FACE="Arial Narrow" SIZE="5" COLOR="#800000"></p>
|
||
|
||
<p>‹^</font><font FACE="Arial Narrow" SIZE="5"><b># $ K + </b></font><font
|
||
FACE="Arial Narrow" SIZE="5" COLOR="#800000">›</font><b><font FACE="Arial Narrow"
|
||
SIZE="5">IWbemServices::DeleteInstance</font><font FACE="Arial Narrow" SIZE="1"
|
||
COLOR="#800000"><EFBFBD>@<40></font></b><font SIZE="2" COLOR="#ff00ff"></p>
|
||
|
||
<p><span style=color:#FF0000></font><font FACE="Arial" SIZE="2" COLOR="#ff0000">[This
|
||
is preliminary documentation and subject to change.]</font><font SIZE="2" COLOR="#ff00ff"></span></font><font
|
||
FACE="Arial" SIZE="2"> </p>
|
||
|
||
<p>The <b>IWbemServices::DeleteInstance</b> method deletes an instance of an existing
|
||
class in the current namespace.</font><font FACE="Lucida Sans Typewriter" SIZE="2"><b></p>
|
||
|
||
<p>HRESULT IWbemServices::DeleteInstance(</p>
|
||
|
||
<p>[in] BSTR</b><i> strObjectPath</i><b>, </p>
|
||
|
||
<p>[in] LONG</b><i> lFlags</i><b>, </p>
|
||
|
||
<p>[in] IWbemContext</b><i> *pCtx</i><b>, </p>
|
||
|
||
<p>[out, OPTIONAL] IWbemCallResult</b><i> **ppCallResult </i><b></p>
|
||
|
||
<p>);</b></p>
|
||
|
||
<p></font><font FACE="Arial Narrow"><b> </p>
|
||
|
||
<p>Parameters</b></font><font FACE="Arial" SIZE="2"><i></p>
|
||
|
||
<p>strObjectPath</p>
|
||
|
||
<blockquote>
|
||
</i><p>A valid BSTR containing the object path to the instance to be deleted.</p>
|
||
</blockquote>
|
||
|
||
<p><i> </p>
|
||
|
||
<p>lFlags</p>
|
||
|
||
<blockquote>
|
||
</i><p>One of the following values are valid:</font></p>
|
||
</blockquote>
|
||
|
||
<p ALIGN="LEFT"> </p>
|
||
|
||
<table CELLSPACING="0" BORDER="0" WIDTH="445">
|
||
<tr>
|
||
<td WIDTH="53%" VALIGN="TOP"><font FACE="Arial" SIZE="2"><b>Flag</b></font></td>
|
||
<td WIDTH="47%" VALIGN="TOP"><font FACE="Arial" SIZE="2"><b>Description</b></font></td>
|
||
</tr>
|
||
<tr>
|
||
<td WIDTH="53%" VALIGN="TOP"><font FACE="Arial" SIZE="2">WBEM_FLAG_RETURN_IMMEDIATELY </font></td>
|
||
<td WIDTH="47%" VALIGN="TOP"><font FACE="Arial" SIZE="2">This flag causes this to be a
|
||
semisychronous call. See Making a Semisynchronous Call</font><font FACE="Arial" SIZE="2"
|
||
COLOR="#800000">_hmm_making_a_semisynchronous_call</font><font FACE="Arial" SIZE="2"> for
|
||
more information on semisynchronous calls.</font></td>
|
||
</tr>
|
||
<tr>
|
||
<td WIDTH="53%" VALIGN="TOP"><font FACE="Arial" SIZE="2">WBEM_FLAG_OWNER_UPDATE</font></td>
|
||
<td WIDTH="47%" VALIGN="TOP"><font FACE="Arial" SIZE="2">Push and push-verify providers
|
||
must set this flag when deleting an instance.</font></td>
|
||
</tr>
|
||
</table>
|
||
|
||
<p><font FACE="Arial" SIZE="2"><i> </p>
|
||
|
||
<p>pCtx</p>
|
||
|
||
<blockquote>
|
||
</i><p>Typically NULL. Otherwise, this is a pointer to an <b>IWbemContext</b> object that
|
||
may be used by the provider that is deleting the instance. The values in the context
|
||
object must be specified in the documentation for the provider in question. </p>
|
||
</blockquote>
|
||
|
||
<p><i> </p>
|
||
|
||
<p>ppCallResult</p>
|
||
|
||
<blockquote>
|
||
</i><p>If NULL, this parameter is not used. If <i>ppCallResult</i> is specified, it must
|
||
be set to point to NULL on entry. If the <i>lFlags </i>parameter contains
|
||
WBEM_FLAG_RETURN_IMMEDIATELY, this call will return immediately with WBEM_S_NO_ERROR. The <i>ppCallResult
|
||
</i>parameter<i> </i>will receive a pointer to a new <b>IWbemCallResult</b></font><font
|
||
FACE="Arial" SIZE="2" COLOR="#800000">_hmm_IWbemCallResult</font><font FACE="Arial"
|
||
SIZE="2"> object, which can then be polled to obtain the result using the <b>GetCallStatus</b></font><font
|
||
FACE="Arial" SIZE="2" COLOR="#800000">_hmm_IWbemCallresult_GetCallStatus</font><font
|
||
FACE="Arial" SIZE="2"><i> </i>method.</p>
|
||
</font><font FACE="Arial" SIZE="1"><p></font> </p>
|
||
</blockquote>
|
||
|
||
<p><font FACE="Arial Narrow"><b> </p>
|
||
|
||
<p>Return Values</b></font></p>
|
||
|
||
<table CELLSPACING="0" BORDER="0" WIDTH="463">
|
||
<tr>
|
||
<td WIDTH="50%" VALIGN="TOP"><font FACE="Arial" SIZE="2">WBEM_E_ACCESS_DENIED</font></td>
|
||
<td WIDTH="50%" VALIGN="TOP"><font FACE="Arial" SIZE="2">The current context does not have
|
||
adequate rights to delete the object.</font></td>
|
||
</tr>
|
||
<tr>
|
||
<td WIDTH="50%" VALIGN="TOP"><font FACE="Arial" SIZE="2">WBEM_E_FAILED</font></td>
|
||
<td WIDTH="50%" VALIGN="TOP"><font FACE="Arial" SIZE="2">This indicates other unspecified
|
||
errors.</font></td>
|
||
</tr>
|
||
<tr>
|
||
<td WIDTH="50%" VALIGN="TOP"><font FACE="Arial" SIZE="2">WBEM_E_INVALID_CLASS</font></td>
|
||
<td WIDTH="50%" VALIGN="TOP"><font FACE="Arial" SIZE="2">The specified class does not
|
||
exist.</font></td>
|
||
</tr>
|
||
<tr>
|
||
<td WIDTH="50%" VALIGN="TOP"><font FACE="Arial" SIZE="2">WBEM_E_INVALID_PARAMETER</font></td>
|
||
<td WIDTH="50%" VALIGN="TOP"><font FACE="Arial" SIZE="2">One of the parameters was not
|
||
valid. This will be attempting to delete a class object.</font></td>
|
||
</tr>
|
||
<tr>
|
||
<td WIDTH="50%" VALIGN="TOP"><font FACE="Arial" SIZE="2">WBEM_E_NOT_FOUND</font></td>
|
||
<td WIDTH="50%" VALIGN="TOP"><font FACE="Arial" SIZE="2">The object did not exist.</font></td>
|
||
</tr>
|
||
<tr>
|
||
<td WIDTH="50%" VALIGN="TOP"><font FACE="Arial" SIZE="2">WBEM_E_OUT_OF_MEMORY</font></td>
|
||
<td WIDTH="50%" VALIGN="TOP"><font FACE="Arial" SIZE="2">There was not enough memory to
|
||
complete the operation.</font></td>
|
||
</tr>
|
||
<tr>
|
||
<td WIDTH="50%" VALIGN="TOP"><font FACE="Arial" SIZE="2">WBEM_E_TRANSPORT_FAILURE</font></td>
|
||
<td WIDTH="50%" VALIGN="TOP"><font FACE="Arial" SIZE="2">This indicates the failure of the
|
||
remote procedure call (RPC) link between the current process and CIMOM.</font></td>
|
||
</tr>
|
||
<tr>
|
||
<td WIDTH="50%" VALIGN="TOP"><font FACE="Arial" SIZE="2">WBEM_S_NO_ERROR</font></td>
|
||
<td WIDTH="50%" VALIGN="TOP"><font FACE="Arial" SIZE="2">The call succeeded.</font></td>
|
||
</tr>
|
||
</table>
|
||
|
||
<p><font FACE="Arial" SIZE="2"> </p>
|
||
|
||
<p>On failure, you can obtain any available information from the COM function <b>GetErrorInfo</b>.</p>
|
||
|
||
<p>DCOM-specific error codes also may be returned if network problems cause you to lose
|
||
the remote connection to CIMOM.</font><b><font FACE="Arial Narrow"></p>
|
||
|
||
<p>Remarks</font><font FACE="Arial" SIZE="2"></p>
|
||
|
||
<p>IWbemServices::DeleteInstance</b> is called to delete an existing instance in the
|
||
current namespace. Instances in other namespaces cannot be deleted. When <b>DeleteInstance</b>
|
||
is called to delete an instance that belongs to a class in a hierachy, CIMOM calls the <b>DeleteInstanceAsync</b>
|
||
method for all of the providers responsible for non-abstract classes in the hierarchy.
|
||
That is, if the <i>strObjectPath</i> parameter identifies an instance of ClassB, and
|
||
ClassB derives from ClassA, a non-abstract class, and is the parent class of ClassC and
|
||
ClassD, also non-abstract classes, the providers for all four classes are called. </p>
|
||
|
||
<p>CIMOM calls each provider with an object path that is modified to point to their class.
|
||
For example, if <i>strObjectPath</i> for the original call is set to
|
||
"ClassB.k=1", the call to the provider of ClassA would set <i>strObjectPath</i>
|
||
to "ClassA.k=1".</p>
|
||
|
||
<p>The success of a <b>DeleteInstance</b> call depends only on the success of a <b>DeleteInstanceAsync</b>
|
||
call to the provider of the top-most non-abstract class. A non-abstract class has an
|
||
abstract class as its parent. If the provider for any one of such classes succeeds, the
|
||
operations succeeds, if all such classes fail, the operation fails.</p>
|
||
|
||
<p>For example, assume that ClassX is the base class for the following hierarchy:</p>
|
||
|
||
<blockquote>
|
||
<p>1. ClassA derives from ClassX.</p>
|
||
<p>2. ClassB derives from ClassA.</p>
|
||
<p>3. ClassC and ClassD derive from ClassB.</p>
|
||
</font>
|
||
</blockquote>
|
||
|
||
<p><font FACE="Arial" SIZE="2"> </p>
|
||
|
||
<p>If ClassX is the only abstract class in the hierarchy and the <i>strObjectPath</i>
|
||
parameter in <b>DeleteInstance</b> points to an instance of ClassB, only the provider for
|
||
ClassA needs to succeed in its <b>DeleteInstanceAsync</b> call.</p>
|
||
|
||
<p>If ClassX, ClassA, and ClassB are all abstract and the <i>strObjectPath</i> parameter
|
||
in <b>DeleteInstance</b> again points to an instance of ClassB, either the provider for
|
||
ClassC or the provider for ClassD must succeed. </font><font FACE="Arial Narrow"><b></p>
|
||
|
||
<p>See Also</b></font><font FACE="Arial" SIZE="2"></p>
|
||
|
||
<p>Error Handling for Applications</font><font FACE="Arial" SIZE="2" COLOR="#800000">_hmm_Error_Handling_for_Applications</font><font
|
||
FACE="Arial" SIZE="2">, <b>IWbemCallResult</b></font><font FACE="Arial" SIZE="2"
|
||
COLOR="#800000">_hmm_IWbemCallResult</font><font FACE="Arial" SIZE="2">, <b>IWbemServices::DeleteInstanceAsync</b></font><font
|
||
FACE="Arial" SIZE="2" COLOR="#800000">_hmm_IWbemServices_DeleteInstanceAsync</font><font
|
||
FACE="Arial" SIZE="2">, Object Paths</font><font FACE="Arial" SIZE="2" COLOR="#800000">_hmm_Object_Paths</font><font
|
||
FACE="Arial Narrow" SIZE="5" COLOR="#800000"></p>
|
||
|
||
<p>‹^</font><font FACE="Arial Narrow" SIZE="5"><b># $ K + </b></font><font
|
||
FACE="Arial Narrow" SIZE="5" COLOR="#800000">›</font><b><font FACE="Arial Narrow"
|
||
SIZE="5">IWbemServices::DeleteInstanceAsync</font><font FACE="Arial Narrow" SIZE="1"
|
||
COLOR="#800000"><EFBFBD>@<40></font></b><font SIZE="2" COLOR="#ff00ff"></p>
|
||
|
||
<p><span style=color:#FF0000></font><font FACE="Arial" SIZE="2" COLOR="#ff0000">[This
|
||
is preliminary documentation and subject to change.]</font><font SIZE="2" COLOR="#ff00ff"></span></font><font
|
||
FACE="Arial" SIZE="2"> </p>
|
||
|
||
<p>The <b>IWbemServices::DeleteInstanceAsync</b> method asynchronously deletes an instance
|
||
of an existing class in the current namespace. The confirmation or failure of the
|
||
operation is reported through the <b>IWbemObjectSink</b></font><font FACE="Arial" SIZE="2"
|
||
COLOR="#800000">_hmm_IWbemObjectSink</font><font FACE="Arial" SIZE="2"> interface
|
||
implemented by the caller. </font><font FACE="Lucida Sans Typewriter" SIZE="2"><b></p>
|
||
|
||
<p>HRESULT IWbemServices::DeleteInstanceAsync(</p>
|
||
|
||
<p>[in] BSTR</b><i> strObjectPath</i><b>, </p>
|
||
|
||
<p>[in] LONG</b><i> lFlags</i><b>, </p>
|
||
|
||
<p>[in] IWbemContext</b><i> *pCtx</i><b>, </p>
|
||
|
||
<p>[in] IWbemObjectSink</b><i> *pResponseHandler</i><b> </p>
|
||
|
||
<p>);</b></p>
|
||
|
||
<p></font><font FACE="Arial Narrow"><b> </p>
|
||
|
||
<p>Parameters</b></font><font FACE="Arial" SIZE="2"><i></p>
|
||
|
||
<p>strObjectPath</p>
|
||
|
||
<blockquote>
|
||
</i><p>A valid BSTR containing the object path</font><font FACE="Arial" SIZE="2"
|
||
COLOR="#800000">_hmm_Object_Paths</font><font FACE="Arial" SIZE="2"> of the object to be
|
||
deleted.</p>
|
||
</blockquote>
|
||
|
||
<p><i> </p>
|
||
|
||
<p>lFlags</i></font></p>
|
||
|
||
<p ALIGN="LEFT"> </p>
|
||
|
||
<table CELLSPACING="0" BORDER="0" WIDTH="445">
|
||
<tr>
|
||
<td WIDTH="53%" VALIGN="TOP"><font FACE="Arial" SIZE="2"><b>Flag</b></font></td>
|
||
<td WIDTH="47%" VALIGN="TOP"><font FACE="Arial" SIZE="2"><b>Description</b></font></td>
|
||
</tr>
|
||
<tr>
|
||
<td WIDTH="53%" VALIGN="TOP"><font FACE="Arial" SIZE="2">WBEM_FLAG_SEND_STATUS </font></td>
|
||
<td WIDTH="47%" VALIGN="TOP"><font FACE="Arial" SIZE="2">This flag registers with CIMOM a
|
||
request to receive intermediate status reports through the clients implementation of <b>IWbemObjectSink::SetStatus</b>.</font></td>
|
||
</tr>
|
||
<tr>
|
||
<td WIDTH="53%" VALIGN="TOP"><font FACE="Arial" SIZE="2">WBEM_FLAG_OWNER_UPDATE</font></td>
|
||
<td WIDTH="47%" VALIGN="TOP"><font FACE="Arial" SIZE="2">Push and push-verify providers
|
||
must specify this flag when calling <b>DeleteInstanceAsync</b> to indicate that this class
|
||
has changed.</font></td>
|
||
</tr>
|
||
</table>
|
||
|
||
<p><font FACE="Arial" SIZE="2"><i> </p>
|
||
|
||
<p>pCtx</p>
|
||
|
||
<blockquote>
|
||
</i><p>Typically NULL. Otherwise, this is a pointer to an <b>IWbemContext</b> object that
|
||
may be used by the provider that is deleting the instance. The values in the context
|
||
object must be specified in the documentation for the provider in question. </p>
|
||
</blockquote>
|
||
|
||
<p><i> </p>
|
||
|
||
<p>pResponseHandler</p>
|
||
|
||
<blockquote>
|
||
</i><p>Points to the caller's implementation of <b>IWbemObjectSink</b></font><font
|
||
FACE="Arial" SIZE="2" COLOR="#800000">_hmm_IWbemObjectSink</font><font FACE="Arial"
|
||
SIZE="2">. This handler receives the status of the delete operation as it becomes
|
||
available through the <b>SetStatus</b></font><font FACE="Arial" SIZE="2" COLOR="#800000">_hmm_IWbemObjectSink_SetStatus</font><font
|
||
FACE="Arial" SIZE="2"> method. If any error code is returned, then the supplied <b>IWbemObjectSink</b>
|
||
pointer will not be used. If WBEM_S_NO_ERROR is returned, then the user's <b>IWbemObjectSink</b>
|
||
implementation will be called to indicate the result of the operation. CIMOM only calls <b>AddRef</b>
|
||
on the pointer in cases where WBEM_S_NO_ERROR returns. In cases where an error code
|
||
returns, the reference count is the same as on entry. For a detailed explanation of making
|
||
a call asynchronously, see Making an Asynchronous Call</font><font FACE="Arial" SIZE="2"
|
||
COLOR="#800000">_hmm_making_an_asynchronous_call</font><font FACE="Arial" SIZE="2">.</p>
|
||
</font><font FACE="Arial" SIZE="1"><p></font> </p>
|
||
</blockquote>
|
||
|
||
<p><font FACE="Arial Narrow"><b> </p>
|
||
|
||
<p>Return Values</b></font></p>
|
||
|
||
<table CELLSPACING="0" BORDER="0" WIDTH="464">
|
||
<tr>
|
||
<td WIDTH="50%" VALIGN="TOP"><font FACE="Arial" SIZE="2">WBEM_E_FAILED</font></td>
|
||
<td WIDTH="50%" VALIGN="TOP"><font FACE="Arial" SIZE="2">This indicates other unspecified
|
||
errors.</font></td>
|
||
</tr>
|
||
<tr>
|
||
<td WIDTH="50%" VALIGN="TOP"><font FACE="Arial" SIZE="2">WBEM_E_INVALID_CLASS</font></td>
|
||
<td WIDTH="50%" VALIGN="TOP"><font FACE="Arial" SIZE="2">The specified class was invalid.</font></td>
|
||
</tr>
|
||
<tr>
|
||
<td WIDTH="50%" VALIGN="TOP"><font FACE="Arial" SIZE="2">WBEM_E_INVALID_PARAMETER</font></td>
|
||
<td WIDTH="50%" VALIGN="TOP"><font FACE="Arial" SIZE="2">An invalid parameter was
|
||
specified.</font></td>
|
||
</tr>
|
||
<tr>
|
||
<td WIDTH="50%" VALIGN="TOP"><font FACE="Arial" SIZE="2">WBEM_E_OUT_OF_MEMORY</font></td>
|
||
<td WIDTH="50%" VALIGN="TOP"><font FACE="Arial" SIZE="2">There was not enough memory to
|
||
complete the operation.</font></td>
|
||
</tr>
|
||
<tr>
|
||
<td WIDTH="50%" VALIGN="TOP"><font FACE="Arial" SIZE="2">WBEM_E_TRANSPORT_FAILURE</font></td>
|
||
<td WIDTH="50%" VALIGN="TOP"><font FACE="Arial" SIZE="2">This indicates the failure of the
|
||
remote procedure call (RPC) link between the current process and CIMOM.</font></td>
|
||
</tr>
|
||
<tr>
|
||
<td WIDTH="50%" VALIGN="TOP"><font FACE="Arial" SIZE="2">WBEM_S_NO_ERROR</font></td>
|
||
<td WIDTH="50%" VALIGN="TOP"><font FACE="Arial" SIZE="2">The call succeeded.</font></td>
|
||
</tr>
|
||
</table>
|
||
|
||
<p><font FACE="Arial" SIZE="2"> </p>
|
||
|
||
<p>On failure, you can obtain any available information from the COM function <b>GetErrorInfo</b>.</p>
|
||
|
||
<p>Other error conditions are reported asynchronously to the object sink supplied by the <i>pResponseHandler</i>
|
||
parameter.</p>
|
||
|
||
<p>DCOM-specific error codes also may be returned if network problems cause you to lose
|
||
the remote connection to CIMOM.</font><font FACE="Arial Narrow" SIZE="3"><b></p>
|
||
|
||
<p>Note</b></font><font FACE="Arial" SIZE="2"></p>
|
||
|
||
<p>Clients that call <b>DeleteInstanceAsync</b> must always expect the results of the call
|
||
to be reported using their <b>IWbemObjectSink::Indicate</b></font><font FACE="Arial"
|
||
SIZE="2" COLOR="#800000">_hmm_IWbemObjectSink_Indicate</font><font FACE="Arial" SIZE="2">
|
||
method. </p>
|
||
|
||
<p>When the instance pointed to by <i>strObjectPath</i> belongs to a class that is a
|
||
member of a class hierarchy, the success of <b>DeleteInstanceAsync</b> depends on the
|
||
top-most non-abstract provider. For a detailed explanation of the dependencies involved
|
||
that determine the success of this operation, see the <b>Remarks</b> section for <b>IWbemServices::DeleteInstance</b></font><font
|
||
FACE="Arial" SIZE="2" COLOR="#800000">_hmm_IWbemServices_Deletenstance</font><font
|
||
FACE="Arial" SIZE="2">. </font><font FACE="Arial Narrow"><b></p>
|
||
|
||
<p>See Also</b></font><font FACE="Arial" SIZE="2"></p>
|
||
|
||
<p>Making an Asynchronous Call</font><font FACE="Arial" SIZE="2" COLOR="#800000">_hmm_Making_an_Asynchronous_Call</font><font
|
||
FACE="Arial" SIZE="2">, <b>IWbemServices::DeleteInstance</b></font><font FACE="Arial"
|
||
SIZE="2" COLOR="#800000">_hmm_IWbemServices_DeleteInstance</font><font FACE="Arial"
|
||
SIZE="2">, Object Paths</font><font FACE="Arial" SIZE="2" COLOR="#800000">_hmm_Object_Paths</font><font
|
||
FACE="Arial Narrow" SIZE="5" COLOR="#800000"></p>
|
||
|
||
<p>‹^</font><font FACE="Arial Narrow" SIZE="5"><b># $ K + </b></font><font
|
||
FACE="Arial Narrow" SIZE="5" COLOR="#800000">›</font><b><font FACE="Arial Narrow"
|
||
SIZE="5">IWbemServices::CreateInstanceEnum</font><font FACE="Arial Narrow" SIZE="1"
|
||
COLOR="#800000"><EFBFBD>@<40></font></b><font SIZE="2" COLOR="#ff00ff"></p>
|
||
|
||
<p><span style=color:#FF0000></font><font FACE="Arial" SIZE="2" COLOR="#ff0000">[This
|
||
is preliminary documentation and subject to change.]</font><font SIZE="2" COLOR="#ff00ff"></span></font><font
|
||
FACE="Arial" SIZE="2"> </p>
|
||
|
||
<p>The <b>IWbemServices::CreateInstanceEnum</b> method creates an enumerator that returns
|
||
the instances of a specified class according to user-specified selection criteria. This
|
||
method supports simple WQL queries; more complex queries can be processed using the <b>IWbemServices::ExecQuery</b></font><font
|
||
FACE="Arial" SIZE="2" COLOR="#800000">_hmm_IWbemServices_ExecQuery</font><font
|
||
FACE="Arial" SIZE="2"> method.</font><font FACE="Lucida Sans Typewriter" SIZE="2"><b></p>
|
||
|
||
<p>HRESULT IWbemServices::CreateInstanceEnum(</p>
|
||
|
||
<p>[in] BSTR</b><i> strClass</i><b>, </p>
|
||
|
||
<p>[in] LONG</b><i> lFlags</i><b>, </p>
|
||
|
||
<p>[in] IWbemContext</b><i> *pCtx</i><b>, </p>
|
||
|
||
<p>[out] IEnumWbemClassObject</b><i> **ppEnum</i><b> </p>
|
||
|
||
<p>);</b></p>
|
||
|
||
<p></font><font FACE="Arial Narrow"><b> </p>
|
||
|
||
<p>Parameters</b></font><font FACE="Arial" SIZE="2"><i></p>
|
||
|
||
<p>strClass</p>
|
||
|
||
<blockquote>
|
||
</i><p>A valid BSTR containing the name of the class for which instances are desired. This
|
||
parameter cannot be NULL.</p>
|
||
</blockquote>
|
||
|
||
<p><i> </p>
|
||
|
||
<p>lFlags</p>
|
||
|
||
<blockquote>
|
||
</i><p>The following flags affect the behavior of this method. The suggested value for
|
||
this parameter is WBEM_FLAG_RETURN_IMMEDIATELY | WBEM_FLAG_FORWARD_ONLY for best
|
||
performance.</font></p>
|
||
</blockquote>
|
||
|
||
<p ALIGN="LEFT"> </p>
|
||
|
||
<table CELLSPACING="0" BORDER="0" WIDTH="445">
|
||
<tr>
|
||
<td WIDTH="53%" VALIGN="TOP"><font FACE="Arial" SIZE="2"><b>Flag</b> </font></td>
|
||
<td WIDTH="47%" VALIGN="TOP"><font FACE="Arial" SIZE="2"><b>Description</b></font></td>
|
||
</tr>
|
||
<tr>
|
||
<td WIDTH="53%" VALIGN="TOP"><font FACE="Arial" SIZE="2">WBEM_FLAG_DEEP </font></td>
|
||
<td WIDTH="47%" VALIGN="TOP"><font FACE="Arial" SIZE="2">This flag forces the enumeration
|
||
to include all of class in the hierarchy.</font></td>
|
||
</tr>
|
||
<tr>
|
||
<td WIDTH="53%" VALIGN="TOP"><font FACE="Arial" SIZE="2">WBEM_FLAG_SHALLOW </font></td>
|
||
<td WIDTH="47%" VALIGN="TOP"><font FACE="Arial" SIZE="2">This flag forces the enumeration
|
||
to include only immediate subclasses of the specified superclass.</font></td>
|
||
</tr>
|
||
<tr>
|
||
<td WIDTH="53%" VALIGN="TOP"><font FACE="Arial" SIZE="2">WBEM_FLAG_RETURN_IMMEDIATELY </font></td>
|
||
<td WIDTH="47%" VALIGN="TOP"><font FACE="Arial" SIZE="2">This flag causes this to be a
|
||
semisycnronous call. See Making a Semisynchronous Call</font><font FACE="Arial" SIZE="2"
|
||
COLOR="#800000">_hmm_making_a_semisynchronous_call</font><font FACE="Arial" SIZE="2"> for
|
||
more information on semisynchronous calls.</font></td>
|
||
</tr>
|
||
<tr>
|
||
<td WIDTH="53%" VALIGN="TOP"><font FACE="Arial" SIZE="2">WBEM_FLAG_FORWARD_ONLY</font></td>
|
||
<td WIDTH="47%" VALIGN="TOP"><font FACE="Arial" SIZE="2">This flag causes a forward-only
|
||
enumerator to be returned. Forward-only enumerators are generally much faster and use less
|
||
memory than conventional enumerators but do not allow calls to <b>Clone</b> or <b>Reset</b>.
|
||
</font></td>
|
||
</tr>
|
||
<tr>
|
||
<td WIDTH="53%" VALIGN="TOP"><font FACE="Arial" SIZE="2">WBEM_FLAG_BIDIRECTIONAL</font></td>
|
||
<td WIDTH="47%" VALIGN="TOP"><font FACE="Arial" SIZE="2">This flag causes CIMOM to retain
|
||
pointers to objects of the enumeration until the client releases the enumerator.</font></td>
|
||
</tr>
|
||
</table>
|
||
|
||
<p><font FACE="Arial" SIZE="2"> </p>
|
||
|
||
<p> </p>
|
||
|
||
<p><i> </p>
|
||
|
||
<p>pCtx</p>
|
||
|
||
<blockquote>
|
||
</i><p>Typically NULL. Otherwise, this is a pointer to an <b>IWbemContext</b> object that
|
||
may be used by the provider that is providing the requested instances. The values in the
|
||
context object must be specified in the documentation for the provider in question. See
|
||
Making Calls to CIMOM</font><font FACE="Arial" SIZE="2" COLOR="#800000">_hmm_Making_Calls_to_CIMOM</font><font
|
||
FACE="Arial" SIZE="2"> for more information about this parameter.</p>
|
||
</blockquote>
|
||
|
||
<p><i> </p>
|
||
|
||
<p>ppEnum</p>
|
||
|
||
<blockquote>
|
||
</i><p>Receives the pointer to the enumerator, which has a positive reference count. The
|
||
caller must call <b>IUnknown::Release</b> on the pointer after it is no longer required.</p>
|
||
</font><font FACE="Arial" SIZE="1"><p></font> </p>
|
||
</blockquote>
|
||
|
||
<p><font FACE="Arial Narrow"><b> </p>
|
||
|
||
<p>Return Values</b></font></p>
|
||
|
||
<table CELLSPACING="0" BORDER="0" WIDTH="463">
|
||
<tr>
|
||
<td WIDTH="50%" VALIGN="TOP"><font FACE="Arial" SIZE="2">WBEM_E_ACCESS_DENIED</font></td>
|
||
<td WIDTH="50%" VALIGN="TOP"><font FACE="Arial" SIZE="2">The current user does not have
|
||
permission to view instances of the specified class.</font></td>
|
||
</tr>
|
||
<tr>
|
||
<td WIDTH="50%" VALIGN="TOP"><font FACE="Arial" SIZE="2">WBEM_E_FAILED</font></td>
|
||
<td WIDTH="50%" VALIGN="TOP"><font FACE="Arial" SIZE="2">This indicates other unspecified
|
||
errors.</font></td>
|
||
</tr>
|
||
<tr>
|
||
<td WIDTH="50%" VALIGN="TOP"><font FACE="Arial" SIZE="2">WBEM_E_INVALID_CLASS</font></td>
|
||
<td WIDTH="50%" VALIGN="TOP"><font FACE="Arial" SIZE="2">The specified class does not
|
||
exist or is invalid.</font></td>
|
||
</tr>
|
||
<tr>
|
||
<td WIDTH="50%" VALIGN="TOP"><font FACE="Arial" SIZE="2">WBEM_E_INVALID_PARAMETER</font></td>
|
||
<td WIDTH="50%" VALIGN="TOP"><font FACE="Arial" SIZE="2">An invalid parameter was
|
||
specified.</font></td>
|
||
</tr>
|
||
<tr>
|
||
<td WIDTH="50%" VALIGN="TOP"><font FACE="Arial" SIZE="2">WBEM_E_OUT_OF_MEMORY</font></td>
|
||
<td WIDTH="50%" VALIGN="TOP"><font FACE="Arial" SIZE="2">There was not enough memory to
|
||
complete the operation.</font></td>
|
||
</tr>
|
||
<tr>
|
||
<td WIDTH="50%" VALIGN="TOP"><font FACE="Arial" SIZE="2">WBEM_E_TRANSPORT_FAILURE</font></td>
|
||
<td WIDTH="50%" VALIGN="TOP"><font FACE="Arial" SIZE="2">This indicates the failure of the
|
||
remote procedure call (RPC) link between the current process and CIMOM.</font></td>
|
||
</tr>
|
||
<tr>
|
||
<td WIDTH="50%" VALIGN="TOP"><font FACE="Arial" SIZE="2">WBEM_S_NO_ERROR</font></td>
|
||
<td WIDTH="50%" VALIGN="TOP"><font FACE="Arial" SIZE="2">The call succeeded.</font></td>
|
||
</tr>
|
||
</table>
|
||
|
||
<p><font FACE="Arial" SIZE="2"> </p>
|
||
|
||
<p>On failure, you can obtain any available information from the COM function <b>GetErrorInfo</b>.</p>
|
||
|
||
<p>DCOM-specific error codes also may be returned if network problems cause you to lose
|
||
the remote connection to CIMOM.</font><font FACE="Arial Narrow"><b></p>
|
||
|
||
<p>Remarks</b></font><font FACE="Arial" SIZE="2"></p>
|
||
|
||
<p>It is not an error for the returned enumerator to have zero elements.</font><font
|
||
FACE="Arial Narrow"><b></p>
|
||
|
||
<p>See Also</b></font><font FACE="Arial" SIZE="2"></p>
|
||
|
||
<p>Error Handling for Applications</font><font FACE="Arial" SIZE="2" COLOR="#800000">_hmm_Error_Handling_for_Applications</font><font
|
||
FACE="Arial" SIZE="2">, <b>IWbemServices::CreateInstanceEnumAsync</b></font><font
|
||
FACE="Arial" SIZE="2" COLOR="#800000">_hmm_IWbemServices_CreateInstanceEnumAsync</font><font
|
||
FACE="Arial Narrow" SIZE="5" COLOR="#800000"></p>
|
||
|
||
<p>‹^</font><font FACE="Arial Narrow" SIZE="5"><b># $ K + </b></font><font
|
||
FACE="Arial Narrow" SIZE="5" COLOR="#800000">›</font><b><font FACE="Arial Narrow"
|
||
SIZE="5">IWbemServices::CreateInstanceEnumAsync</font><font FACE="Arial Narrow" SIZE="1"
|
||
COLOR="#800000"><EFBFBD>@<40></font></b><font SIZE="2" COLOR="#ff00ff"></p>
|
||
|
||
<p><span style=color:#FF0000></font><font FACE="Arial" SIZE="2" COLOR="#ff0000">[This
|
||
is preliminary documentation and subject to change.]</font><font SIZE="2" COLOR="#ff00ff"></span></font><font
|
||
FACE="Arial" SIZE="2"> </p>
|
||
|
||
<p>The <b>IWbemServices::CreateInstanceEnumAsync</b> method creates an enumerator that
|
||
asynchronously returns the instances of a specified class according to user-specified
|
||
selection criteria. This method supports simple WQL queries; more complex queries can be
|
||
processed using the <b>IWbemServices::ExecQueryAsync</b></font><font FACE="Arial" SIZE="2"
|
||
COLOR="#800000">_hmm_IWbemServices_ExecQueryAsync</font><font FACE="Arial" SIZE="2">
|
||
method.</font><font FACE="Lucida Sans Typewriter" SIZE="2"><b></p>
|
||
|
||
<p>HRESULT IWbemServices::CreateInstanceEnumAsync</b>(</p>
|
||
|
||
<p><b> </p>
|
||
|
||
<p>[in] BSTR</b><i> strClass</i><b>, </p>
|
||
|
||
<p>[in] LONG</b><i> lFlags</i><b>, </p>
|
||
|
||
<p>[in] IWbemContext</b><i> *pCtx</i><b>, </p>
|
||
|
||
<p>[in] IWbemObjectSink</b><i> *pResponseHandler</i><b> </p>
|
||
|
||
<p>);</b></p>
|
||
|
||
<p></font><font FACE="Arial Narrow"><b> </p>
|
||
|
||
<p>Parameters</b></font><font FACE="Arial" SIZE="2"><i></p>
|
||
|
||
<p>strClass</p>
|
||
|
||
<blockquote>
|
||
</i><p>A valid BSTR containing the name of the class for which instances are desired. This
|
||
parameter cannot be NULL.</p>
|
||
</blockquote>
|
||
|
||
<p><i> </p>
|
||
|
||
<p>lFlags</i></font></p>
|
||
|
||
<p ALIGN="LEFT"> </p>
|
||
|
||
<table CELLSPACING="0" BORDER="0" WIDTH="445">
|
||
<tr>
|
||
<td WIDTH="53%" VALIGN="TOP"><font FACE="Arial" SIZE="2"><b>Flag</b> </font></td>
|
||
<td WIDTH="47%" VALIGN="TOP"><font FACE="Arial" SIZE="2"><b>Description</b></font></td>
|
||
</tr>
|
||
<tr>
|
||
<td WIDTH="53%" VALIGN="TOP"><font FACE="Arial" SIZE="2">WBEM_FLAG_DEEP </font></td>
|
||
<td WIDTH="47%" VALIGN="TOP"><font FACE="Arial" SIZE="2">This flag forces the enumeration
|
||
to include all of class in the hierarchy.</font></td>
|
||
</tr>
|
||
<tr>
|
||
<td WIDTH="53%" VALIGN="TOP"><font FACE="Arial" SIZE="2">WBEM_FLAG_SHALLOW </font></td>
|
||
<td WIDTH="47%" VALIGN="TOP"><font FACE="Arial" SIZE="2">This flag forces the enumeration
|
||
to include only immediate subclasses of the specified superclass.</font></td>
|
||
</tr>
|
||
<tr>
|
||
<td WIDTH="53%" VALIGN="TOP"><font FACE="Arial" SIZE="2">WBEM_FLAG_SEND_STATUS </font></td>
|
||
<td WIDTH="47%" VALIGN="TOP"><font FACE="Arial" SIZE="2">This flag registers with CIMOM a
|
||
request to receive intermediate status reports through the clients implementation of <b>IWbemObjectSink::SetStatus</b></font><font
|
||
FACE="Arial" SIZE="2" COLOR="#800000">_hmm_IWbemObjectSink_SetStatus</font><font
|
||
FACE="Arial" SIZE="2">.</font></td>
|
||
</tr>
|
||
<tr>
|
||
<td WIDTH="53%" VALIGN="TOP"><font FACE="Arial" SIZE="2">WBEM_FLAG_FORWARD_ONLY</font></td>
|
||
<td WIDTH="47%" VALIGN="TOP"><font FACE="Arial" SIZE="2">This flag causes a forward-only
|
||
enumerator to be returned. Forward-only enumerators are generally much faster and use less
|
||
memory than conventional enumerators but do not allow calls to <b>Clone</b> or <b>Reset</b>.
|
||
</font></td>
|
||
</tr>
|
||
<tr>
|
||
<td WIDTH="53%" VALIGN="TOP"><font FACE="Arial" SIZE="2">WBEM_FLAG_BIDIRECTIONAL</font></td>
|
||
<td WIDTH="47%" VALIGN="TOP"><font FACE="Arial" SIZE="2">This flag causes CIMOM to retain
|
||
pointers to objects of the enumeration until the client releases the enumerator.</font></td>
|
||
</tr>
|
||
</table>
|
||
|
||
<p><font FACE="Arial" SIZE="2"> </p>
|
||
|
||
<blockquote>
|
||
<i><p>pCtx</p>
|
||
</i><p>Typically NULL. Otherwise, this is a pointer to an <b>IWbemContext</b> object that
|
||
may be used by the provider that is returning the requested instances. The values in the
|
||
context object must be specified in the documentation for the provider in question. See
|
||
Making Calls to CIMOM</font><font FACE="Arial" SIZE="2" COLOR="#800000">_hmm_Making_Calls_to_CIMOM</font><font
|
||
FACE="Arial" SIZE="2"> for more information about this parameter.</p>
|
||
</blockquote>
|
||
|
||
<p><i> </p>
|
||
|
||
<p>pResponseHandler</p>
|
||
|
||
<blockquote>
|
||
</i><p>Points to the caller's implementation of <b>IWbemObjectSink</b></font><font
|
||
FACE="Arial" SIZE="2" COLOR="#800000">_hmm_IWbemObjectSink</font><font FACE="Arial"
|
||
SIZE="2">. This handler receives the objects as they become available. If any error code
|
||
is returned, then the supplied <b>IWbemObjectSink</b> pointer will not be used. If any
|
||
error code is returned, then the supplied <b>IWbemObjectSink</b> pointer will not be used.
|
||
If WBEM_S_NO_ERROR is returned, then the user's <b>IWbemObjectSink</b> implementation will
|
||
be called to indicate the result of the operation. CIMOM only calls <b>AddRef</b> on the
|
||
pointer in cases where WBEM_S_NO_ERROR returns. In cases where an error code returns, the
|
||
reference count is the same as on entry. For a detailed explanation of this parameter, see
|
||
Making an Asynchronous Call</font><font FACE="Arial" SIZE="2" COLOR="#800000">_hmm_making_an_asynchronous_call</font><font
|
||
FACE="Arial" SIZE="2">.</p>
|
||
</font><font FACE="Arial" SIZE="1"><p></font> </p>
|
||
</blockquote>
|
||
|
||
<p><font FACE="Arial Narrow"><b> </p>
|
||
|
||
<p>Return Values</b></font></p>
|
||
|
||
<table CELLSPACING="0" BORDER="0" WIDTH="463">
|
||
<tr>
|
||
<td WIDTH="50%" VALIGN="TOP"><font FACE="Arial" SIZE="2">WBEM_E_FAILED</font></td>
|
||
<td WIDTH="50%" VALIGN="TOP"><font FACE="Arial" SIZE="2">This indicates other unspecified
|
||
errors.</font></td>
|
||
</tr>
|
||
<tr>
|
||
<td WIDTH="50%" VALIGN="TOP"><font FACE="Arial" SIZE="2">WBEM_E_INVALID_PARAMETER</font></td>
|
||
<td WIDTH="50%" VALIGN="TOP"><font FACE="Arial" SIZE="2">An invalid parameter was
|
||
specified.</font></td>
|
||
</tr>
|
||
<tr>
|
||
<td WIDTH="50%" VALIGN="TOP"><font FACE="Arial" SIZE="2">WBEM_E_INVALID_CLASS</font></td>
|
||
<td WIDTH="50%" VALIGN="TOP"><font FACE="Arial" SIZE="2">The specified class does not
|
||
exist or is invalid.</font></td>
|
||
</tr>
|
||
<tr>
|
||
<td WIDTH="50%" VALIGN="TOP"><font FACE="Arial" SIZE="2">WBEM_E_OUT_OF_MEMORY</font></td>
|
||
<td WIDTH="50%" VALIGN="TOP"><font FACE="Arial" SIZE="2">There was not enough memory to
|
||
complete the operation.</font></td>
|
||
</tr>
|
||
<tr>
|
||
<td WIDTH="50%" VALIGN="TOP"><font FACE="Arial" SIZE="2">WBEM_E_TRANSPORT_FAILURE</font></td>
|
||
<td WIDTH="50%" VALIGN="TOP"><font FACE="Arial" SIZE="2">This indicates the failure of the
|
||
remote procedure call (RPC) link between the current process and CIMOM.</font></td>
|
||
</tr>
|
||
<tr>
|
||
<td WIDTH="50%" VALIGN="TOP"><font FACE="Arial" SIZE="2">WBEM_S_NO_ERROR</font></td>
|
||
<td WIDTH="50%" VALIGN="TOP"><font FACE="Arial" SIZE="2">The call succeeded.</font></td>
|
||
</tr>
|
||
</table>
|
||
|
||
<p><font FACE="Arial" SIZE="2"> </p>
|
||
|
||
<p>On failure, you can obtain additional information from the COM function <b>GetErrorInfo</b>.</p>
|
||
|
||
<p>DCOM-specific error codes also may be returned if network problems cause you to lose
|
||
the remote connection to CIMOM.</font><b><font FACE="Arial Narrow"></p>
|
||
|
||
<p>Remarks</font><font FACE="Arial" SIZE="2"></p>
|
||
|
||
<p>IWbemObjectSink::SetStatus</b> is called to indicate the end of the result set. It may
|
||
also be called with no intervening calls to <b>IWbemObjectSink::Indicate</b> if error
|
||
conditions occur. </font><b><font FACE="Arial Narrow"></p>
|
||
|
||
<p><a NAME="here"></a>See Also</font><font FACE="Arial" SIZE="2"></p>
|
||
|
||
<p>IWbemServices::CreateInstanceEnum</font></b><font FACE="Arial" SIZE="2" COLOR="#800000">_hmm_IWbemServices_CreateInstanceEnum</font><font
|
||
FACE="Arial" SIZE="2"> </font><font FACE="Arial Narrow" SIZE="5" COLOR="#800000"></p>
|
||
|
||
<p>‹^</font><font FACE="Arial Narrow" SIZE="5"><b># $ K + </b></font><font
|
||
FACE="Arial Narrow" SIZE="5" COLOR="#800000">›</font><b><font FACE="Arial Narrow"
|
||
SIZE="5">IWbemServices::ExecQuery</font><font FACE="Arial Narrow" SIZE="1" COLOR="#800000"><EFBFBD>@<40></font></b><font
|
||
SIZE="2" COLOR="#ff00ff"></p>
|
||
|
||
<p><span style=color:#FF0000></font><font FACE="Arial" SIZE="2" COLOR="#ff0000">[This
|
||
is preliminary documentation and subject to change.]</font><font SIZE="2" COLOR="#ff00ff"></span></font><font
|
||
FACE="Arial" SIZE="2"> </p>
|
||
|
||
<p>The <b>IWbemServices::ExecQuery</b> method executes a query to retrieve objects. </p>
|
||
|
||
<p>For the valid types of queries that can be performed, see Queries</font><font
|
||
FACE="Arial" SIZE="2" COLOR="#800000">_hmm_wbem_query_language</font><font FACE="Arial"
|
||
SIZE="2">.</font><font FACE="Lucida Sans Typewriter" SIZE="2"><b></p>
|
||
|
||
<p>HRESULT IWbemServices::ExecQuery(</p>
|
||
|
||
<p>[in] BSTR</b><i> strQueryLanguage</i><b>, </p>
|
||
|
||
<p>[in] BSTR</b><i> strQuery</i><b>, </p>
|
||
|
||
<p>[in] LONG</b><i> lFlags</i><b>, </p>
|
||
|
||
<p>[in] IWbemContext</b><i> *pCtx</i><b>, </p>
|
||
|
||
<p>[out] IEnumWbemClassObject</b><i> **ppEnum</i><b> </p>
|
||
|
||
<p>);</b></p>
|
||
|
||
<p></font><font FACE="Arial Narrow"><b> </p>
|
||
|
||
<p>Parameters</b></font><font FACE="Arial" SIZE="2"><i></p>
|
||
|
||
<p>strQueryLanguage</p>
|
||
|
||
<blockquote>
|
||
</i><p>A valid BSTR containing one of the query languages supported by CIMOM. This must be
|
||
the "WQL," the acronym for WBEM Query Language.</p>
|
||
</blockquote>
|
||
|
||
<p><i> </p>
|
||
|
||
<p>strQuery</p>
|
||
|
||
<blockquote>
|
||
</i><p>A valid BSTR containing the text of the query. This parameter cannot be NULL. </p>
|
||
</blockquote>
|
||
|
||
<p><i> </p>
|
||
|
||
<p>lFlags</p>
|
||
|
||
<blockquote>
|
||
</i><p>The following flags affect the behavior of this method. The suggested value for
|
||
this parameter is WBEM_FLAG_RETURN_IMMEDIATELY | WBEM_FLAG_FORWARD_ONLY for best
|
||
performance.</font></p>
|
||
</blockquote>
|
||
|
||
<p ALIGN="LEFT"> </p>
|
||
|
||
<table CELLSPACING="0" BORDER="0" WIDTH="445">
|
||
<tr>
|
||
<td WIDTH="53%" VALIGN="TOP"><font FACE="Arial" SIZE="2"><b>Flag</b></font></td>
|
||
<td WIDTH="47%" VALIGN="TOP"><font FACE="Arial" SIZE="2"><b>Value</b></font></td>
|
||
</tr>
|
||
<tr>
|
||
<td WIDTH="53%" VALIGN="TOP"><font FACE="Arial" SIZE="2">WBEM_FLAG_FORWARD_ONLY</font></td>
|
||
<td WIDTH="47%" VALIGN="TOP"><font FACE="Arial" SIZE="2">This flag causes a forward-only
|
||
enumerator to be returned. Forward-only enumerators are generally much faster and use less
|
||
memory than conventional enumerators but do not allow calls to <b>Clone</b> or <b>Reset</b>.
|
||
</font></td>
|
||
</tr>
|
||
<tr>
|
||
<td WIDTH="53%" VALIGN="TOP"><font FACE="Arial" SIZE="2">WBEM_FLAG_BIDIRECTIONAL</font></td>
|
||
<td WIDTH="47%" VALIGN="TOP"><font FACE="Arial" SIZE="2">This flag causes CIMOM to retain
|
||
pointers to objects of the enumeration until the client releases the enumerator.</font></td>
|
||
</tr>
|
||
<tr>
|
||
<td WIDTH="53%" VALIGN="TOP"><font FACE="Arial" SIZE="2">WBEM_FLAG_RETURN_IMMEDIATELY</font></td>
|
||
<td WIDTH="47%" VALIGN="TOP"><font FACE="Arial" SIZE="2">This flag causes this to be a
|
||
semisycnronous call. See Making a Semisynchronous Call</font><font FACE="Arial" SIZE="2"
|
||
COLOR="#800000">_hmm_making_a_semisynchronous_call</font><font FACE="Arial" SIZE="2"> for
|
||
more information on semisynchronous calls.</font></td>
|
||
</tr>
|
||
<tr>
|
||
<td WIDTH="53%" VALIGN="TOP"><font FACE="Arial" SIZE="2">WBEM_FLAG_ENSURE_LOCATABLE</font><font
|
||
FACE="Arial" SIZE="2" COLOR="#0000ff"> </font></td>
|
||
<td WIDTH="47%" VALIGN="TOP"><font FACE="Arial" SIZE="2">This flag ensures that any
|
||
returned objects have enough information in them so that the system properties such as
|
||
__PATH, __RELPATH, and __SERVER are non-NULL.</font></td>
|
||
</tr>
|
||
</table>
|
||
|
||
<p><font FACE="Arial" SIZE="1"> </p>
|
||
|
||
<p></font><font FACE="Arial" SIZE="2"><i> </p>
|
||
|
||
<p>pCtx</p>
|
||
|
||
<blockquote>
|
||
</i><p>Typically NULL. Otherwise, this is a pointer to an <b>IWbemContext</b> object that
|
||
may be used by the provider that is providing the requested classes or instances. The
|
||
values in the context object must be specified in the documentation for the provider in
|
||
question. See Making Calls to CIMOM</font><font FACE="Arial" SIZE="2" COLOR="#800000">_hmm_Making_Calls_to_CIMOM</font><font
|
||
FACE="Arial" SIZE="2"> for more information about this parameter. </font><font
|
||
FACE="Arial" SIZE="2" COLOR="#008000"><b>‹</b></font><font FACE="Arial" SIZE="2">If
|
||
the query is very broad and involves many instance providers, it is not practical to
|
||
include enough context information for all providers. In these cases, the parameter should
|
||
be NULL.</font><font FACE="Arial" SIZE="2" COLOR="#008000"><b>›</b></font></p>
|
||
</blockquote>
|
||
|
||
<p><font FACE="Arial" SIZE="2"><i> </p>
|
||
|
||
<p>ppEnum</p>
|
||
|
||
<blockquote>
|
||
</i><p>If no error occurs, this receives the enumerator that allows the caller to retrieve
|
||
the instances in the result set of the query. It is not an error for the query to have a
|
||
result set with zero instances. This is determined only by attempting to iterate through
|
||
the instances. This object returns with a positive reference count. The caller must call <b>Release</b>
|
||
when the object is no longer needed.</p>
|
||
</font><font FACE="Arial" SIZE="1"><p></font> </p>
|
||
</blockquote>
|
||
|
||
<p><font FACE="Arial Narrow"><b> </p>
|
||
|
||
<p>Return Values</b></font></p>
|
||
|
||
<table CELLSPACING="0" BORDER="0" WIDTH="463">
|
||
<tr>
|
||
<td WIDTH="50%" VALIGN="TOP"><font FACE="Arial" SIZE="2">WBEM_E_ACCESS_DENIED</font></td>
|
||
<td WIDTH="50%" VALIGN="TOP"><font FACE="Arial" SIZE="2">The current user does not have
|
||
permission to view the result set.</font></td>
|
||
</tr>
|
||
<tr>
|
||
<td WIDTH="50%" VALIGN="TOP"><font FACE="Arial" SIZE="2">WBEM_E_FAILED</font></td>
|
||
<td WIDTH="50%" VALIGN="TOP"><font FACE="Arial" SIZE="2">This indicates other unspecified
|
||
errors.</font></td>
|
||
</tr>
|
||
<tr>
|
||
<td WIDTH="50%" VALIGN="TOP"><font FACE="Arial" SIZE="2">WBEM_E_INVALID_PARAMETER</font></td>
|
||
<td WIDTH="50%" VALIGN="TOP"><font FACE="Arial" SIZE="2">An invalid parameter was
|
||
specified.</font></td>
|
||
</tr>
|
||
<tr>
|
||
<td WIDTH="50%" VALIGN="TOP"><font FACE="Arial" SIZE="2">WBEM_E_INVALID_QUERY</font></td>
|
||
<td WIDTH="50%" VALIGN="TOP"><font FACE="Arial" SIZE="2">The query was not syntactically
|
||
valid.</font></td>
|
||
</tr>
|
||
<tr>
|
||
<td WIDTH="50%" VALIGN="TOP"><font FACE="Arial" SIZE="2">WBEM_E_INVALID_QUERY_LANGUAGE</font></td>
|
||
<td WIDTH="50%" VALIGN="TOP"><font FACE="Arial" SIZE="2">The requested query language is
|
||
not supported.</font></td>
|
||
</tr>
|
||
<tr>
|
||
<td WIDTH="50%" VALIGN="TOP"><font FACE="Arial" SIZE="2">WBEM_E_OUT_OF_MEMORY</font></td>
|
||
<td WIDTH="50%" VALIGN="TOP"><font FACE="Arial" SIZE="2">There was not enough memory to
|
||
complete the operation.</font></td>
|
||
</tr>
|
||
<tr>
|
||
<td WIDTH="50%" VALIGN="TOP"><font FACE="Arial" SIZE="2">WBEM_E_TRANSPORT_FAILURE</font></td>
|
||
<td WIDTH="50%" VALIGN="TOP"><font FACE="Arial" SIZE="2">This indicates the failure of the
|
||
remote procedure call (RPC) link between the current process and CIMOM.</font></td>
|
||
</tr>
|
||
<tr>
|
||
<td WIDTH="50%" VALIGN="TOP"><font FACE="Arial" SIZE="2">WBEM_E_INVALID_CLASS</font></td>
|
||
<td WIDTH="50%" VALIGN="TOP"><font FACE="Arial" SIZE="2">The query specifies a class that
|
||
does not exist.</font></td>
|
||
</tr>
|
||
<tr>
|
||
<td WIDTH="50%" VALIGN="TOP"><font FACE="Arial" SIZE="2">WBEM_S_NO_ERROR</font></td>
|
||
<td WIDTH="50%" VALIGN="TOP"><font FACE="Arial" SIZE="2">The call succeeded.</font></td>
|
||
</tr>
|
||
</table>
|
||
|
||
<p><font FACE="Arial" SIZE="2"> </p>
|
||
|
||
<p>On failure, you can obtain any available information from the COM function <b>GetErrorInfo</b>.</p>
|
||
|
||
<p>DCOM-specific error codes also may be returned if network problems cause you to lose
|
||
the remote connection to CIMOM.</font><b><font FACE="Arial Narrow"></p>
|
||
|
||
<p>Remarks</font><font FACE="Arial" SIZE="2"></p>
|
||
|
||
<p>IWbemServices::ExecQuery</b> processes the query specified in the <i>strQuery</i>
|
||
parameter and creates an enumerator through which the caller can access the query results.
|
||
The enumerator is a pointer to an <b>IEnumWbemClassObject</b></font><font FACE="Arial"
|
||
SIZE="2" COLOR="#800000">_hmm_IEnumWbemClassObject</font><font FACE="Arial" SIZE="2">
|
||
interface; the query results are instances of class objects made available through the <b>IWbemClassObject</b></font><font
|
||
FACE="Arial" SIZE="2" COLOR="#800000">_hmm_IWbemClassObject</font><font FACE="Arial"
|
||
SIZE="2"> interface. </font><b><font FACE="Arial Narrow"></p>
|
||
|
||
<p>See Also</font><font FACE="Arial" SIZE="2"></p>
|
||
|
||
<p>IWbemServices::ExecQueryAsync</font></b><font FACE="Arial" SIZE="2" COLOR="#800000">_hmm_IWbemServices_ExecQueryAsync</font><font
|
||
FACE="Arial" SIZE="2"></p>
|
||
|
||
<p>Data Queries</font><font FACE="Arial" SIZE="2" COLOR="#800000">_hmm_Data_Queries</font><font
|
||
FACE="Arial" SIZE="2"></p>
|
||
|
||
<p>Event Queries</font><font FACE="Arial" SIZE="2" COLOR="#800000">_hmm_Event_Queries</font><font
|
||
FACE="Arial" SIZE="2"></p>
|
||
|
||
<p>Schema Queries</font><font FACE="Arial" SIZE="2" COLOR="#800000">_hmm_Schema_Queries</font><font
|
||
FACE="Arial Narrow" SIZE="5" COLOR="#800000"></p>
|
||
|
||
<p>‹^</font><font FACE="Arial Narrow" SIZE="5"><b># $ K + </b></font><font
|
||
FACE="Arial Narrow" SIZE="5" COLOR="#800000">›</font><b><font FACE="Arial Narrow"
|
||
SIZE="5">IWbemServices::ExecQueryAsync</font><font FACE="Arial Narrow" SIZE="1"
|
||
COLOR="#800000"><EFBFBD>@<40></font></b><font SIZE="2" COLOR="#ff00ff"></p>
|
||
|
||
<p><span style=color:#FF0000></font><font FACE="Arial" SIZE="2" COLOR="#ff0000">[This
|
||
is preliminary documentation and subject to change.]</font><font SIZE="2" COLOR="#ff00ff"></span></font><font
|
||
FACE="Arial" SIZE="2"> </p>
|
||
|
||
<p>The <b>IWbemServices::ExecQueryAsync</b> method The <b>IWbemServices::ExecQuery</b>
|
||
method executes a query to retrieve objects asynchronously. </font><font
|
||
FACE="Lucida Sans Typewriter" SIZE="2"><b></p>
|
||
|
||
<p>HRESULT IWbemServices::ExecQueryAsync(</p>
|
||
|
||
<p>[in] BSTR</b><i> strQueryLanguage</i><b>, </p>
|
||
|
||
<p>[in] BSTR</b><i> strQuery</i><b>, </p>
|
||
|
||
<p>[in] LONG</b><i> lFlags</i><b>, </p>
|
||
|
||
<p>[in] IWbemContext</b><i> *pCtx</i><b>, </p>
|
||
|
||
<p>[in] IWbemObjectSink</b><i> *pResponseHandler</i><b> </p>
|
||
|
||
<p>);</b></p>
|
||
|
||
<p></font><font FACE="Arial Narrow"><b> </p>
|
||
|
||
<p>Parameters</b></font><font FACE="Arial" SIZE="2"><i></p>
|
||
|
||
<p>strQueryLanguage</p>
|
||
|
||
<blockquote>
|
||
</i><p>A valid BSTR containing one of the query languages supported by CIMOM. This must be
|
||
WQL.</p>
|
||
</blockquote>
|
||
|
||
<p><i> </p>
|
||
|
||
<p>strQuery</p>
|
||
|
||
<blockquote>
|
||
</i><p>A valid BSTR containing the text of the query. This cannot be NULL. </p>
|
||
</blockquote>
|
||
|
||
<p><i> </p>
|
||
|
||
<p>lFlags</i></font></p>
|
||
|
||
<p ALIGN="LEFT"> </p>
|
||
|
||
<table CELLSPACING="0" BORDER="0" WIDTH="445">
|
||
<tr>
|
||
<td WIDTH="53%" VALIGN="TOP"><font FACE="Arial" SIZE="2"><b>Flag</b></font></td>
|
||
<td WIDTH="47%" VALIGN="TOP"><font FACE="Arial" SIZE="2"><b>Description</b></font></td>
|
||
</tr>
|
||
<tr>
|
||
<td WIDTH="53%" VALIGN="TOP"><font FACE="Arial" SIZE="2">WBEM_FLAG_BIDIRECTIONAL</font></td>
|
||
<td WIDTH="47%" VALIGN="TOP"><font FACE="Arial" SIZE="2">This flag causes CIMOM to retain
|
||
pointers to objects of the enumeration until the client releases the enumerator.</font></td>
|
||
</tr>
|
||
<tr>
|
||
<td WIDTH="53%" VALIGN="TOP"><font FACE="Arial" SIZE="2">WBEM_FLAG_FORWARD_ONLY</font></td>
|
||
<td WIDTH="47%" VALIGN="TOP"><font FACE="Arial" SIZE="2">This flag causes a forward-only
|
||
enumerator to be returned. Forward-only enumerators are generally much faster and use less
|
||
memory than conventional enumerators.</font></td>
|
||
</tr>
|
||
<tr>
|
||
<td WIDTH="53%" VALIGN="TOP"><font FACE="Arial" SIZE="2">WBEM_FLAG_SEND_STATUS</font></td>
|
||
<td WIDTH="47%" VALIGN="TOP"><font FACE="Arial" SIZE="2">This flag registers with CIMOM a
|
||
request to receive intermediate status reports through the clients implementation of <b>IWbemObjectSink::SetStatus</b></font><font
|
||
FACE="Arial" SIZE="2" COLOR="#800000">_hmm_IWbemObjectSink_SetStatus</font><font
|
||
FACE="Arial" SIZE="2">.</font></td>
|
||
</tr>
|
||
<tr>
|
||
<td WIDTH="53%" VALIGN="TOP"><font FACE="Arial" SIZE="2">WBEM_FLAG_ENSURE_LOCATABLE</font><font
|
||
FACE="Arial" SIZE="2" COLOR="#0000ff"> </font></td>
|
||
<td WIDTH="47%" VALIGN="TOP"><font FACE="Arial" SIZE="2">This flag ensures that any
|
||
returned objects have enough information in them so that the system properties such as
|
||
__PATH, __RELPATH, and __SERVER are non-NULL.</font></td>
|
||
</tr>
|
||
</table>
|
||
|
||
<p><font FACE="Arial" SIZE="2"> </p>
|
||
|
||
<p> </p>
|
||
|
||
<p><i> </p>
|
||
|
||
<p>pCtx</p>
|
||
|
||
<blockquote>
|
||
</i><p>Typically NULL. Otherwise, this is a pointer to an <b>IWbemContext</b> object that
|
||
may be used by the provider that is returning the requested classes or instances. The
|
||
values in the context object must be specified in the documentation for the provider in
|
||
question. See Making Calls to CIMOM</font><font FACE="Arial" SIZE="2" COLOR="#800000">_hmm_Making_Calls_to_CIMOM</font><font
|
||
FACE="Arial" SIZE="2"> for more information about this parameter.</font><font FACE="Arial"
|
||
SIZE="2" COLOR="#008000"><b>‹</b></font><font FACE="Arial" SIZE="2">If the query is
|
||
very broad and involves many instance providers, it is not practical to include enough
|
||
context information for all providers. In these cases, set the parameter to NULL.</font><font
|
||
FACE="Arial" SIZE="2" COLOR="#008000"><b>›</b></font></p>
|
||
</blockquote>
|
||
|
||
<p><font FACE="Arial" SIZE="2"><i> </p>
|
||
|
||
<p>pResponseHandler</p>
|
||
|
||
<blockquote>
|
||
</i><p>Points to the caller's implementation of <b>IWbemObjectSink</b></font><font
|
||
FACE="Arial" SIZE="2" COLOR="#800000">_hmm_IWbemObjectSink</font><font FACE="Arial"
|
||
SIZE="2">. This handler receives the objects in the query result set as they become
|
||
available. If any error code is returned, then the supplied <b>IWbemObjectSink</b> pointer
|
||
will not be used. If WBEM_S_NO_ERROR is returned, then the user's <b>IWbemObjectSink</b>
|
||
implementation will be called to indicate the result of the operation. CIMOM calls <b>IWbemObjectSink::Indicate</b></font><font
|
||
FACE="Arial" SIZE="2" COLOR="#800000">_hmm_IWbemObjectSink_Indicate</font><font
|
||
FACE="Arial" SIZE="2"> with the objects any number of times, followed by a single call to <b>IWbemObjectSink::SetStatus</b><i>
|
||
</i>to indicate the final status.</p>
|
||
<p>CIMOM only calls <b>AddRef</b> to the pointer in cases where WBEM_S_NO_ERROR returns.
|
||
In cases where an error code returns, the reference count is the same as on entry. For a
|
||
detailed explanation of call methods asynchronously, see Making an Asynchronous Call</font><font
|
||
FACE="Arial" SIZE="2" COLOR="#800000">_hmm_making_an_asynchronous_call</font><font
|
||
FACE="Arial" SIZE="2">.</p>
|
||
</font><font FACE="Arial" SIZE="1"><p></font> </p>
|
||
</blockquote>
|
||
|
||
<p><font FACE="Arial Narrow"><b> </p>
|
||
|
||
<p>Return Values</b></font></p>
|
||
|
||
<table CELLSPACING="0" BORDER="0" WIDTH="463">
|
||
<tr>
|
||
<td WIDTH="53%" VALIGN="TOP"><font FACE="Arial" SIZE="2">WBEM_E_FAILED</font></td>
|
||
<td WIDTH="47%" VALIGN="TOP"><font FACE="Arial" SIZE="2">This indicates other unspecified
|
||
errors.</font></td>
|
||
</tr>
|
||
<tr>
|
||
<td WIDTH="53%" VALIGN="TOP"><font FACE="Arial" SIZE="2">WBEM_E_INVALID_CLASS</font></td>
|
||
<td WIDTH="47%" VALIGN="TOP"><font FACE="Arial" SIZE="2">The query specifies a class that
|
||
does not exist.</font></td>
|
||
</tr>
|
||
<tr>
|
||
<td WIDTH="53%" VALIGN="TOP"><font FACE="Arial" SIZE="2">WBEM_E_INVALID_PARAMETER</font></td>
|
||
<td WIDTH="47%" VALIGN="TOP"><font FACE="Arial" SIZE="2">An invalid parameter was
|
||
specified.</font></td>
|
||
</tr>
|
||
<tr>
|
||
<td WIDTH="53%" VALIGN="TOP"><font FACE="Arial" SIZE="2">WBEM_E_OUT_OF_MEMORY</font></td>
|
||
<td WIDTH="47%" VALIGN="TOP"><font FACE="Arial" SIZE="2">There was not enough memory to
|
||
complete the operation.</font></td>
|
||
</tr>
|
||
<tr>
|
||
<td WIDTH="53%" VALIGN="TOP"><font FACE="Arial" SIZE="2">WBEM_E_TRANSPORT_FAILURE</font></td>
|
||
<td WIDTH="47%" VALIGN="TOP"><font FACE="Arial" SIZE="2">This indicates the failure of the
|
||
remote procedure call (RPC) link between the current process and CIMOM.</font></td>
|
||
</tr>
|
||
<tr>
|
||
<td WIDTH="53%" VALIGN="TOP"><font FACE="Arial" SIZE="2">WBEM_S_NO_ERROR</font></td>
|
||
<td WIDTH="47%" VALIGN="TOP"><font FACE="Arial" SIZE="2">The call succeeded.</font></td>
|
||
</tr>
|
||
</table>
|
||
|
||
<p><font FACE="Arial" SIZE="2"> </p>
|
||
|
||
<p>On failure, you can obtain any available information from the COM function <b>GetErrorInfo</b>.</p>
|
||
|
||
<p>Other error codes are returned to the object sink specified by the <i>pResponseHandler</i>
|
||
parameter.</p>
|
||
|
||
<p>DCOM-specific error codes also may be returned if network problems cause you to lose
|
||
the remote connection to CIMOM.</font><font FACE="Arial Narrow"><b></p>
|
||
|
||
<p>Remarks</b></font><font FACE="Arial" SIZE="2"></p>
|
||
|
||
<p>The caller's <b>IWbemObjectSink::Indicate </b>method may be called to report
|
||
intermittant status.<b> IWbemObjectSink::SetStatus</b> is called to indicate the end of
|
||
the result set. </font><font FACE="Arial Narrow"><b></p>
|
||
|
||
<p>See Also</b></font><font FACE="Arial" SIZE="2"></p>
|
||
|
||
<p>Making an Asynchronous Call</font><font FACE="Arial" SIZE="2" COLOR="#800000">_hmm_Making_an_Asynchronous_Call</font><font
|
||
FACE="Arial" SIZE="2">, <b>IWbemServices::ExecQuery</b></font><font FACE="Arial" SIZE="2"
|
||
COLOR="#800000">_hmm_IWbemServices_ExecQuery</font><font FACE="Arial" SIZE="2">, Queries</font><font
|
||
FACE="Arial" SIZE="2" COLOR="#800000">_hmm_wbem_query_language</font><font
|
||
FACE="Arial Narrow" SIZE="5" COLOR="#800000"></p>
|
||
|
||
<p>‹^</font><font FACE="Arial Narrow" SIZE="5"><b># $ K + </b></font><font
|
||
FACE="Arial Narrow" SIZE="5" COLOR="#800000">›</font><b><font FACE="Arial Narrow"
|
||
SIZE="5">IWbemServices::ExecNotificationQuery</font><font FACE="Arial Narrow" SIZE="1"
|
||
COLOR="#800000"><EFBFBD>@<40></font></b><font SIZE="2" COLOR="#ff00ff"></p>
|
||
|
||
<p><span style=color:#FF0000></font><font FACE="Arial" SIZE="2" COLOR="#ff0000">[This
|
||
is preliminary documentation and subject to change.]</font><font SIZE="2" COLOR="#ff00ff"></span></font><font
|
||
FACE="Arial" SIZE="2"> </p>
|
||
|
||
<p>The <b>IWbemServices::ExecNotificationQuery</b> method executes a query to receive
|
||
events. The call returns immediately, and the user can poll the returned enumerator for
|
||
events as they arrive. Releasing the returned enumerator cancels the query.</font><font
|
||
FACE="Lucida Sans Typewriter" SIZE="2"><b></p>
|
||
|
||
<p>HRESULT IWbemServices::ExecNotificationQuery(</p>
|
||
|
||
<p>[in] BSTR</b><i> strQueryLanguage</i><b>, </p>
|
||
|
||
<p>[in] BSTR</b><i> strQuery</i><b>, </p>
|
||
|
||
<p>[in] LONG</b><i> lFlags</i><b>, </p>
|
||
|
||
<p>[in] IWbemContext</b><i> *pCtx</i><b>, </p>
|
||
|
||
<p>[out] IEnumWbemClassObject</b><i> **ppEnum </i><b></p>
|
||
|
||
<p>);</b></p>
|
||
|
||
<p></font><font FACE="Arial Narrow"><b> </p>
|
||
|
||
<p>Parameters</b></font><font FACE="Arial" SIZE="2"><i></p>
|
||
|
||
<p>strQueryLanguage</p>
|
||
|
||
<blockquote>
|
||
</i><p>A valid BSTR containing one of the query languages supported by CIMOM. This cannot
|
||
be NULL. Currently, only the <b>WBEM Query Language (WQL)</b></font><font FACE="Arial"
|
||
SIZE="2" COLOR="#800000">_hmm_WBEM_Query_Language</font><font FACE="Arial" SIZE="2"> is
|
||
supported<b>.</b></p>
|
||
</blockquote>
|
||
|
||
<p><i> </p>
|
||
|
||
<p>strQuery</p>
|
||
|
||
<blockquote>
|
||
</i><p>A valid BSTR containing the text of the event-related query. This cannot be NULL.</p>
|
||
</blockquote>
|
||
|
||
<p><i> </p>
|
||
|
||
<p>lFlags</p>
|
||
|
||
<blockquote>
|
||
</i><p>The following flags affect the behavior of this method. The suggested value for
|
||
this parameter is WBEM_FLAG_RETURN_IMMEDIATELY | WBEM_FLAG_FORWARD_ONLY for best
|
||
performance.</font></p>
|
||
</blockquote>
|
||
|
||
<p ALIGN="LEFT"> </p>
|
||
|
||
<table CELLSPACING="0" BORDER="0" WIDTH="445">
|
||
<tr>
|
||
<td WIDTH="53%" VALIGN="TOP"><font FACE="Arial" SIZE="2"><b>Flag</b></font></td>
|
||
<td WIDTH="47%" VALIGN="TOP"><font FACE="Arial" SIZE="2"><b>Description</b></font></td>
|
||
</tr>
|
||
<tr>
|
||
<td WIDTH="53%" VALIGN="TOP"><font FACE="Arial" SIZE="2">WBEM_FLAG_FORWARD_ONLY</font></td>
|
||
<td WIDTH="47%" VALIGN="TOP"><font FACE="Arial" SIZE="2">This flag causes a forward-only
|
||
enumerator to be returned. Forward-only enumerators are generally much faster and use less
|
||
memory than conventional enumerators but do not allow calls to <b>Clone</b> or <b>Reset</b>.
|
||
</font></td>
|
||
</tr>
|
||
<tr>
|
||
<td WIDTH="53%" VALIGN="TOP"><font FACE="Arial" SIZE="2">WBEM_FLAG_RETURN_IMMEDIATELY </font></td>
|
||
<td WIDTH="47%" VALIGN="TOP"><font FACE="Arial" SIZE="2">The user must specify this flag
|
||
or the call will fail.This is because events are received continuously, which means the
|
||
user must poll the returned enumerator. Blocking this call indefinitely while waiting for
|
||
a possible event would block the thread for an indefinite amount of time. See Making a
|
||
Semisynchronous Call</font><font FACE="Arial" SIZE="2" COLOR="#800000">_hmm_making_a_semisynchronous_call</font><font
|
||
FACE="Arial" SIZE="2"> for more information on semisynchronous calls.</font></td>
|
||
</tr>
|
||
</table>
|
||
|
||
<p><font FACE="Arial" SIZE="2"> </p>
|
||
|
||
<p> </p>
|
||
|
||
<p><i> </p>
|
||
|
||
<p>pCtx</p>
|
||
|
||
<blockquote>
|
||
</i><p>Typically NULL. Otherwise, this is a pointer to an <b>IWbemContext</b> object that
|
||
may be used by the provider that is providing the requested events. The values in the
|
||
context object must be specified in the documentation for the provider in question. See
|
||
Making Calls to CIMOM</font><font FACE="Arial" SIZE="2" COLOR="#800000">_hmm_Making_Calls_to_CIMOM</font><font
|
||
FACE="Arial" SIZE="2"> for more information about this parameter.</p>
|
||
</blockquote>
|
||
|
||
<p><i> </p>
|
||
|
||
<p>ppEnum</p>
|
||
|
||
<blockquote>
|
||
</i><p>If no error occurs, this receives the enumerator that allows the caller to retrieve
|
||
the instances in the result set of the query. The caller periodically calls <b>IEnumWbemClassObject::Next</b></font><font
|
||
FACE="Arial" SIZE="2" COLOR="#800000">_hmm_IEnumWbemClassObject_Next</font><font
|
||
FACE="Arial" SIZE="2"> to see if any events are available. Notice that in this usage, <b>Reset</b></font><font
|
||
FACE="Arial" SIZE="2" COLOR="#800000">_hmm_IEnumWbemClassObject_Reset</font><font
|
||
FACE="Arial" SIZE="2"> does not move the enumerator back to the beginning of the event
|
||
sequence; it has no effect. The parameter can continue to receive events until <b>Release</b><i>
|
||
</i>is called on the returned enumerator.</p>
|
||
</font><font FACE="Arial" SIZE="1"><p></font> </p>
|
||
</blockquote>
|
||
|
||
<p><font FACE="Arial Narrow"><b> </p>
|
||
|
||
<p>Return Values</b></font></p>
|
||
|
||
<table CELLSPACING="0" BORDER="0" WIDTH="463">
|
||
<tr>
|
||
<td WIDTH="59%" VALIGN="TOP"><font FACE="Arial" SIZE="2">WBEM_E_ACCESS_DENIED</font></td>
|
||
<td WIDTH="41%" VALIGN="TOP"><font FACE="Arial" SIZE="2">The current user is not
|
||
authorized to view the result set.</font></td>
|
||
</tr>
|
||
<tr>
|
||
<td WIDTH="59%" VALIGN="TOP"><font FACE="Arial" SIZE="2">WBEM_E_FAILED</font></td>
|
||
<td WIDTH="41%" VALIGN="TOP"><font FACE="Arial" SIZE="2">This indicates other unspecified
|
||
errors.</font></td>
|
||
</tr>
|
||
<tr>
|
||
<td WIDTH="59%" VALIGN="TOP"><font FACE="Arial" SIZE="2">WBEM_E_INVALID_CLASS</font></td>
|
||
<td WIDTH="41%" VALIGN="TOP"><font FACE="Arial" SIZE="2">The query specifies a class that
|
||
does not exist.</font></td>
|
||
</tr>
|
||
<tr>
|
||
<td WIDTH="59%" VALIGN="TOP"><font FACE="Arial" SIZE="2">WBEM_E_INVALID_PARAMETER</font></td>
|
||
<td WIDTH="41%" VALIGN="TOP"><font FACE="Arial" SIZE="2">An invalid parameter was
|
||
specified.</font></td>
|
||
</tr>
|
||
<tr>
|
||
<td WIDTH="59%" VALIGN="TOP"><font FACE="Arial" SIZE="2">WBEM_E_INVALID_QUERY</font></td>
|
||
<td WIDTH="41%" VALIGN="TOP"><font FACE="Arial" SIZE="2">The query was not syntactically
|
||
valid.</font></td>
|
||
</tr>
|
||
<tr>
|
||
<td WIDTH="59%" VALIGN="TOP"><font FACE="Arial" SIZE="2">WBEM_E_INVALID_QUERY_LANGUAGE</font></td>
|
||
<td WIDTH="41%" VALIGN="TOP"><font FACE="Arial" SIZE="2">The requested query language is
|
||
not supported.</font></td>
|
||
</tr>
|
||
<tr>
|
||
<td WIDTH="59%" VALIGN="TOP"><font FACE="Arial" SIZE="2">WBEM_E_OUT_OF_MEMORY</font></td>
|
||
<td WIDTH="41%" VALIGN="TOP"><font FACE="Arial" SIZE="2">There was not enough memory to
|
||
complete the operation.</font></td>
|
||
</tr>
|
||
<tr>
|
||
<td WIDTH="59%" VALIGN="TOP"><font FACE="Arial" SIZE="2">WBEM_E_TRANSPORT_FAILURE</font></td>
|
||
<td WIDTH="41%" VALIGN="TOP"><font FACE="Arial" SIZE="2">This indicates the failure of the
|
||
remote procedure call (RPC) link between the current process and CIMOM.</font></td>
|
||
</tr>
|
||
<tr>
|
||
<td WIDTH="59%" VALIGN="TOP"><font FACE="Arial" SIZE="2">WBEM_S_NO_ERROR</font></td>
|
||
<td WIDTH="41%" VALIGN="TOP"><font FACE="Arial" SIZE="2">The call succeeded.</font></td>
|
||
</tr>
|
||
</table>
|
||
|
||
<p><font FACE="Arial" SIZE="2"> </p>
|
||
|
||
<p>On failure, you can obtain any available information from the COM function <b>GetErrorInfo</b>.</p>
|
||
|
||
<p>DCOM-specific error codes also may be returned if network problems cause you to lose
|
||
the remote connection to CIMOM.</font><font FACE="Arial Narrow"><b></p>
|
||
|
||
<p>See Also</b></font><font FACE="Arial" SIZE="2"></p>
|
||
|
||
<p>Temporary Event Consumers</font><font FACE="Arial" SIZE="2" COLOR="#800000">_hmm_Temporary_Event_Consumers</font><font
|
||
FACE="Arial" SIZE="2">, Error Handling for Applications</font><font FACE="Arial" SIZE="2"
|
||
COLOR="#800000">_hmm_Error_Handling_for_Applications</font><font FACE="Arial" SIZE="2">, <b>IWbemServices::ExecNotificationQueryAsync</b></font><font
|
||
FACE="Arial" SIZE="2" COLOR="#800000">_hmm_IWbemServices_ExecNotificationQueryAsync</font><font
|
||
FACE="Arial" SIZE="2">, Queries</font><font FACE="Arial" SIZE="2" COLOR="#800000">_hmm_wbem_query_language</font><font
|
||
FACE="Arial Narrow" SIZE="5" COLOR="#800000"></p>
|
||
|
||
<p>‹^</font><font FACE="Arial Narrow" SIZE="5"><b># $ K + </b></font><font
|
||
FACE="Arial Narrow" SIZE="5" COLOR="#800000">›</font><b><font FACE="Arial Narrow"
|
||
SIZE="5">IWbemServices::ExecNotificationQueryAsync</font><font FACE="Arial Narrow"
|
||
SIZE="1" COLOR="#800000"><EFBFBD>@<40></font></b><font SIZE="2" COLOR="#ff00ff"></p>
|
||
|
||
<p><span style=color:#FF0000></font><font FACE="Arial" SIZE="2" COLOR="#ff0000">[This
|
||
is preliminary documentation and subject to change.]</font><font SIZE="2" COLOR="#ff00ff"></span></font><font
|
||
FACE="Arial" SIZE="2"> </p>
|
||
|
||
<p>The <b>IWbemServices::ExecNotificationQueryAsync</b> method performs the same task as <b>IWbemServices::ExecNotificationQuery</b></font><font
|
||
FACE="Arial" SIZE="2" COLOR="#800000">_hmm_IWbemServices_ExecNotificationQuery</font><font
|
||
FACE="Arial" SIZE="2"> except that events are supplied to the specified response handler
|
||
until <b>CancelAsyncCall</b></font><font FACE="Arial" SIZE="2" COLOR="#800000">_hmm_IWbemServices_CancelAsyncCall</font><font
|
||
FACE="Arial" SIZE="2"> is called to stop the event notification.</font><font
|
||
FACE="Lucida Sans Typewriter" SIZE="2"><b></p>
|
||
|
||
<p>HRESULT IWbemServices::ExecNotificationQueryAsync(</p>
|
||
|
||
<p>[in] BSTR</b><i> strQueryLanguage</i><b>, </p>
|
||
|
||
<p>[in] BSTR</b><i> strQuery</i><b>, </p>
|
||
|
||
<p>[in] LONG</b><i> lFlags</i><b>, </p>
|
||
|
||
<p>[in] IWbemContext</b><i> *pCtx</i><b>, </p>
|
||
|
||
<p>[in] IWbemObjectSink</b><i> *pResponseHandler</i><b> </p>
|
||
|
||
<p>);</b></p>
|
||
|
||
<p></font><font FACE="Arial Narrow"><b> </p>
|
||
|
||
<p>Parameters</b></font><font FACE="Arial" SIZE="2"><i></p>
|
||
|
||
<p>strQueryLanguage</p>
|
||
|
||
<blockquote>
|
||
</i><p>A valid BSTR containing one of the query languages supported by CIMOM. This must be
|
||
WQL.</p>
|
||
</blockquote>
|
||
|
||
<p><i> </p>
|
||
|
||
<p>strQuery</p>
|
||
|
||
<blockquote>
|
||
</i><p>A valid BSTR containing the text of the event-related query. This cannot be NULL. </p>
|
||
</blockquote>
|
||
|
||
<p><i> </p>
|
||
|
||
<p>lFlags</i></font></p>
|
||
|
||
<p ALIGN="LEFT"> </p>
|
||
|
||
<table CELLSPACING="0" BORDER="0" WIDTH="445">
|
||
<tr>
|
||
<td WIDTH="53%" VALIGN="TOP"><font FACE="Arial" SIZE="2">Flag</font></td>
|
||
<td WIDTH="47%" VALIGN="TOP"><font FACE="Arial" SIZE="2"><b>Description</b></font></td>
|
||
</tr>
|
||
<tr>
|
||
<td WIDTH="53%" VALIGN="TOP"><font FACE="Arial" SIZE="2">WBEM_FLAG_SEND_STATUS</font></td>
|
||
<td WIDTH="47%" VALIGN="TOP"><font FACE="Arial" SIZE="2">This flag registers with CIMOM a
|
||
request to receive intermediate status reports through the clients implementation of <b>IWbemObjectSink::SetStatus</b></font><font
|
||
FACE="Arial" SIZE="2" COLOR="#800000">_hmm_IWbemObjectSink_SetStatus</font><font
|
||
FACE="Arial" SIZE="2">..</font></td>
|
||
</tr>
|
||
</table>
|
||
|
||
<p><font FACE="Arial" SIZE="2"><i> </p>
|
||
|
||
<p>pCtx</p>
|
||
|
||
<blockquote>
|
||
</i><p>Typically NULL. Otherwise, this is a pointer to an <b>IWbemContext</b> object that
|
||
may be used by the provider that is returning the requested events. The values in the
|
||
context object must be specified in the documentation for the provider in question. See
|
||
Making Calls to CIMOM</font><font FACE="Arial" SIZE="2" COLOR="#800000">_hmm_Making_Calls_to_CIMOM</font><font
|
||
FACE="Arial" SIZE="2"> for more information about this parameter.</p>
|
||
</blockquote>
|
||
|
||
<p><i> </p>
|
||
|
||
<p>pResponseHandler</p>
|
||
|
||
<blockquote>
|
||
</i><p>Points to a the caller's implementation of <b>IWbemObjectSink</b></font><font
|
||
FACE="Arial" SIZE="2" COLOR="#800000">_hmm_IWbemObjectSink</font><font FACE="Arial"
|
||
SIZE="2">. This handler receives the objects in the query result set as they become
|
||
available. To cease receiving events, the caller must call <b>IWbemServices::CancelAsyncCall</b></font><font
|
||
FACE="Arial" SIZE="2" COLOR="#800000">_hmm_IWbemServices_CancelAsyncCall</font><font
|
||
FACE="Arial" SIZE="2"> using the same pointer value for <i>pResponseHandler. </i>As events
|
||
become available, the supplied <b>IWbemObjectSink::Indicate</b> implementation is called
|
||
to deliver the event objects. <b>IWbemObjectSink::SetStatus</b> is not called at any time,
|
||
since there is no final or terminating condition. The call executes indefinitely until
|
||
canceled. If any error code is returned, then the supplied <b>IWbemObjectSink</b> pointer
|
||
will not be used. If WBEM_S_NO_ERROR is returned, then the user's <b>IWbemObjectSink</b>
|
||
implementation will be called to indicate the result of the operation. CIMOM only calls <b>AddRef</b>
|
||
on the pointer in cases where WBEM_S_NO_ERROR returns. In cases where an error code
|
||
returns, the reference count is the same as on entry. For a detailed explanation of this
|
||
parameter, see Making an Asynchronous Call</font><font FACE="Arial" SIZE="2"
|
||
COLOR="#800000">_hmm_Making_an_Asynchronous_Call</font><font FACE="Arial" SIZE="2">.</p>
|
||
</font><font FACE="Arial" SIZE="1"><p></font> </p>
|
||
</blockquote>
|
||
|
||
<p><font FACE="Arial Narrow"><b> </p>
|
||
|
||
<p>Return Values</b></font></p>
|
||
|
||
<table CELLSPACING="0" BORDER="0" WIDTH="463">
|
||
<tr>
|
||
<td WIDTH="53%" VALIGN="TOP"><font FACE="Arial" SIZE="2">WBEM_E_FAILED</font></td>
|
||
<td WIDTH="47%" VALIGN="TOP"><font FACE="Arial" SIZE="2">This indicates other unspecified
|
||
errors.</font></td>
|
||
</tr>
|
||
<tr>
|
||
<td WIDTH="53%" VALIGN="TOP"><font FACE="Arial" SIZE="2">WBEM_E_INVALID_CLASS</font></td>
|
||
<td WIDTH="47%" VALIGN="TOP"><font FACE="Arial" SIZE="2">The query specifies a class that
|
||
does not exist.</font></td>
|
||
</tr>
|
||
<tr>
|
||
<td WIDTH="53%" VALIGN="TOP"><font FACE="Arial" SIZE="2">WBEM_E_INVALID_PARAMETER</font></td>
|
||
<td WIDTH="47%" VALIGN="TOP"><font FACE="Arial" SIZE="2">An invalid parameter was
|
||
specified.</font></td>
|
||
</tr>
|
||
<tr>
|
||
<td WIDTH="53%" VALIGN="TOP"><font FACE="Arial" SIZE="2">WBEM_E_OUT_OF_MEMORY</font></td>
|
||
<td WIDTH="47%" VALIGN="TOP"><font FACE="Arial" SIZE="2">There was not enough memory to
|
||
complete the operation.</font></td>
|
||
</tr>
|
||
<tr>
|
||
<td WIDTH="53%" VALIGN="TOP"><font FACE="Arial" SIZE="2">WBEM_E_TRANSPORT_FAILURE</font></td>
|
||
<td WIDTH="47%" VALIGN="TOP"><font FACE="Arial" SIZE="2">This indicates the failure of the
|
||
remote procedure call (RPC) link between the current process and CIMOM.</font></td>
|
||
</tr>
|
||
<tr>
|
||
<td WIDTH="53%" VALIGN="TOP"><font FACE="Arial" SIZE="2">WBEM_S_NO_ERROR</font></td>
|
||
<td WIDTH="47%" VALIGN="TOP"><font FACE="Arial" SIZE="2">The call succeeded.</font></td>
|
||
</tr>
|
||
</table>
|
||
|
||
<p><font FACE="Arial" SIZE="2"> </p>
|
||
|
||
<p>On failure, you can obtain any available information from the COM function <b>GetErrorInfo</b>.</p>
|
||
|
||
<p>Other error codes are returned to the object sink specified by the <i>pResponseHandler</i>
|
||
parameter.</p>
|
||
|
||
<p>DCOM-specific error codes also may be returned if network problems cause you to lose
|
||
the remote connection to CIMOM.</font><font FACE="Arial Narrow"><b></p>
|
||
|
||
<p>See Also</b></font><font FACE="Arial" SIZE="2"></p>
|
||
|
||
<p>Temporary Event Consumers</font><font FACE="Arial" SIZE="2" COLOR="#800000">_hmm_Temporary_Event_Consumers</font><font
|
||
FACE="Arial" SIZE="2"></p>
|
||
|
||
<p>Making an Asynchronous Call</font><font FACE="Arial" SIZE="2" COLOR="#800000">_hmm_Making_an_Asynchronous_Call</font><font
|
||
FACE="Arial" SIZE="2"></p>
|
||
|
||
<p>Event Queries</font><font FACE="Arial" SIZE="2" COLOR="#800000">_hmm_Event_Queries</font><font
|
||
FACE="Arial" SIZE="2"><b></p>
|
||
|
||
<p>IWbemServices::ExecQuery</b></font><font FACE="Arial" SIZE="2" COLOR="#800000">_hmm_IWbemServices_ExecQuery</font><font
|
||
FACE="Arial Narrow" SIZE="5" COLOR="#800000"></p>
|
||
|
||
<p>‹^</font><font FACE="Arial Narrow" SIZE="5"><b># $ K + </b></font><font
|
||
FACE="Arial Narrow" SIZE="5" COLOR="#800000">›</font><b><font FACE="Arial Narrow"
|
||
SIZE="5">IWbemServices::ExecMethod</font><font FACE="Arial Narrow" SIZE="1"
|
||
COLOR="#800000"><EFBFBD>@<40></font></b><font SIZE="2" COLOR="#ff00ff"></p>
|
||
|
||
<p><span style=color:#FF0000></font><font FACE="Arial" SIZE="2" COLOR="#ff0000">[This
|
||
is preliminary documentation and subject to change.]</font><font SIZE="2" COLOR="#ff00ff"></span></font><font
|
||
FACE="Arial" SIZE="2"> </p>
|
||
|
||
<p>The <b>IWbemServices::ExecMethod</b> method executes a method exported by a CIM object.
|
||
The method call is forwarded to the appropriate provider where it executes. Information
|
||
and status are returned to the caller, which blocks until the call is complete.</p>
|
||
|
||
<p>Methods are not directly implemented by CIMOM, but are exported by method providers.
|
||
For any given CIM class, the available methods and their parameters must be specified in
|
||
the documentation for the provider in question.</p>
|
||
|
||
<p>See Calling a Method</font><font FACE="Arial" SIZE="2" COLOR="#800000">_hmm_Calling_a_Method</font><font
|
||
FACE="Arial" SIZE="2"> for additional information about executing methods.</font><font
|
||
FACE="Lucida Sans Typewriter" SIZE="2"><b></p>
|
||
|
||
<p>HRESULT IWbemServices::ExecMethod(</p>
|
||
|
||
<p>[in] BSTR</b><i> strObjectPath</i><b>, </p>
|
||
|
||
<p>[in] BSTR </b><i>MethodName</i><b>,</p>
|
||
|
||
<p>[in] LONG</b><i> lFlags</i><b>, </p>
|
||
|
||
<p>[in] IWbemContext</b><i> *pCtx</i>,<b> </p>
|
||
|
||
<p>[in] IWbemClassObject </b><i>*pInParams</i><b>,</p>
|
||
|
||
<p>[out, OPTIONAL] IWbemClassObject </b><i>**ppOutParams</i><b>,</b><i></p>
|
||
|
||
<p></i><b>[out, OPTIONAL] IWbemCallResult </b><i>**ppCallResult</i><b></p>
|
||
|
||
<p>);</p>
|
||
|
||
<p></font><font FACE="Arial Narrow"> </p>
|
||
|
||
<p>Parameters</font></b><font FACE="Arial" SIZE="2"><i></p>
|
||
|
||
<p>strObjectPath</p>
|
||
|
||
<blockquote>
|
||
</i><p>A valid BSTR containing the object path</font><font FACE="Arial" SIZE="2"
|
||
COLOR="#800000">_hmm_Object_Paths</font><font FACE="Arial" SIZE="2"> of the object for
|
||
which the method is executed.</p>
|
||
</blockquote>
|
||
|
||
<p><i> </p>
|
||
|
||
<p>MethodName</p>
|
||
|
||
<blockquote>
|
||
</i><p>The name of the method for the object.</p>
|
||
</blockquote>
|
||
|
||
<p><i> </p>
|
||
|
||
<p>lFlags</p>
|
||
|
||
<blockquote>
|
||
</i><p>This parameter can be set to zero to make this a synchronous call. Otherwise, to
|
||
make this a semisynchronous call set <i>lFlags</i> to WBEM_FLAG_RETURN_IMMEDIATELY,
|
||
provide a valid pointer for the <i>ppCallResult</i> parameter and this call will return
|
||
immediately. See Making a Semisynchronous Call</font><font FACE="Arial" SIZE="2"
|
||
COLOR="#800000">_hmm_Making_a_Semisynchronous_Call</font><font FACE="Arial" SIZE="2"> for
|
||
more information on semisynchronous calls.</p>
|
||
</blockquote>
|
||
|
||
<p><i> </p>
|
||
|
||
<p>pCtx</p>
|
||
|
||
<blockquote>
|
||
</i><p>Typically NULL. Otherwise, this is a pointer to an <b>IWbemContext</b> object that
|
||
may be used by the provider that is executing the method. The values in the context object
|
||
must be specified in the documentation for the provider in question. See Making Calls to
|
||
CIMOM</font><font FACE="Arial" SIZE="2" COLOR="#800000">_hmm_Making_Calls_to_CIMOM</font><font
|
||
FACE="Arial" SIZE="2"> for more information about this parameter.</p>
|
||
</blockquote>
|
||
|
||
<p><i> </p>
|
||
|
||
<p>pInParams</p>
|
||
|
||
<blockquote>
|
||
</i><p>May be NULL if no inbound parameters are required to execute the method. Otherwise,
|
||
this points to an <b>IWbemClassObject</b> that contains the properties acting as inbound
|
||
parameters for the method execution. The contents of the object are method-specific, and
|
||
are part of the specification for the provider in question.</p>
|
||
</blockquote>
|
||
|
||
<p><i> </p>
|
||
|
||
<p>ppOutParams</p>
|
||
|
||
<blockquote>
|
||
</i><p>If not NULL, receives a pointer to the outbound parameters and return values for
|
||
the method execution. The contents of this object are method-specific, and are part of the
|
||
specification for the provider in question. The caller must call <b>Release</b> on the
|
||
returned object when it is no longer required.</p>
|
||
</blockquote>
|
||
|
||
<p><i> </p>
|
||
|
||
<p>ppCallResult</p>
|
||
|
||
<blockquote>
|
||
</i><p>If NULL, this is not used. If <i>ppCallResult</i> is specified it must be set to
|
||
point to NULL on entry. In this case, the call returns immediately with WBEM_S_NO_ERROR. <i>ppCallResult
|
||
</i>receives a pointer to a new <b>IWbemCallResult</b></font><font FACE="Arial" SIZE="2"
|
||
COLOR="#800000">_hmm_IWbemCallResult</font><font FACE="Arial" SIZE="2"> object, which must
|
||
be polled to obtain the result of the method execution using the <b>GetCallStatus</b>
|
||
method. The out-parameters for the call are available by calling <b>IWbemCallResult::GetResultObject</b></font><font
|
||
FACE="Arial" SIZE="2" COLOR="#800000">_hmm_IWbemCallResult_GetResultObject</font><font
|
||
FACE="Arial" SIZE="2"> </p>
|
||
</font><font FACE="Arial" SIZE="1"><p></font> </p>
|
||
</blockquote>
|
||
|
||
<p><font FACE="Arial Narrow"><b> </p>
|
||
|
||
<p>Return Values</b></font></p>
|
||
|
||
<table CELLSPACING="0" BORDER="0" WIDTH="464">
|
||
<tr>
|
||
<td WIDTH="66%" VALIGN="TOP"><font FACE="Arial" SIZE="2">WBEM_E_FAILED</font></td>
|
||
<td WIDTH="34%" VALIGN="TOP"><font FACE="Arial" SIZE="2">This indicates other unspecified
|
||
errors.</font></td>
|
||
</tr>
|
||
<tr>
|
||
<td WIDTH="66%" VALIGN="TOP"><font FACE="Arial" SIZE="2">WBEM_E_INVALID_CLASS</font></td>
|
||
<td WIDTH="34%" VALIGN="TOP"><font FACE="Arial" SIZE="2">The specified class was invalid.</font></td>
|
||
</tr>
|
||
<tr>
|
||
<td WIDTH="66%" VALIGN="TOP"><font FACE="Arial" SIZE="2">WBEM_E_INVALID_PARAMETER</font></td>
|
||
<td WIDTH="34%" VALIGN="TOP"><font FACE="Arial" SIZE="2">An invalid parameter was
|
||
specified.</font></td>
|
||
</tr>
|
||
<tr>
|
||
<td WIDTH="66%" VALIGN="TOP"><font FACE="Arial" SIZE="2">WBEM_E_PROVIDER_NOT_CAPABLE</font></td>
|
||
<td WIDTH="34%" VALIGN="TOP"><font FACE="Arial" SIZE="2">The provider does not support
|
||
method calls.</font></td>
|
||
</tr>
|
||
<tr>
|
||
<td WIDTH="66%" VALIGN="TOP"><font FACE="Arial" SIZE="2">WBEM_E_OUT_OF_MEMORY</font></td>
|
||
<td WIDTH="34%" VALIGN="TOP"><font FACE="Arial" SIZE="2">There was not enough memory to
|
||
complete the operation.</font></td>
|
||
</tr>
|
||
<tr>
|
||
<td WIDTH="66%" VALIGN="TOP"><font FACE="Arial" SIZE="2">WBEM_E_TRANSPORT_FAILURE</font></td>
|
||
<td WIDTH="34%" VALIGN="TOP"><font FACE="Arial" SIZE="2">This indicates the failure of the
|
||
remote procedure call (RPC) link between the current process and CIMOM.</font></td>
|
||
</tr>
|
||
<tr>
|
||
<td WIDTH="66%" VALIGN="TOP"><font FACE="Arial" SIZE="2">WBEM_E_INVALID_METHOD</font></td>
|
||
<td WIDTH="34%" VALIGN="TOP"><font FACE="Arial" SIZE="2">The requested method was not
|
||
available.</font></td>
|
||
</tr>
|
||
<tr>
|
||
<td WIDTH="66%" VALIGN="TOP"><font FACE="Arial" SIZE="2">WBEM_E_ACCESS_DENIED</font></td>
|
||
<td WIDTH="34%" VALIGN="TOP"><font FACE="Arial" SIZE="2">The current user was not
|
||
authorized to execute the method.</font></td>
|
||
</tr>
|
||
<tr>
|
||
<td WIDTH="66%" VALIGN="TOP"><font FACE="Arial" SIZE="2">WBEM_E_INVALID_METHOD_PARAMETERS</font></td>
|
||
<td WIDTH="34%" VALIGN="TOP"><font FACE="Arial" SIZE="2">The supplied <i>pInParams </i>object
|
||
was determined by the provider to be invalid.</font></td>
|
||
</tr>
|
||
<tr>
|
||
<td WIDTH="66%" VALIGN="TOP"><font FACE="Arial" SIZE="2">WBEM_S_NO_ERROR</font></td>
|
||
<td WIDTH="34%" VALIGN="TOP"><font FACE="Arial" SIZE="2">The call succeeded.</font></td>
|
||
</tr>
|
||
</table>
|
||
|
||
<p><font FACE="Arial" SIZE="2"> </p>
|
||
|
||
<p>On failure, you can obtain any available information from the COM function <b>GetErrorInfo</b>.</p>
|
||
|
||
<p>DCOM-specific error codes also may be returned if network problems cause you to lose
|
||
the remote connection to CIMOM.</font><font FACE="Arial Narrow"><b></p>
|
||
|
||
<p>See Also</b></font><font FACE="Arial" SIZE="2"></p>
|
||
|
||
<p>Calling a Method</font><font FACE="Arial" SIZE="2" COLOR="#800000">_hmm_Calling_a_Method</font><font
|
||
FACE="Arial" SIZE="2">, <b>IWbemServices::ExecMethodAsync</b></font><font FACE="Arial"
|
||
SIZE="2" COLOR="#800000">_hmm_IWbemServices_ExecMethodAsync</font><font FACE="Arial"
|
||
SIZE="2">, <b>IWbemCallResult::GetResultObject</b></font><font FACE="Arial" SIZE="2"
|
||
COLOR="#800000">_hmm_IWbemCallResult_GetResultObject</font><font FACE="Arial Narrow"
|
||
SIZE="5" COLOR="#800000"></p>
|
||
|
||
<hr>
|
||
|
||
<p>‹^</font><font FACE="Arial Narrow" SIZE="5"><b># $ K + </b></font><font
|
||
FACE="Arial Narrow" SIZE="5" COLOR="#800000">›</font><b><font FACE="Arial Narrow"
|
||
SIZE="5">IWbemServices::ExecMethodAsync</font><font FACE="Arial Narrow" SIZE="1"
|
||
COLOR="#800000"><EFBFBD>@<40></font></b><font SIZE="2" COLOR="#ff00ff"></p>
|
||
|
||
<p><span style=color:#FF0000></font><font FACE="Arial" SIZE="2" COLOR="#ff0000">[This
|
||
is preliminary documentation and subject to change.]</font><font SIZE="2" COLOR="#ff00ff"></span></font><font
|
||
FACE="Arial" SIZE="2"> </p>
|
||
|
||
<p>The <b>IWbemServices::ExecMethodAsync</b> method asynchronously executes a method
|
||
exported by a CIM object. The call immediately returns to the client while the inbound
|
||
parameters are forwarded to the appropriate provider where it executes. Information and
|
||
status are returned to the caller through the supplied object sink.</p>
|
||
|
||
<p>Methods are not directly implemented by CIMOM, but are exported by method providers.
|
||
For any given CIM class, the available methods and their parameters are part of the
|
||
documentation for the provider in question.</font><font FACE="Lucida Sans Typewriter"
|
||
SIZE="2"><b></p>
|
||
|
||
<p>HRESULT IWbemServices::ExecMethodAsync(</p>
|
||
|
||
<p>[in] BSTR</b><i> strObjectPath</i><b>, </p>
|
||
|
||
<p>[in] BSTR </b><i>strMethodName</i><b>,</p>
|
||
|
||
<p>[in] LONG</b><i> lFlags</i><b>, </p>
|
||
|
||
<p>[in] IWbemContext</b><i> *pCtx</i><b>, </b></p>
|
||
|
||
<p><b> </p>
|
||
|
||
<p>[in] IWbemClassObject</b> <i>*pInParams</i>,</p>
|
||
|
||
<p><i> </p>
|
||
|
||
<p></i><b>[in] IWbemObjectSink</b> <i>*pResponseHandler</i><b></p>
|
||
|
||
<p>);</p>
|
||
|
||
<p></font><font FACE="Arial Narrow"> </p>
|
||
|
||
<p>Parameters</font></b><font FACE="Arial" SIZE="2"><i></p>
|
||
|
||
<p>strObjectPath</p>
|
||
|
||
<blockquote>
|
||
</i><p>A valid BSTR containing the object path</font><font FACE="Arial" SIZE="2"
|
||
COLOR="#800000">_hmm_Object_Paths</font><font FACE="Arial" SIZE="2"> of the object for
|
||
which the method is to be executed.</p>
|
||
</blockquote>
|
||
|
||
<p><i> </p>
|
||
|
||
<p>strMethodName</p>
|
||
|
||
<blockquote>
|
||
</i><p>The name of the method for the object.</p>
|
||
</blockquote>
|
||
|
||
<p><i> </p>
|
||
|
||
<p>lFlags</p>
|
||
|
||
<blockquote>
|
||
</i><p>WBEM_FLAG_SEND_STATUS registers with CIMOM a request to receive intermediate status
|
||
reports through the clients implementation of <b>IWbemObjectSink::SetStatus</b>.</p>
|
||
</blockquote>
|
||
|
||
<p><i> </p>
|
||
|
||
<p>pCtx</p>
|
||
|
||
<blockquote>
|
||
</i><p>Typically NULL. Otherwise, this is a pointer to an <b>IWbemContext</b> object that
|
||
may be used by the provider that is executing the method. The values in the context object
|
||
must be specified in the documentation for the provider in question. See Making Calls to
|
||
CIMOM</font><font FACE="Arial" SIZE="2" COLOR="#800000">_hmm_Making_Calls_to_CIMOM</font><font
|
||
FACE="Arial" SIZE="2"> for more information about this parameter.</p>
|
||
</blockquote>
|
||
|
||
<p><i> </p>
|
||
|
||
<p>pInParams</p>
|
||
|
||
<blockquote>
|
||
</i><p>Can be NULL if no inbound parameters are required to execute the method. Otherwise,
|
||
this points to an <b>IWbemClassObject</b> that contains the properties acting as inbound
|
||
parameters for the method execution. The contents of the object are method-specific, and
|
||
are part of the specification for the provider in question.</p>
|
||
</blockquote>
|
||
|
||
<p><i> </p>
|
||
|
||
<p>pResponseHandler</p>
|
||
|
||
<blockquote>
|
||
</i><p>Must not be NULL. The object sink receives the result of the method call. The
|
||
outbound parameters are sent to <b>IWbemObjectSink::Indicate</b></font><font FACE="Arial"
|
||
SIZE="2" COLOR="#800000">_hmm_IWbemObjectSink_Indicate</font><font FACE="Arial" SIZE="2">.The
|
||
result of the call mechanism itself will be sent to <b>IWbemObjectSink::SetStatus</b></font><font
|
||
FACE="Arial" SIZE="2" COLOR="#800000">_hmm_IWbemObjectSink_SetStatus</font><font
|
||
FACE="Arial" SIZE="2">. Notice that <b>IWbemObjectSink::SetStatus</b> does not receive the
|
||
return code of the CIM method. However, it receives the return code of the actual
|
||
call-return mechanism, and is only useful for verifying that the call occurred or that it
|
||
failed for mechanical reasons. The result code returned from the CIM method is returned in
|
||
the outbound parameter object supplied to <b>IWbemObjectSink::Indicate. </b>If any error
|
||
code is returned, then the supplied IWbemObjectSink pointer will not be used. If
|
||
WBEM_S_NO_ERROR is returned, then the user's IWbemObjectSink implementation will be called
|
||
to indicate the result of the operation.</p>
|
||
</font><font FACE="Arial" SIZE="1"><p></font> </p>
|
||
</blockquote>
|
||
|
||
<p><font FACE="Arial Narrow"><b> </p>
|
||
|
||
<p>Return Values</b></font></p>
|
||
|
||
<table CELLSPACING="0" BORDER="0" WIDTH="464">
|
||
<tr>
|
||
<td WIDTH="52%" VALIGN="TOP"><font FACE="Arial" SIZE="2">WBEM_E_FAILED</font></td>
|
||
<td WIDTH="48%" VALIGN="TOP"><font FACE="Arial" SIZE="2">This indicates other unspecified
|
||
errors.</font></td>
|
||
</tr>
|
||
<tr>
|
||
<td WIDTH="52%" VALIGN="TOP"><font FACE="Arial" SIZE="2">WBEM_E_INVALID_PARAMETER</font></td>
|
||
<td WIDTH="48%" VALIGN="TOP"><font FACE="Arial" SIZE="2">An invalid parameter was
|
||
specified.</font></td>
|
||
</tr>
|
||
<tr>
|
||
<td WIDTH="52%" VALIGN="TOP"><font FACE="Arial" SIZE="2">WBEM_E_OUT_OF_MEMORY</font></td>
|
||
<td WIDTH="48%" VALIGN="TOP"><font FACE="Arial" SIZE="2">There was not enough memory to
|
||
complete the operation.</font></td>
|
||
</tr>
|
||
<tr>
|
||
<td WIDTH="52%" VALIGN="TOP"><font FACE="Arial" SIZE="2">WBEM_E_TRANSPORT_FAILURE</font></td>
|
||
<td WIDTH="48%" VALIGN="TOP"><font FACE="Arial" SIZE="2">This indicates the failure of the
|
||
remote procedure call (RPC) link between the current process and CIMOM.</font></td>
|
||
</tr>
|
||
<tr>
|
||
<td WIDTH="52%" VALIGN="TOP"><font FACE="Arial" SIZE="2">WBEM_E_ACCESS_DENIED</font></td>
|
||
<td WIDTH="48%" VALIGN="TOP"><font FACE="Arial" SIZE="2">The current user was not
|
||
authorized to execute the method.</font></td>
|
||
</tr>
|
||
<tr>
|
||
<td WIDTH="52%" VALIGN="TOP"><font FACE="Arial" SIZE="2">WBEM_S_NO_ERROR</font></td>
|
||
<td WIDTH="48%" VALIGN="TOP"><font FACE="Arial" SIZE="2">The call succeeded.</font></td>
|
||
</tr>
|
||
</table>
|
||
|
||
<p><font FACE="Arial" SIZE="2"> </p>
|
||
|
||
<p>On failure, you can obtain any available information from the COM function <b>GetErrorInfo</b>.</p>
|
||
|
||
<p>Other errors will be reported asynchronously to the object sink supplied in the <i>pReponseHandler
|
||
</i>parameter</p>
|
||
|
||
<p>DCOM-specific error codes also may be returned if network problems cause you to lose
|
||
the remote connection to CIMOM.</font><font FACE="Arial Narrow"><b></p>
|
||
|
||
<p>See Also</b></font><font FACE="Arial" SIZE="2"></p>
|
||
|
||
<p>Making an Asynchronous Call</font><font FACE="Arial" SIZE="2" COLOR="#800000">_hmm_Making_an_Asynchronous_Call</font><font
|
||
FACE="Arial" SIZE="2">, <b>IWbemServices::ExecMethod</b></font><font FACE="Arial" SIZE="2"
|
||
COLOR="#800000">_hmm_IWbemServices_ExecMethod</font></p>
|
||
</body>
|
||
</html>
|