IWpdSerializer::GetSerializedSize method

The GetSerializedSize method calculates the buffer size that is required to hold a serialized IPortableDeviceValues interface.

Syntax

HRESULT GetSerializedSize(
  [in]  IPortableDeviceValues *pSource,
  [out] DWORD                 *pdwSize
);

Parameters

pSource [in]

Pointer to an IPortableDeviceValues interface whose size you want to request.

pdwSize [out]

Pointer to a DWORD that indicates the buffer size that is required to serialize pSource, in bytes.

Return value

The method returns an HRESULT. Possible values include, but are not limited to, those in the following table.

Return code Description
S_OK
The method succeeded.
E_POINTER
A required pointer argument was NULL.
E_OUTOFMEMORY
There was not enough available memory to create the buffer.

Requirements

Requirement Value
Header
PortableDeviceTypes.h
Library
PortableDeviceGUIDs.lib

See also

IWpdSerializer Interface