Package org.eclipse.handly.ui.outline

# Class LinkWithEditorContribution

java.lang.Object
org.eclipse.handly.ui.outline.OutlineContribution
org.eclipse.handly.ui.outline.LinkWithEditorContribution

All Implemented Interfaces:
  `IOutlineContribution`

public abstract class LinkWithEditorContribution extends OutlineContribution
An abstract base class for link-with-editor contributions.

Contributes link-with-editor behavior, if the outline page supports linking with editor. The activation of the feature is governed by the corresponding `preference`. Subclasses must implement linking logic in a `linking helper`.

- ## Constructor Summary

  Constructors
  Constructor
  Description
  `LinkWithEditorContribution()`

- ## Method Summary

  Modifier and Type
  Method
  Description
  `void`
  `dispose()`
  Disposes of this contribution.
  `protected abstract org.eclipse.ui.OpenAndLinkWithEditorHelper`
  `getLinkingHelper()`
  Returns a linking helper that will provide link-with-editor logic for the outline page.
  `void`
  `init(ICommonOutlinePage outlinePage)`
  Initializes this contribution.

  ### Methods inherited from class org.eclipse.handly.ui.outline.OutlineContribution

  `getOutlinePage`

  ### Methods inherited from class java.lang.Object

  `clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

- ## Constructor Details

  - ### LinkWithEditorContribution

    public LinkWithEditorContribution()

- ## Method Details

  - ### init

    public void init(ICommonOutlinePage outlinePage)
    Description copied from class: `OutlineContribution`
    Initializes this contribution. This method is called after the outline page's tree viewer has been created.

    This method may be extended by subclasses. Subclasses must call the superclass implementation.

    Specified by:
      `init` in interface `IOutlineContribution`
    Overrides:
      `init` in class `OutlineContribution`
    Parameters:
      `outlinePage` - the contribution's outline page (never `null`)

  - ### dispose

    public void dispose()
    Description copied from class: `OutlineContribution`
    Disposes of this contribution. Implementors should clean up any resources associated with this contribution. Note that there is no guarantee that `init()` has been called. This method has no effect if this contribution has already been disposed.

    This method may be extended by subclasses. Subclasses must call the superclass implementation.

    Specified by:
      `dispose` in interface `IOutlineContribution`
    Overrides:
      `dispose` in class `OutlineContribution`

  - ### getLinkingHelper

    protected abstract org.eclipse.ui.OpenAndLinkWithEditorHelper getLinkingHelper()
    Returns a linking helper that will provide link-with-editor logic for the outline page. This method is called once, when this contribution is initializing.
    Returns:
      the linking helper (not `null`)