Interface ICompareContainer

All Superinterfaces:
IRunnableContext
All Known Implementing Classes:
CompareContainer, CompareEditorInput, HistoryPageCompareEditorInput, PageCompareEditorInput, ParticipantPageCompareEditorInput, SaveableCompareEditorInput, SyncInfoCompareInput

public interface ICompareContainer extends IRunnableContext
A compare container is used to represent any UI that can contain compare viewers.

This interface is not intended to be implemented by clients.

Since:
3.3
  • Method Details

    • addCompareInputChangeListener

      void addCompareInputChangeListener(ICompareInput input, ICompareInputChangeListener listener)
      Register for change events for the given compare input. Although clients can register with the compare input directly, registering through the container allows for deterministic and optimized behavior in some cases. Registering multiple times for the same compare input has no effect.
      Parameters:
      input - the compare input
      listener - the compare input change listener
    • removeCompareInputChangeListener

      void removeCompareInputChangeListener(ICompareInput input, ICompareInputChangeListener listener)
      Remove the change listener from the given compare input. Removing a listener that is not registered has no effect.
      Parameters:
      input - the compare input
      listener - the compare input change listener
    • registerContextMenu

      void registerContextMenu(MenuManager menu, ISelectionProvider selectionProvider)
      Register the content menu with the container to give the container a chance to add additional items to the context menu such as popup menu object contributions. The provided menu should have a IWorkbenchActionConstants.MB_ADDITIONS separator as this is where the container will add actions.
      Parameters:
      menu - the menu being registered
      selectionProvider - the selection provider
    • setStatusMessage

      void setStatusMessage(String message)
      Set the status message displayed by the container to the given message
      Parameters:
      message - the status message
    • getActionBars

      IActionBars getActionBars()
      Return the action bars for the container or null if the container does not have an action bars.
      Returns:
      the action bars for the container or null
    • getServiceLocator

      IServiceLocator getServiceLocator()
      Return the service locator for the container or null if the container does not have one.
      Returns:
      the service locator for the container or null
    • getNavigator

      ICompareNavigator getNavigator()
      Return the ICompareNavigator associated with this container or null if the container does not have a global navigator.
      Returns:
      the ICompareNavigator associated with this container or null
    • runAsynchronously

      void runAsynchronously(IRunnableWithProgress runnable)
      Queue the given task to be run asynchronously. If the given runnable was previously queued to run asynchronously and it has not yet run, the task position will be moved to the end of the queue. If the task that is being queued is currently running, the running task will be canceled and added to the end of the queue.

      This method should be treated as a request to run the given task asynchronously. However, clients should not assume that the code will be run asynchronously. Depending on the container implementation, a call to this method may or may not block the caller until the task is completed. Also, the task may be executed in a modal or non-modal fashion.

      Parameters:
      runnable - the task to be performed
    • getWorkbenchPart

      IWorkbenchPart getWorkbenchPart()
      Return the workbench part associated with this container or null if there is no part or it is not available.
      Returns:
      the workbench part associated with this container or null