Class ReferencesView

  • All Implemented Interfaces:
    org.eclipse.core.runtime.IAdaptable, org.eclipse.core.runtime.IExecutableExtension, org.eclipse.jface.viewers.ISelectionProvider, org.eclipse.ui.IPersistable, org.eclipse.ui.IViewPart, org.eclipse.ui.IWorkbenchPart, org.eclipse.ui.IWorkbenchPart2, org.eclipse.ui.IWorkbenchPart3, org.eclipse.ui.part.IWorkbenchPartOrientation

    public class ReferencesView
    extends org.eclipse.ui.part.ViewPart
    implements org.eclipse.jface.viewers.ISelectionProvider
    The References View Part.
    Author:
    Christopher Mindus
    • Field Summary

      Fields 
      Modifier and Type Field Description
      static java.lang.String ID
      The View Part ID "com.iizigo.editor.ReferencesView".
      • Fields inherited from interface org.eclipse.ui.IWorkbenchPart

        PROP_TITLE
    • Constructor Summary

      Constructors 
      Constructor Description
      ReferencesView()
      Eclipse constructor.
    • Method Summary

      All Methods Instance Methods Concrete Methods 
      Modifier and Type Method Description
      void addSelectionChangedListener​(org.eclipse.jface.viewers.ISelectionChangedListener listener)
      Adds a listener for selection changes in this selection provider.
      void createPartControl​(org.eclipse.swt.widgets.Composite parent)
      Create contents of the view part.
      void dispose()
      Disposes of the view part.
      void findReferences​(org.eclipse.jface.viewers.ISelection selection)
      Finds the references from a selection.
      org.eclipse.jface.viewers.ISelection getSelection()
      Returns the current selection for this provider.
      void init​(org.eclipse.ui.IViewSite site, org.eclipse.ui.IMemento memento)
      Initializes the part with a memento.
      void removeSelectionChangedListener​(org.eclipse.jface.viewers.ISelectionChangedListener listener)
      Removes the given selection change listener from this selection provider.
      void saveState​(org.eclipse.ui.IMemento memento)
      Save the state.
      void setFocus()
      Sets focus to the table.
      void setSelection​(org.eclipse.jface.viewers.ISelection selection)
      Sets the current selection for this selection provider.
      • Methods inherited from class org.eclipse.ui.part.ViewPart

        checkSite, getViewSite, init, setContentDescription, setInitializationData, setPartName
      • Methods inherited from class org.eclipse.ui.part.WorkbenchPart

        addPartPropertyListener, addPropertyListener, firePartPropertyChanged, firePropertyChange, getAdapter, getConfigurationElement, getContentDescription, getDefaultImage, getOrientation, getPartName, getPartProperties, getPartProperty, getSite, getTitle, getTitleImage, getTitleToolTip, removePartPropertyListener, removePropertyListener, setPartProperty, setSite, setTitle, setTitleImage, setTitleToolTip, showBusy
      • Methods inherited from class org.eclipse.core.commands.common.EventManager

        addListenerObject, clearListeners, getListeners, isListenerAttached, removeListenerObject
      • Methods inherited from class java.lang.Object

        clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
      • Methods inherited from interface org.eclipse.core.runtime.IAdaptable

        getAdapter
      • Methods inherited from interface org.eclipse.ui.IWorkbenchPart

        addPropertyListener, getSite, getTitle, getTitleImage, getTitleToolTip, removePropertyListener
    • Field Detail

      • ID

        public static final java.lang.String ID
        The View Part ID "com.iizigo.editor.ReferencesView".
    • Constructor Detail

      • ReferencesView

        public ReferencesView()
        Eclipse constructor.
    • Method Detail

      • createPartControl

        public void createPartControl​(org.eclipse.swt.widgets.Composite parent)
        Create contents of the view part.
        Specified by:
        createPartControl in interface org.eclipse.ui.IWorkbenchPart
        Specified by:
        createPartControl in class org.eclipse.ui.part.WorkbenchPart
        Parameters:
        parent -
      • init

        public void init​(org.eclipse.ui.IViewSite site,
                         org.eclipse.ui.IMemento memento)
                  throws org.eclipse.ui.PartInitException
        Initializes the part with a memento.
        Specified by:
        init in interface org.eclipse.ui.IViewPart
        Overrides:
        init in class org.eclipse.ui.part.ViewPart
        Throws:
        org.eclipse.ui.PartInitException
      • saveState

        public void saveState​(org.eclipse.ui.IMemento memento)
        Save the state.
        Specified by:
        saveState in interface org.eclipse.ui.IPersistable
        Specified by:
        saveState in interface org.eclipse.ui.IViewPart
        Overrides:
        saveState in class org.eclipse.ui.part.ViewPart
      • dispose

        public void dispose()
        Disposes of the view part.
        Specified by:
        dispose in interface org.eclipse.ui.IWorkbenchPart
        Overrides:
        dispose in class org.eclipse.ui.part.WorkbenchPart
      • setFocus

        public void setFocus()
        Sets focus to the table.
        Specified by:
        setFocus in interface org.eclipse.ui.IWorkbenchPart
        Specified by:
        setFocus in class org.eclipse.ui.part.WorkbenchPart
      • addSelectionChangedListener

        public void addSelectionChangedListener​(org.eclipse.jface.viewers.ISelectionChangedListener listener)
        Adds a listener for selection changes in this selection provider. Has no effect if an identical listener is already registered.
        Specified by:
        addSelectionChangedListener in interface org.eclipse.jface.viewers.ISelectionProvider
        Parameters:
        listener - A selection changed listener.
      • getSelection

        public org.eclipse.jface.viewers.ISelection getSelection()
        Returns the current selection for this provider.
        Specified by:
        getSelection in interface org.eclipse.jface.viewers.ISelectionProvider
        Returns:
        The current selection.
      • removeSelectionChangedListener

        public void removeSelectionChangedListener​(org.eclipse.jface.viewers.ISelectionChangedListener listener)
        Removes the given selection change listener from this selection provider. Has no effect if an identical listener is not registered.
        Specified by:
        removeSelectionChangedListener in interface org.eclipse.jface.viewers.ISelectionProvider
        Parameters:
        listener - A selection changed listener.
      • setSelection

        public void setSelection​(org.eclipse.jface.viewers.ISelection selection)
        Sets the current selection for this selection provider.
        Specified by:
        setSelection in interface org.eclipse.jface.viewers.ISelectionProvider
        Parameters:
        selection - The new selection.
      • findReferences

        public void findReferences​(org.eclipse.jface.viewers.ISelection selection)
        Finds the references from a selection.