IAppxFactory::CreateBlockMapReader method (appxpackaging.h)

Creates a read-only block map object model from contents provided by an IStream.

Syntax

HRESULT CreateBlockMapReader(
  [in]          IStream             *inputStream,
  [out, retval] IAppxBlockMapReader **blockMapReader
);

Parameters

[in] inputStream

Type: IStream*

The stream that delivers the block map XML for reading. The stream must support Read, Seek, and Stat. If these methods fail, their error codes might be passed to and returned by this method.

[out, retval] blockMapReader

Type: IAppxBlockMapReader**

The block map reader.

Return value

Type: HRESULT

If the method succeeds, it returns S_OK. Otherwise, it returns an error code that includes, but is not limited to, those in the following table.

Return code Description
APPX_E_INVALID_BLOCKMAP
The inputStream does not contain syntactically valid XML for the block map.

Remarks

Use the CreateBlockMapReader method to read a block map outside of an app package. The blockMapReader provides access to all data elements and attributes in the block map XML.

Requirements

Requirement Value
Minimum supported client Windows 8 [desktop apps only]
Minimum supported server Windows Server 2012 [desktop apps only]
Target Platform Windows
Header appxpackaging.h

See also

IAppxFactory

IAppxFactory::CreateValidatedBlockMapReader