RelationshipsManager
General
RelationshipsManager és una classe en Aspose.Slides per NET.
Gestió de relacions (.rels) en un paquet OPC. Cada part pot tenir un arxiu .rells associat que defineix les seves relacions amb altres parts. Aquesta classe proporciona mètodes per carregar, afegir, eliminar i serialitzar les relacions a XML.
Propietats
| Name | Type | Access | Description |
|---|---|---|---|
PartName | string | Read | Gets the part name of the relationships file |
Mètodes
| Signature | Description |
|---|---|
RelationshipsManager(package: OpcPackage, sourcePart: string) | Initializes a manager with an OPC package and source part path |
GetRelsPartName(sourcePart: string) | Gets the .rels file path for a given source part. The source part path. The corresponding .rels part path. "" → “_rels/.rels” “ppt/presentation.xml” → “ppt/_rels/presentation.xml.rels” “ppt/slides/slide1.xml” → “ppt/slides/_rels/slide1.xml.rels” |
Load() | Loads and parses the .rels file from the package. |
ParseRelationships() | Parses relationships from the loaded XML element. |
GetRelationship(relId: string) | The or null if not found. |
GetRelationshipsByType(relType: string) | A list of matching relationships. |
GetAllRelationships() | A list of all relationships. |
GenerateRelId() | A relationship ID not already in use. |
AddRelationship(relType: string, target: string, relId: string?, targetMode: string?) | The relationship ID. |
RemoveRelationship(relId: string) | true if removed; false if not found. |
Save() | Saves the relationships back to the package. If there are no relationships, the .rels part is deleted. |