Class EUnitRunnerView

  • All Implemented Interfaces:
    org.eclipse.core.runtime.IAdaptable, org.eclipse.core.runtime.IExecutableExtension, EUnitTestListener, 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 EUnitRunnerView
    extends org.eclipse.ui.part.ViewPart
    implements EUnitTestListener
    View part for the EUnit test case runner.

    Note: this class implements the EUnitTestListener interface, but it is does not use the EUnit Ant extension point. That is the role of the ShowEUnitViewTestListener, which creates this view and sets it up. After setting it up, ShowEUnitViewTestListener delegates all notifications to this class.

    Version:
    1.0
    Author:
    Antonio Garc��a-Dom��nguez
    • Field Summary

      Fields 
      Modifier and Type Field Description
      static java.lang.String ID
      The ID of the view as specified by the extension.
      • Fields inherited from interface org.eclipse.ui.IWorkbenchPart

        PROP_TITLE
    • Constructor Summary

      Constructors 
      Constructor Description
      EUnitRunnerView()  
    • Method Summary

      All Methods Instance Methods Concrete Methods 
      Modifier and Type Method Description
      void afterCase​(EUnitModule module, EUnitTest test)
      Notification sent after running a test case.
      void beforeCase​(EUnitModule module, EUnitTest test)
      Notification sent before running a test case.
      void createPartControl​(org.eclipse.swt.widgets.Composite parent)
      This is a callback that will allow us to create the viewer and initialize it.
      void setCurrentModules​(java.util.List<EUnitModule> modules)
      Changes the module which is currently displayed in this view.
      void setFocus()
      Passing the focus request to the viewer's control.
      • Methods inherited from class org.eclipse.ui.part.ViewPart

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

        addPartPropertyListener, addPropertyListener, dispose, 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, dispose, getSite, getTitle, getTitleImage, getTitleToolTip, removePropertyListener
    • Field Detail

      • ID

        public static final java.lang.String ID
        The ID of the view as specified by the extension.
        See Also:
        Constant Field Values
    • Constructor Detail

      • EUnitRunnerView

        public EUnitRunnerView()
    • Method Detail

      • createPartControl

        public void createPartControl​(org.eclipse.swt.widgets.Composite parent)
        This is a callback that will allow us to create the viewer and initialize it.
        Specified by:
        createPartControl in interface org.eclipse.ui.IWorkbenchPart
        Specified by:
        createPartControl in class org.eclipse.ui.part.WorkbenchPart
      • setFocus

        public void setFocus()
        Passing the focus request to the viewer's control.
        Specified by:
        setFocus in interface org.eclipse.ui.IWorkbenchPart
        Specified by:
        setFocus in class org.eclipse.ui.part.WorkbenchPart
      • setCurrentModules

        public void setCurrentModules​(java.util.List<EUnitModule> modules)
        Changes the module which is currently displayed in this view.
        Parameters:
        module - EUnit module to be shown.
      • beforeCase

        public void beforeCase​(EUnitModule module,
                               EUnitTest test)
        Description copied from interface: EUnitTestListener
        Notification sent before running a test case.
        Specified by:
        beforeCase in interface EUnitTestListener
        Parameters:
        module - EUnit module under execution.
        test - Description of the test case: its result has not been set yet.
      • afterCase

        public void afterCase​(EUnitModule module,
                              EUnitTest test)
        Description copied from interface: EUnitTestListener
        Notification sent after running a test case.
        Specified by:
        afterCase in interface EUnitTestListener
        Parameters:
        module - EUnit module under execution.
        test - Test case, with its result set.