IOpcRelationshipSet interface

Represents a Relationships part as an unordered set of IOpcRelationship interface pointers to relationship objects.

When to implement

Never. Custom implementations of this interface are not supported.

Members

The IOpcRelationshipSet interface inherits from the IUnknown interface. IOpcRelationshipSet also has these types of members:

Methods

The IOpcRelationshipSet interface has these methods.

MethodDescription
CreateRelationship

Creates a relationship object that represents a specified relationship, then adds to the set a pointer to the object's IOpcRelationship interface.

DeleteRelationship

Deletes a specified IOpcRelationship interface pointer from the set.

GetEnumerator

Gets an enumerator of IOpcRelationship interface pointers in the set.

GetEnumeratorForType

Gets an enumerator of the IOpcRelationship interface pointers in the set that point to representations of relationships that have a specified relationship type.

GetRelationship

Gets a relationship object from the set that represents a specified relationship.

GetRelationshipsContentStream

Gets a read-only stream that contains the part content of the Relationships part represented by the set.

RelationshipExists

Gets a value that indicates whether a specified relationship is represented as a relationship object in the set.

 

Remarks

When a relationship object is created and a pointer to it is added to the set, the relationship it represents is saved when the package is saved.

When an IOpcRelationship interface pointer is deleted from the set, the relationship it represents is not saved when the package is saved.

If a relationship is represented in the set, the relationship is stored in the Relationships part represented as the set.

For how to form the part name for the target of a relationship, see Resolving a Part Name from a Target URI.

For more information about relationships, see Open Packaging Conventions Fundamentals and the ECMA-376 OpenXML, 1st Edition, Part 2: Open Packaging Conventions (OPC).

The IOpcRelationship interface provides access to relationship properties. For details about these properties, see the Relationships Overview and IOpcRelationship.

Thread Safety

Packaging objects are not thread-safe.

For more information, see the Getting Started with the Packaging API.

Requirements

Minimum supported client

Windows 7 [desktop apps | Windows Store apps]

Minimum supported server

Windows Server 2008 R2 [desktop apps | Windows Store apps]

Header

Msopc.h

IDL

Msopc.idl

See also

Core Packaging Interfaces
Overviews
Getting Started with the Packaging API
Open Packaging Conventions Fundamentals
Relationships Overview
Reference
IOpcRelationshipEnumerator
Packaging API Reference
Packaging API Samples
External Resources
ECMA-376 OpenXML

 

 

Community Additions

ADD
Show: