ResolveConceptualLinksComponent Class

This is a modified version of the original ResolveConceptualLinksComponent that is used to resolve links to conceptual topics.

Definition

Namespace: Sandcastle.Tools.BuildComponents
Assembly: Sandcastle.Tools.BuildComponents (in Sandcastle.Tools.BuildComponents.dll) Version: 2024.12.21.0
public class ResolveConceptualLinksComponent : BuildComponentCore
Inheritance
Object    BuildComponentCore    ResolveConceptualLinksComponent

Remarks

This version contains the following improvements and fixes:
  • Broken links use the None style rather than the Index style so that it is apparent that they do not work.
  • The inner text from the conceptual link is used if specified.
  • On broken links, when the showBrokenLinkText option is true and there is no inner text, the target value is displayed.
  • Conceptual link targets can include an optional anchor name from within the target such as "#Name" (see examples below).
  • Unnecessary whitespace is removed from the link text.
  • If the companion file contains a <linkText> element and no inner text is specified, its value will be used for the link text rather than the title. This allows for a shorter title or description to use as the default link text.

Example

On links without inner text, if the companion file contains a linkText element, that text will be used. If not, the title is used.
Example Links
<!-- Link with inner text -->
             <link xlink:href="3ab3113f-984b-19ac-7812-990192aca5b0">Click Here</link>
             <!-- Link with anchor reference -->
             <link xlink:href="3ab3113f-984b-19ac-7812-990192aca5b1#SubTopic" />
             <!-- Link with inner text and an anchor reference -->
             <link xlink:href="3ab3113f-984b-19ac-7812-990192aca5b1#PropA">PropertyA</link>
Example configuration
<!-- Resolve conceptual links -->
<component id="Resolve Conceptual Links Component">
    <showBrokenLinkText value="true" />
    <targets base="xmlComp" type="local" />
</component>

Constructors

Properties

BuildAssembler This read-only property returns a reference to the build assembler instance using the component
(Inherited from BuildComponentCore)
GroupId This is used to set an optional group ID for use with component events
(Inherited from BuildComponentCore)

Methods

Apply This is implemented to resolve the conceptual links
(Overrides BuildComponentCoreApply(XmlDocument, String))
Dispose This implements the Dispose() interface to properly dispose of the build component.
(Inherited from BuildComponentCore)
Dispose(Boolean) This can be overridden by derived classes to add their own disposal code if necessary.
(Inherited from BuildComponentCore)
EqualsDetermines whether the specified object is equal to the current object.
(Inherited from Object)
Finalize This handles garbage collection to ensure proper disposal of the build component if not done explicitly with Dispose.
(Inherited from BuildComponentCore)
GetHashCodeServes as the default hash function.
(Inherited from Object)
GetTypeGets the Type of the current instance.
(Inherited from Object)
Initialize This abstract method must be overridden to initialize the component
(Overrides BuildComponentCoreInitialize(XPathNavigator))
MemberwiseCloneCreates a shallow copy of the current Object.
(Inherited from Object)
OnComponentEvent This can be used to raise the ComponentEvent event with the specified event arguments.
(Inherited from BuildComponentCore)
ToStringReturns a string that represents the current object.
(Inherited from Object)
WriteMessage(MessageLevel, String, Object) This can be used to report a message
(Inherited from BuildComponentCore)
WriteMessage(String, MessageLevel, String, Object) This can be used to report a message for a specific topic ID
(Inherited from BuildComponentCore)

See Also