de.cau.cs.kieler.sim.kiem.automated.ui.extension
Class AutomationListener

java.lang.Object
  extended by de.cau.cs.kieler.sim.kiem.automated.AbstractAutomationListener
      extended by de.cau.cs.kieler.sim.kiem.automated.ui.extension.AutomationListener
All Implemented Interfaces:
IAutomationListener

public class AutomationListener
extends AbstractAutomationListener

Listens to events coming from the automated execution and is responsible for relaying them to the different view elements.

Rating proposed yellow
(2010-04-12)

Constructor Summary
AutomationListener()
           
 
Method Summary
 void doPreAutomationProcessing()
          This method is called immediately before the automation starts and gives listeners a chance to perform some action like opening views or loading plugins.
 void executionFileStarted(IPath executionFile, Exception exception)
          This method indicates that the automation tried to start a new execution file.
 void receiveIterationResult(IterationResult result)
          Publishes the result of the currently running iteration.
 void receiveIterationResult(List<IterationResult> results)
          Publishes a list of results of the last couple of iterations.
 void receiveModelFileResults(IPath executionFile, List<AbstractResult> results)
          This method will pass all summarized model file results produced by the given execution file.
 void refresh()
          Notifies the listeners that information in the already produced results may have changed and that the listeners should re-check the values.
 
Methods inherited from class de.cau.cs.kieler.sim.kiem.automated.AbstractAutomationListener
doPostAutomationProcessing
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

AutomationListener

public AutomationListener()
Method Detail

doPreAutomationProcessing

public void doPreAutomationProcessing()
This method is called immediately before the automation starts and gives listeners a chance to perform some action like opening views or loading plugins.

Specified by:
doPreAutomationProcessing in interface IAutomationListener
Overrides:
doPreAutomationProcessing in class AbstractAutomationListener

executionFileStarted

public void executionFileStarted(IPath executionFile,
                                 Exception exception)
This method indicates that the automation tried to start a new execution file. If starting the file failed the exception will be passed.

Specified by:
executionFileStarted in interface IAutomationListener
Overrides:
executionFileStarted in class AbstractAutomationListener
Parameters:
executionFile - the path to the execution file
exception - an exception that caused the file to fail, null if the file was started successfully

receiveIterationResult

public void receiveIterationResult(IterationResult result)
Publishes the result of the currently running iteration. This result might NOT be complete yet and some information in it might be changed or updated until the iteration finishes. All listeners should re-check the iteration results when the refresh method is called.

Specified by:
receiveIterationResult in interface IAutomationListener
Overrides:
receiveIterationResult in class AbstractAutomationListener
Parameters:
result - the result

receiveIterationResult

public void receiveIterationResult(List<IterationResult> results)
Publishes a list of results of the last couple of iterations. The results might NOT be complete yet and some information in them might be changed or updated until the model file finishes. All listeners should re-check the iteration results when the refresh method is called.

Specified by:
receiveIterationResult in interface IAutomationListener
Overrides:
receiveIterationResult in class AbstractAutomationListener
Parameters:
results - the results

receiveModelFileResults

public void receiveModelFileResults(IPath executionFile,
                                    List<AbstractResult> results)
This method will pass all summarized model file results produced by the given execution file. It will be called once the execution file was completely simulated.

Specified by:
receiveModelFileResults in interface IAutomationListener
Overrides:
receiveModelFileResults in class AbstractAutomationListener
Parameters:
executionFile - the execution file
results - the list of model file results

refresh

public void refresh()
Notifies the listeners that information in the already produced results may have changed and that the listeners should re-check the values. A change should only happen in the results connected to the currently simulated execution file.

Specified by:
refresh in interface IAutomationListener
Overrides:
refresh in class AbstractAutomationListener