mavis
Class MeasurementEvent

java.lang.Object
  extended by java.util.EventObject
      extended by mavis.MeasurementEvent
All Implemented Interfaces:
java.io.Serializable

public class MeasurementEvent
extends java.util.EventObject

MeasurementEvent is used to notify listeners about the stages of an ongoing measurement.

See Also:
Serialized Form

Nested Class Summary
static class MeasurementEvent.Type
          The type of a measurement event.
 
Field Summary
private  Project project
          The project whose measurement sent this event.
private  MeasurementStep step
          The measurement that sent this event.
private  MeasurementEvent.Type type
          The type of event this is.
 
Fields inherited from class java.util.EventObject
source
 
Constructor Summary
MeasurementEvent(Project project, MeasurementStep step, MeasurementEvent.Type type)
          Creates a new measurement event.
 
Method Summary
 Project getProject()
          Returns the project whose measurement sent this event.
 MeasurementStep getStep()
          Returns the measurement that sent this event.
 MeasurementEvent.Type getType()
          Returns the type of event this is.
 
Methods inherited from class java.util.EventObject
getSource, toString
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Field Detail

project

private Project project
The project whose measurement sent this event.


step

private MeasurementStep step
The measurement that sent this event.


type

private MeasurementEvent.Type type
The type of event this is.

Constructor Detail

MeasurementEvent

public MeasurementEvent(Project project,
                        MeasurementStep step,
                        MeasurementEvent.Type type)
Creates a new measurement event.

Parameters:
project - the project whose measurement sent this event.
step - the measurement that sent this event.
type - the type of event this is.
Throws:
java.lang.NullPointerException - if project or type is null.
Method Detail

getProject

public Project getProject()
Returns the project whose measurement sent this event.


getStep

public MeasurementStep getStep()
Returns the measurement that sent this event. Can be null, if this event was sent by a manual command.


getType

public MeasurementEvent.Type getType()
Returns the type of event this is.