Represents a part that contains data and is not a Relationships part.
When to implement
Never. Custom implementations of this interface are not supported.
The IOpcPart interface inherits from the IUnknown interface. IOpcPart also has these types of members:
The IOpcPart interface has these methods.
Gets a value that describes the way part content is compressed.
Gets a stream that provides read/write access to part content.
Gets the media type of part content.
Gets a part URI object that represents the part name.
Gets a relationship set object that represents the Relationships part that stores relationships that have the part as their source.
To create a part object to represent a part, call the IOpcPartSet::CreatePart method. To get a pointer to the interface of a part object that represents an existing part, call the IOpcPartSet::GetPart or IOpcPartEnumerator::GetCurrent method.
A Relationships part cannot be represented by an implementation of the IOpcPart interface.
Methods of an IOpcPart interface provide access to part information through the properties listed in the following table:
The compression option to be used on part content.
The stream of bytes that makes up the part as described in the ECMA-376 OpenXML, 1st Edition, Part 2: Open Packaging Conventions (OPC).
The media type of the part content, as specified by the package designer in compliance with the rules in the OPC.
The URI of the part in the package.
For more information about parts, see the Open Packaging Conventions Fundamentals and the OPC.
Packaging objects are not thread-safe.
For more information, see the Getting Started with the Packaging API.
Minimum supported client
|Windows 7 [desktop apps only]|
Minimum supported server
|Windows Server 2008 R2 [desktop apps only]|
- Core Packaging Interfaces
- Getting Started with the Packaging API
- Open Packaging Conventions Fundamentals
- Parts Overview
- Packaging API Reference
- Packaging API Samples
- External Resources
- ECMA-376 OpenXML