WindowsXP/admin/wmi/wbem/winmgmt/specs/html/interface_iwbemobjectinternals.htm
2025-04-27 07:49:33 -04:00

718 lines
31 KiB
HTML

<html>
<head>
<title>Interface IWbemObjectInternals</title>
<meta name="GENERATOR" content="Microsoft FrontPage 3.0">
</head>
<body bgcolor="#FFFFC1">
<font FACE="Arial Narrow" SIZE="6" COLOR="#800000">
<p></font><font face="Arial Narrow" size="6"><b>Interface IWbemObjectInternals</b></font><font
SIZE="2" COLOR="#ff00ff"></p>
</font><font FACE="Arial" SIZE="2">
<p>The <strong>IWbemObjectInternals</strong> interface is intended to allow direct access
to and manipulation of binary data underlying an instance of<strong> IWbemClassObject</strong>.
&nbsp; For instance, if you have a series of<strong> IWbemClassObjects</strong> that are
all instances of the same class, in order to limit consumption of memory, you can use <strong>IWbemObjectInternals::MergeClassPart</strong>
to cause all objects to use a shared piece of data for the class part information, since
this piece of data cannot be modified for instances.</p>
</font>
<p><font FACE="Arial" SIZE="2">This interface is derived from <strong>IUnknown </strong>and
supports its methods.</font></p>
<table CELLSPACING="0" BORDER="0" WIDTH="597">
<tr>
<td VALIGN="TOP" COLSPAN="2" width="549"></td>
</tr>
<tr>
<td WIDTH="232" VALIGN="TOP"><font FACE="Arial" SIZE="2"><b>IWbemCallResult Methods</b></font></td>
<td WIDTH="361" VALIGN="TOP"><font FACE="Arial" SIZE="2"><b>Description</b></font></td>
</tr>
<tr>
<td WIDTH="232" VALIGN="TOP"><a href="#QueryObjectInfo"><font face="Arial" size="2"
color="#008000"><u><strong>QueryObjectInfo</strong></u></font></a></td>
<td WIDTH="361" VALIGN="TOP"><font face="Arial" size="2" color="#008000">Returns a bitmask
containing information regarding availability of various pieces of data in the object..</font></td>
</tr>
<tr>
<td WIDTH="232" VALIGN="TOP"><a href="#SetObjectMemory"><font face="Arial" size="2"
color="#008000"><strong><u>SetObjectMemory</u></strong></font></a></td>
<td WIDTH="361" VALIGN="TOP"><font face="Arial" size="2" color="#008000">Sets the object's
binary data to the supplied buffer.</font></td>
</tr>
<tr>
<td WIDTH="232" VALIGN="TOP"><a href="#GetObjectMemory"><font face="Arial" size="2"
color="#008000"><strong><u>GetObjectMemory</u></strong></font></a></td>
<td WIDTH="361" VALIGN="TOP"><font face="Arial" size="2" color="#008000">Returns the
object's underlying binary data in the supplied buffer.</font></td>
</tr>
<tr>
<td WIDTH="232" VALIGN="TOP"><a href="#IsObjectInstance"><font face="Arial" size="2"
color="#008000"><strong><u>IsObjectInstance</u></strong></font></a></td>
<td WIDTH="361" VALIGN="TOP"><font face="Arial" size="2" color="#008000">Returns whether
or not the object's underlying binary data describes an instance or a class.</font></td>
</tr>
<tr>
<td WIDTH="232" VALIGN="TOP"><a href="#SetObjectParts"><font face="Arial" size="2"
color="#008000"><strong><u>SetObjectParts</u></strong></font></a></td>
<td WIDTH="361" VALIGN="TOP"><font face="Arial" size="2" color="#008000">Sets the
specified portions of the object's binary data to the data in the supplied buffer.</font></td>
</tr>
<tr>
<td WIDTH="232" VALIGN="TOP"><a href="#GetObjectParts"><font face="Arial" size="2"
color="#008000"><strong><u>GetObjectParts</u></strong></font></a></td>
<td WIDTH="361" VALIGN="TOP"><font face="Arial" size="2" color="#008000">Gets the
specified portions of the object's binary data and copies the data into the supplied
buffer</font></td>
</tr>
<tr>
<td WIDTH="232" VALIGN="TOP"><a href="#StripClassPart"><font face="Arial" size="2"
color="#008000"><strong><u>StripClassPart</u></strong></font></a></td>
<td WIDTH="361" VALIGN="TOP"><font face="Arial" size="2" color="#008000">Removes the class
part of an Instance object.</font></td>
</tr>
<tr>
<td WIDTH="232" VALIGN="TOP"><a href="#SetClassPart"><font face="Arial" size="2"
color="#008000"><u><b>SetClassPart</b></u></font></a></td>
<td WIDTH="361" VALIGN="TOP"><font face="Arial" size="2" color="#008000">Sets the class
part of an Instance object to the data pointed to by the supplied buffer.</font></td>
</tr>
<tr>
<td WIDTH="232" VALIGN="TOP"><a href="#MergeClassPart"><font face="Arial" size="2"
color="#008000"><u><b>MergeClassPart</b></u></font></a></td>
<td WIDTH="361" VALIGN="TOP"><font face="Arial" size="2" color="#008000">Merges the
current Instance with the class part of the supplied<strong> IWbemClassObject</strong>.
&nbsp; <strong>IWbemClassObject::AddRef()</strong> is called on the supplied object.</font></td>
</tr>
</table>
<p>&nbsp;</p>
<hr>
<font FACE="Arial Narrow" SIZE="5" COLOR="#800000">
<p></font><a name="QueryObjectInfo"></a><font face="Arial Narrow" size="5"><b>IWbemObjectInternals::QueryObjectInfo</b></font><font
SIZE="2" COLOR="#ff00ff"></p>
</font>
<p><font FACE="Arial" SIZE="2">The <b>IWbemObjectInternals::QueryObjectInfo</b> method
returns a bitmap that describes the actual data underlying an <strong>IWbemClassObject</strong>.
&nbsp; At this time, for Class Objects, this function will not return any data.</font></p>
<b><font FACE="Lucida Sans Typewriter" SIZE="2">
<p></font><font FACE="Lucida Sans Typewriter" SIZE="2" color="#008000">HRESULT
QueryObjectInfo(<br>
&nbsp;&nbsp;&nbsp; [out] DWORD* pdwInfo,<br>
&nbsp;&nbsp; );</font><font FACE="Lucida Sans Typewriter" SIZE="2"></p>
</font><font FACE="Arial Narrow">
<p>Parameters</font></b><font FACE="Arial" SIZE="2"><i></p>
<p>pdwInfo<br>
</i>Provides storage for the returned flags..</p>
</font><font FACE="Arial Narrow"><b>
<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_S_NO_ERROR</font></td>
<td WIDTH="47%" VALIGN="TOP"><font FACE="Arial" SIZE="2">The object successfully returned
.</font></td>
</tr>
</table>
<font FACE="Arial" SIZE="2">
<p><strong>Notes</strong></p>
<p>Note that for class objects, although the call will succeed, at this time, the flags
will not contain any useful information. </p>
</font>
<p><font FACE="Arial" SIZE="2">The flags that can be returned in <em>pdwInfo</em> are as
follows:</font></p>
<table CELLSPACING="0" BORDER="0" WIDTH="463">
<tr>
<td WIDTH="53%" VALIGN="TOP"><font FACE="Arial" SIZE="2">WBEM_OBJ_DECORATION_PART</font></td>
<td WIDTH="47%" VALIGN="TOP"><font FACE="Arial" SIZE="2">The decoration part is available.</font></td>
</tr>
<tr>
<td WIDTH="53%" VALIGN="TOP"><font FACE="Arial" SIZE="2">WBEM_OBJ_INSTANCE_PART</font></td>
<td WIDTH="47%" VALIGN="TOP"><font FACE="Arial" SIZE="2">The instance part is available.</font></td>
</tr>
<tr>
<td WIDTH="53%" VALIGN="TOP"><font FACE="Arial" SIZE="2">WBEM_OBJ_CLASS_PART</font></td>
<td WIDTH="47%" VALIGN="TOP"><font FACE="Arial" SIZE="2">The class part is available.</font></td>
</tr>
<tr>
<td WIDTH="53%" VALIGN="TOP"><font FACE="Arial" SIZE="2">WBEM_OBJ_CLASS_PART_INTERNAL</font></td>
<td WIDTH="47%" VALIGN="TOP"><font FACE="Arial" SIZE="2">The class part is contained
internally by the object.</font></td>
</tr>
<tr>
<td WIDTH="53%" VALIGN="TOP"><font FACE="Arial" SIZE="2">WBEM_OBJ_CLASS_PART_SHARED</font></td>
<td WIDTH="47%" VALIGN="TOP"><font FACE="Arial" SIZE="2">The class part information is
held outside of the object and is shared with another object.</font></td>
</tr>
</table>
<p><font FACE="Arial" SIZE="2">The first three flags indicate whether or not specific
parts are available from the object.&nbsp; The last two flags pertain to the class part
and indicate whether or not the part is contained internally, or points to a shared piece
of data.</font>&nbsp; <font FACE="Arial" SIZE="2">Please note that the behavior of
instance objects that do not have all three parts available, is undefined.</font></p>
<p><br>
<font FACE="Arial Narrow"><b>See Also</b></font></p>
<b><font FACE="Arial" SIZE="2"><u>
<p></u></font><font size="2" color="#000000">IWbemServices::IsObjectInstance<br>
IWbemServices::SetObjectParts<br>
IWbemServices::GetObjectParts<br>
IWbemServices::MergeClassPart</font></b></p>
<hr>
<p><a name="SetObjectMemory"></a><font face="Arial Narrow" size="5" color="#000000"><b>IWbemObjectInternals::SetObjectMemory</b></font></p>
<font FACE="Arial" SIZE="2">
<p>The <b>IWbemObjectInternals::S</b><strong>etObjectMemory</strong> method sets the
underlying data of an <strong>IWbemClassObject</strong> to point to a supplied buffer.</font><b><font
FACE="Arial Narrow"></p>
</font><font FACE="Lucida Sans Typewriter" SIZE="2">
<p></font><font FACE="Lucida Sans Typewriter" SIZE="2" color="#008000">HRESULT
SetObjectMemory(<br>
&nbsp;&nbsp;&nbsp; [in] LPVOID <i>pMem</i>,</font><br>
<font FACE="Lucida Sans Typewriter" SIZE="2" color="#008000">&nbsp;&nbsp;&nbsp; [in] DWORD
<i>dwMemSize</i></font><br>
<font FACE="Lucida Sans Typewriter" SIZE="2" color="#008000">&nbsp;&nbsp; );</font><font
FACE="Lucida Sans Typewriter" SIZE="2"></p>
</font><font FACE="Arial Narrow">
<p>Parameters</font></b><font FACE="Arial" SIZE="2"><i></p>
<p>pMem<br>
</i>Specifies the underlying buffer for use by the <strong>IWbemClassObject</strong>.</p>
<i>
<p>dwMemSize<br>
</i>Specifies the size of the buffer <em>pMem</em> points to.</p>
</font><font FACE="Arial Narrow"><b>
<p>Return Values</b></font></p>
<table CELLSPACING="0" BORDER="0" WIDTH="622">
<tr>
<td WIDTH="244" VALIGN="TOP"><font FACE="Arial" SIZE="2">WBEM_S_NO_ERROR</font></td>
<td WIDTH="374" VALIGN="TOP"><font FACE="Arial" SIZE="2">The object path was retrieved.</font></td>
</tr>
<tr>
<td WIDTH="244" VALIGN="TOP"><font FACE="Arial" SIZE="2">WBEM_E_INVALID_PARAMETER</font></td>
<td WIDTH="374" VALIGN="TOP"><font FACE="Arial" SIZE="2">An invalid parameter was
specified.</font></td>
</tr>
</table>
<font FACE="Arial" SIZE="2">
<p>Note that the object memory is what defines an <strong>IWbemClassObject</strong>.
&nbsp; The memory must contain information understood by the <strong>IWbemClassObject</strong>
code or the behavior of the object will be undefined.</font><b><font FACE="Arial Narrow"></p>
<p>See Also</font><u><font FACE="Arial" SIZE="2"></p>
</font></u></b>
<p><font color="#000000" size="2"><b>IWbemServices::GetObjectMemory<br>
IWbemServices::SetObjectParts<br>
IWbemServices::GetObjectParts<br>
</b></font></p>
<hr>
<p><a name="GetObjectMemory"></a><b><font face="Arial Narrow" size="5" color="#000000">IWbemObjectInternals</font><font
face="Arial Narrow" size="5">::GetObjectMemory</font></b><font SIZE="2" COLOR="#ff00ff"></p>
</font><font FACE="Arial" SIZE="2">
<p>You can use the <b>IWbemObjectInternals::GetObjectMemory</b> method to retrieve a copy
of the block of memory underlying an <strong>IWbemClassObject</strong>.</font><b><font
FACE="Lucida Sans Typewriter" SIZE="2"></p>
<p></font><font FACE="Lucida Sans Typewriter" SIZE="2" color="#008000">HRESULT
GetObjectMemory(<br>
&nbsp;&nbsp;&nbsp; [out] LPVOID <i>pDestination</i>,<br>
&nbsp;&nbsp;&nbsp; [in] DWORD <i>dwDestBuffSize</i>,<br>
&nbsp;&nbsp;&nbsp; [out] DWORD* <i>pdwUsed</i><br>
&nbsp;&nbsp; );</font><font FACE="Lucida Sans Typewriter" SIZE="2"></p>
</font><font FACE="Arial Narrow">
<p>Parameters</font></b><font FACE="Arial" SIZE="2"><i></p>
<p>pDestination<br>
</i>Buffer to copy data into.</p>
<i>
<p>dwDestBuffSize<br>
</i>Size of the destination buffer.</p>
<i>
<p>pdwUsed<br>
</i>Number of bytes used in the destination buffer.</p>
</font><font FACE="Arial Narrow"><b>
<p>Return Values</b></font></p>
<table CELLSPACING="0" BORDER="0" WIDTH="576">
<tr>
<td WIDTH="246" VALIGN="TOP"><font FACE="Arial" SIZE="2">WBEM_S_NO_ERROR</font></td>
<td WIDTH="326" VALIGN="TOP"><font FACE="Arial" SIZE="2">The call succeeded and returned
an <b>IWbemServices</b><i> </i>pointer.</font></td>
</tr>
<tr>
<td WIDTH="246" VALIGN="TOP"><font FACE="Arial" SIZE="2">WBEM_E_BUFFER_TOO_SMALL</font></td>
<td WIDTH="326" VALIGN="TOP"><font FACE="Arial" SIZE="2">The supplied buffer was too small
to copy data into.</font></td>
</tr>
<tr>
<td WIDTH="246" VALIGN="TOP"><font FACE="Arial" SIZE="2">WBEM_E_INVALID_PARAMETER</font></td>
<td WIDTH="326" VALIGN="TOP"><font FACE="Arial" SIZE="2">An invalid parameter was
specified.</font></td>
</tr>
</table>
<font FACE="Arial" SIZE="2">
<p>To get the size of the buffer required to copy the data into, pass a NULL for <em>pDestination</em>
and a 0 for <em>dwDestBuffSize</em>.&nbsp; <em>pdwUsed</em> will be filled with the size
of the internal buffer.&nbsp; The function will return WBEM_E_BUFFER_TOO_SMALL.&nbsp; Note
that whenever WBEM_E_BUFFER_TOO_SMALL is returned, <em>pdwUsed</em> will contain the size
of the internal buffer.</font><b><font FACE="Arial Narrow"></p>
<p>See Also</font><u><font FACE="Arial" SIZE="2"></p>
</font></u></b>
<p><font color="#000000" size="2"><b>IWbemServices::SetObjectMemory<br>
IWbemServices::SetObjectParts<br>
IWbemServices::GetObjectParts<br>
</b></font></p>
<font FACE="Arial Narrow" SIZE="5" COLOR="#800000">
<hr>
</font>
<p><a name="IsObjectInstance"></a><b><font face="Arial Narrow" size="5" color="#000000">IWbemObjectInternals</font><font
face="Arial Narrow" size="5">::IsObjectInstance</font></b></p>
<font face="Arial" size="2">
<p>You can use the <b>IWbemObjectInternals::IsObjectInstance</b> method to quickly
determine if an <strong>IWbemClassObject</strong> is an instance or a class.</font><b><font
FACE="Lucida Sans Typewriter" SIZE="2"></p>
<p></font><font FACE="Lucida Sans Typewriter" SIZE="2" color="#008000">HRESULT
IsObjectInstance(<br>
&nbsp;&nbsp;&nbsp; void<br>
&nbsp;&nbsp; );</font><font FACE="Lucida Sans Typewriter" SIZE="2"></p>
</font><font FACE="Arial Narrow">
<p>Parameters</font></b><i><font FACE="Arial" SIZE="2"></p>
</font></i>
<p><font FACE="Arial" SIZE="2">None.</font></p>
<font FACE="Arial Narrow"><b>
<p>Return Values</b></font></p>
<table CELLSPACING="0" BORDER="0" WIDTH="576">
<tr>
<td WIDTH="246" VALIGN="TOP"><font FACE="Arial" SIZE="2">WBEM_S_NO_ERROR</font></td>
<td WIDTH="326" VALIGN="TOP"><font FACE="Arial" SIZE="2">The object is an instance.</font></td>
</tr>
<tr>
<td WIDTH="246" VALIGN="TOP"><font face="Arial" size="2">WBEM_S_FALSE</font></td>
<td WIDTH="326" VALIGN="TOP"><font FACE="Arial" SIZE="2">The object is not an instance..</font></td>
</tr>
</table>
<font FACE="Arial" SIZE="2">
<p>This function directly accesses the Decoration Part of an <strong>IWbemClassObject</strong>
to quickly determine if the object is an Instance or not.</font><b><font
FACE="Arial Narrow"></p>
<p>See Also</font><u><font FACE="Arial" SIZE="2"></p>
</font></u></b>
<p><font size="2" color="#000000"><b>IWbemServices::QueryObjectInfo<br>
</b></font></p>
<hr>
</font>
<p><a name="SetObjectParts"></a><b><font face="Arial Narrow" size="5" color="#000000">IWbemObjectInternals</font><font
face="Arial Narrow" size="5">::SetObjectParts</font></b><font SIZE="2" COLOR="#ff00ff"></p>
</font><font face="Arial" size="2">
<p>You can use the <b>IWbemObjectInternals::SetObjectParts</b> method to quickly set the
underlying memory for an <strong>IWbemClassObject</strong> to point to partial or full
object data.</font><b><font FACE="Lucida Sans Typewriter" SIZE="2"></p>
<p></font><font FACE="Lucida Sans Typewriter" SIZE="2" color="#008000">HRESULT
SetObjectParts(<br>
&nbsp;&nbsp;&nbsp; [in] LPVOID <i>pMem</i>,<br>
&nbsp;&nbsp;&nbsp; [in] DWORD <i>dwMemSize</i>,<br>
&nbsp;&nbsp;&nbsp; [in] DWORD <i>dwParts</i>,<br>
&nbsp;&nbsp; );</font><font FACE="Lucida Sans Typewriter" SIZE="2"></p>
</font><font FACE="Arial Narrow">
<p>Parameters</font></b><font FACE="Arial" SIZE="2"><i></p>
<p>pMem<br>
</i>Buffer to copy data from.</p>
<i>
<p>dwMemSize<br>
</i>Size of the buffer pointed to by pMem.</p>
<i>
<p>dwParts<br>
</i>Bitmask of flags describing the data pointed to by <em>pMem</em> .</p>
</font><font FACE="Arial Narrow"><b>
<p>Return Values</b></font></p>
<table CELLSPACING="0" BORDER="0" WIDTH="576">
<tr>
<td WIDTH="246" VALIGN="TOP"><font FACE="Arial" SIZE="2">WBEM_S_NO_ERROR</font></td>
<td WIDTH="326" VALIGN="TOP"><font face="Arial" size="2">The call succeeded and reset the
memory underlying the object.</font></td>
</tr>
<tr>
<td WIDTH="246" VALIGN="TOP"><font face="Arial" size="2">WBEM_E_INVALID_OPERATION</font></td>
<td WIDTH="326" VALIGN="TOP"><font FACE="Arial" SIZE="2">An invalid operation was
specified.</font></td>
</tr>
<tr>
<td WIDTH="246" VALIGN="TOP"><font FACE="Arial" SIZE="2">WBEM_E_INVALID_PARAMETER</font></td>
<td WIDTH="326" VALIGN="TOP"><font FACE="Arial" SIZE="2">An invalid parameter was
specified.</font></td>
</tr>
</table>
<font face="Arial" size="2">
<p><em>pMem</em> must not be NULL for this operation to succeed, and it must contain the
Decoration Part (specified by <em>dwParts</em>).</font><b><font FACE="Arial Narrow"></p>
<p></font></b><font face="Arial" size="2">Valid flags for dwParts are as follows:</font><font
FACE="Arial Narrow"><b></p>
<table CELLSPACING="0" BORDER="0" WIDTH="463">
<tr>
</b><td WIDTH="53%" VALIGN="TOP"><font FACE="Arial" SIZE="2">WBEM_OBJ_DECORATION_PART</font></td>
<td WIDTH="47%" VALIGN="TOP"><font FACE="Arial" SIZE="2">The decoration part is available.</font></td>
<b>
</tr>
<tr>
</b><td WIDTH="53%" VALIGN="TOP"><font FACE="Arial" SIZE="2">WBEM_OBJ_INSTANCE_PART</font></td>
<td WIDTH="47%" VALIGN="TOP"><font FACE="Arial" SIZE="2">The instance part is available.</font></td>
<b>
</tr>
<tr>
</b><td WIDTH="53%" VALIGN="TOP"><font FACE="Arial" SIZE="2">WBEM_OBJ_CLASS_PART</font></td>
<td WIDTH="47%" VALIGN="TOP"><font FACE="Arial" SIZE="2">The class part is available.</font></td>
<b>
</tr>
</table>
<p></b></font><font face="Arial" size="2">If <em>dwParts</em> does not specify
WBEM_OBJ_DECORATION_PART</font><font FACE="Arial Narrow"><font size="2">, the operation
will return WBEM_E_INVALID_OPERATION.</font><b></p>
<p>See Also</font><u><font FACE="Arial" SIZE="2"></p>
</font></u></b>
<p><font size="2" color="#000000"><b>IWbemServices::GetObjectParts<br>
IWbemServices::SetObjectMemory<br>
IWbemServices::GetObjectMemory<br>
</b></font></p>
<hr>
<p></font><a name="GetObjectParts"></a><b><font face="Arial Narrow" size="5"
color="#000000">IWbemObjectInternals</font><font face="Arial Narrow" size="5">::GetObjectParts</font></b><font
SIZE="2" COLOR="#ff00ff"></p>
</font>
<p><font face="Arial" size="2" color="#000000">You can use the <b>IWbemObjectInternals::GetObjectParts</b>
method to retrieve a copy of the specified underlying parts from an <strong>IWbemClassObject</strong>.
&nbsp; These parts will be placed one after the other in the destinatio buffer.</font><b></p>
</b>
<p><font FACE="Lucida Sans Typewriter" SIZE="2" color="#008000"><b>HRESULT GetObjectParts(<br>
&nbsp;&nbsp;&nbsp; [out] LPVOID <i>pDestination</i>,<br>
&nbsp;&nbsp;&nbsp; [in] DWORD <i>dwDestBuffSize</i>,<i><br>
</i>&nbsp;&nbsp;&nbsp; [in] DWORD <i>dwParts</i>,<i><br>
&nbsp;&nbsp;&nbsp; [out] DWORD* pdwUsed<br>
&nbsp;&nbsp; );</b></font><font face="Arial" size="2" color="#800000"></p>
<p></font></i><strong><font face="Arial Narrow" color="#000000">Parameters</font></strong><i><font
face="Arial" size="2" color="#800000"></p>
<p></font><font face="Arial" size="2" color="#000000">pDestination<br>
</i>Buffer to copy data into.</font></p>
<i>
<p><font face="Arial" size="2" color="#000000">dwDestBuffSize<br>
</i>Size of the destination buffer.</font></p>
<i>
<p><font face="Arial" size="2" color="#000000">dwParts<br>
</i>Parts to copy into the supplied buffer.&nbsp; Values described below.</font></p>
<i>
<p><font face="Arial" size="2" color="#000000">pdwUsed<br>
</i>Number of bytes used in the destination buffer.</font></p>
<p><font color="#000000"><b>Return Values</b></font></p>
<table CELLSPACING="0" BORDER="0" WIDTH="576">
<tr>
<td WIDTH="246" VALIGN="TOP"><font face="Arial" size="2" color="#000000">WBEM_S_NO_ERROR</font></td>
<td WIDTH="326" VALIGN="TOP"><font face="Arial" size="2" color="#000000">The call
succeeded and returned appropriate data in the supplied buffer.</font></td>
</tr>
<tr>
<td WIDTH="246" VALIGN="TOP"><font face="Arial" size="2" color="#000000">WBEM_E_BUFFER_TOO_SMALL</font></td>
<td WIDTH="326" VALIGN="TOP"><font face="Arial" size="2" color="#000000">The supplied
buffer was too small to copy data into.</font></td>
</tr>
<tr>
<td WIDTH="246" VALIGN="TOP"><font face="Arial" size="2" color="#000000">WBEM_E_INVALID_PARAMETER</font></td>
<td WIDTH="326" VALIGN="TOP"><font face="Arial" size="2" color="#000000">An invalid
parameter was specified.</font></td>
</tr>
<tr>
<td WIDTH="246" VALIGN="TOP"><font face="Arial" size="2" color="#000000">WBEM_E_INVALID_OPERATION</font></td>
<td WIDTH="326" VALIGN="TOP"><font face="Arial" size="2" color="#000000">An invalid
operation was requested.</font></td>
</tr>
</table>
<p><font face="Arial" size="2" color="#000000">To get the size of the buffer required to
copy the data into, pass a NULL for <em>pDestination</em> and a 0 for <em>dwDestBuffSize</em>.
&nbsp; <em>pdwUsed</em> will be filled with the size required to copy the specified parts.
&nbsp; The function will return WBEM_E_BUFFER_TOO_SMALL.&nbsp; Note that whenever
WBEM_E_BUFFER_TOO_SMALL is returned, <em>pdwUsed</em> will contain the size required to
copy the specified parts.</font></p>
<p><font face="Arial" size="2" color="#000000">To specify the parts, you can use any or
all of the following flags:</font></p>
<table CELLSPACING="0" BORDER="0" WIDTH="463">
<tr>
<td WIDTH="53%" VALIGN="TOP"><font face="Arial" size="2">WBEM_OBJ_DECORATION_PART</font></td>
<td WIDTH="47%" VALIGN="TOP"><font face="Arial" size="2">The decoration part.</font></td>
</tr>
<tr>
<td WIDTH="53%" VALIGN="TOP"><font face="Arial" size="2">WBEM_OBJ_INSTANCE_PART</font></td>
<td WIDTH="47%" VALIGN="TOP"><font face="Arial" size="2">The instance part..</font></td>
</tr>
<tr>
<td WIDTH="53%" VALIGN="TOP"><font face="Arial" size="2">WBEM_OBJ_CLASS_PART</font></td>
<td WIDTH="47%" VALIGN="TOP"><font face="Arial" size="2">The class part.</font></td>
</tr>
</table>
<p><font face="Arial" size="2">The data will be copied out Decoration, Class then
Instance, maintaining that order in terms of the actual parts copied out.</font><b></p>
<p></b><font face="Arial" size="2">The requested part(s) must be avaliable or the
operation will return WBEM_E_INVALID_OPERATION.</font><b></p>
<p><font color="#000000">See Also</font></p>
</b>
<p><font color="#000000" size="2"><b>IWbemServices::SetObjectParts<br>
IWbemServices::SetObjectMemory<br>
IWbemServices::GetObjectMemory<br>
</b></font></p>
<hr>
<font FACE="Arial Narrow" SIZE="5" COLOR="#800000">
<p></font><a name="StripClassPart"></a><b><font face="Arial Narrow" size="5"
color="#000000">IWbemObjectInternals</font><font face="Arial Narrow" size="5">::StripClassPart</font></b><font
SIZE="2" COLOR="#ff00ff"></p>
</font>
<p><font face="Arial" size="2" color="#000000">You can use the <b>IWbemObjectInternals::StripClassPart</b>
method to remove the class part from the <strong>IWbemClassObject</strong>.&nbsp; Behavior
of the object until a class part is reapplied is undefined.</font><b></p>
</b>
<p><font FACE="Lucida Sans Typewriter" SIZE="2" color="#008000"><b>HRESULT StripClassPart(<br>
<i>&nbsp;&nbsp;&nbsp; void<br>
&nbsp;&nbsp; );</b></font><font face="Arial" size="2" color="#800000"></p>
<p></font></i><strong><font face="Arial Narrow" color="#000000">Parameters</font></strong><font
face="Arial" size="2" color="#800000"><i></p>
</i></font>
<p><font face="Arial" size="2" color="#000000">None.</font></p>
<p><font color="#000000"><b>Return Values</b></font></p>
<table CELLSPACING="0" BORDER="0" WIDTH="576">
<tr>
<td WIDTH="246" VALIGN="TOP"><font face="Arial" size="2" color="#000000">WBEM_S_NO_ERROR</font></td>
<td WIDTH="326" VALIGN="TOP"><font face="Arial" size="2" color="#000000">The call
succeeded and the class part was stripped from the underlying buffer.</font></td>
</tr>
<tr>
<td WIDTH="246" VALIGN="TOP"><font face="Arial" size="2" color="#000000">WBEM_E_OUT_OF_MEMORY</font></td>
<td WIDTH="326" VALIGN="TOP"><font face="Arial" size="2" color="#000000">Unable to
reallocate the buffer.</font></td>
</tr>
<tr>
<td WIDTH="246" VALIGN="TOP"><font face="Arial" size="2">WBEM_E_INVALID_OPERATION</font></td>
<td WIDTH="326" VALIGN="TOP"><font face="Arial" size="2" color="#000000">An invalid
operation was specified.</font></td>
</tr>
</table>
<b>
<p></b><font face="Arial" size="2">For this operation to succeed, the class part MUST be
internal.&nbsp; If it is not, WBEM_E_INVALID_OPERATION will be returned.</font><b></p>
<p><font color="#000000">See Also</font></p>
</b>
<p><font color="#000000" size="2"><b>IWbemServices::SetClassPart<br>
IWbemServices::MergeClassPart<br>
</b></font></p>
<hr>
<font FACE="Arial Narrow" SIZE="5" COLOR="#800000">
<p></font><a name="SetClassPart"></a><b><font face="Arial Narrow" size="5" color="#000000">IWbemObjectInternals</font><font
face="Arial Narrow" size="5">::SetClassPart</font></b><font SIZE="2" COLOR="#ff00ff"></p>
</font>
<p><font face="Arial" size="2" color="#000000">You can use the <b>IWbemObjectInternals::SetClassPart</b>
method to set the class part in an <strong>IWbemClassObject</strong>.</font><b></p>
</b>
<p><font FACE="Lucida Sans Typewriter" SIZE="2" color="#008000"><b>HRESULT StripClassPart(<br>
<i>&nbsp;&nbsp;&nbsp; [in] LPVOID pClassPart,<br>
&nbsp;&nbsp;&nbsp; [in] DWORD dwSize<br>
&nbsp;&nbsp; );</b></font><font face="Arial" size="2" color="#800000"></p>
<p></font></i><strong><font face="Arial Narrow" color="#000000">Parameters</font></strong><i><font
face="Arial" size="2" color="#800000"></p>
<p></font><font face="Arial" size="2" color="#000000">pClassPart<br>
</i>Buffer to copy class part data from.</font></p>
<i>
<p><font face="Arial" size="2" color="#000000">dwSize<br>
</i>Size of the buffer we are copying from.</font></p>
<p><font color="#000000"><b>Return Values</b></font></p>
<table CELLSPACING="0" BORDER="0" WIDTH="576">
<tr>
<td WIDTH="246" VALIGN="TOP"><font face="Arial" size="2" color="#000000">WBEM_S_NO_ERROR</font></td>
<td WIDTH="326" VALIGN="TOP"><font face="Arial" size="2" color="#000000">The call
succeeded and the class part was stripped from the underlying buffer.</font></td>
</tr>
<tr>
<td WIDTH="246" VALIGN="TOP"><font face="Arial" size="2" color="#000000">WBEM_E_OUT_OF_MEMORY</font></td>
<td WIDTH="326" VALIGN="TOP"><font face="Arial" size="2" color="#000000">Unable to
reallocate the buffer.</font></td>
</tr>
<tr>
<td WIDTH="246" VALIGN="TOP"><font face="Arial" size="2">WBEM_E_INVALID_PARAMETER</font></td>
<td WIDTH="326" VALIGN="TOP"><font face="Arial" size="2" color="#000000">An invalid
parameter was specified.</font></td>
</tr>
</table>
<b>
<p></b><font face="Arial" size="2">This operation will resize the underlying buffer to
accomodate the class part.&nbsp; The class part will be copied into the resized buffer.</font><b></p>
<p><font color="#000000">See Also</font></p>
</b>
<p><font color="#000000" size="2"><b>IWbemServices::StripClassPart<br>
IWbemServices::MergeClassPart<br>
</b></font></p>
<hr>
<font FACE="Arial Narrow" SIZE="5" COLOR="#800000">
<p></font><a name="MergeClassPart"></a><b><font face="Arial Narrow" size="5"
color="#000000">IWbemObjectInternals</font><font face="Arial Narrow" size="5">::MergeClassPart</font></b><font
SIZE="2" COLOR="#ff00ff"></p>
</font>
<p><font face="Arial" size="2" color="#000000">You can use the <b>IWbemObjectInternals::MergeClassPart</b>
method to set the class part in an <strong>IWbemClassObject</strong> to point to the class
part of another <strong>IWbemClassObject</strong>.</font><b></p>
</b>
<p><font FACE="Lucida Sans Typewriter" SIZE="2" color="#008000"><b>HRESULT MergeClassPart(<br>
<i>&nbsp;&nbsp;&nbsp; [in] IWbemClassObject* pObj<br>
&nbsp;&nbsp; );</i></b></font></p>
<i><font face="Arial" size="2" color="#800000">
<p></font></i><strong><font face="Arial Narrow" color="#000000">Parameters</font></strong><i><font
face="Arial" size="2" color="#800000"></p>
<p></font><font face="Arial" size="2" color="#000000">pObj<br>
</i>Pointer to an IWbemClassObject whose class part the current object will merge with.</font></p>
<p><font color="#000000"><b>Return Values</b></font></p>
<table CELLSPACING="0" BORDER="0" WIDTH="576">
<tr>
<td WIDTH="246" VALIGN="TOP"><font face="Arial" size="2" color="#000000">WBEM_S_NO_ERROR</font></td>
<td WIDTH="326" VALIGN="TOP"><font face="Arial" size="2" color="#000000">The call
succeeded and the class part was stripped from the underlying buffer.</font></td>
</tr>
<tr>
<td WIDTH="246" VALIGN="TOP"><font face="Arial" size="2" color="#000000">WBEM_E_OUT_OF_MEMORY</font></td>
<td WIDTH="326" VALIGN="TOP"><font face="Arial" size="2" color="#000000">Unable to
reallocate the buffer.</font></td>
</tr>
<tr>
<td WIDTH="246" VALIGN="TOP"><font face="Arial" size="2">WBEM_E_INVALID_PARAMETER</font></td>
<td WIDTH="326" VALIGN="TOP"><font face="Arial" size="2" color="#000000">An invalid
parameter was specified.</font></td>
</tr>
<tr>
<td WIDTH="246" VALIGN="TOP"><font face="Arial" size="2">WBEM_E_INVALID_OPERATION</font></td>
<td WIDTH="326" VALIGN="TOP"><font face="Arial" size="2" color="#000000">An invalid
operation was specified.</font></td>
</tr>
</table>
<b>
<p></b><font face="Arial" size="2">This operation will point the class part of the current
object at the class part of the specified object.&nbsp; The specified object must be an
Instance object, and it must contain a class part, or WBEM_E_INVALID_OPERATION will be
returned.&nbsp; This function will call <strong>IWbemClassObject::AddRef()</strong> on the
supplied object.&nbsp; When the current object is destroyed, it will call <strong>IWbemClassObject::Release()</strong>
on the object it is merged with.</font><b></p>
<p><font color="#000000">See Also</font></p>
<p><font color="#000000" size="2">IWbemServices::StripClassPart<br>
IWbemServices::SetClassPart<br>
IWbemServices::QueryObjectInfo<br>
IWbemServices::SetObjectParts<br>
IWbemServices::GetObjectParts<br>
</font></b></p>
</body>
</html>