faa.tg.simevent.action
Class ActivateFlightAction

java.lang.Object
  extended by faa.tg.simevent.action.ActivateFlightAction
All Implemented Interfaces:
RecordableConditionalState<SimulationTime>, SimEventAction, java.io.Serializable

public class ActivateFlightAction
extends java.lang.Object
implements SimEventAction, java.io.Serializable

 ActivateFlightAction activates a Flight.
 
See the source: ActivateFlightAction.java

Version:
$Id: ActivateFlightAction.java,v 3.5 2008/05/16 15:46:16 lykensj Exp $
Author:
David D'Auria, SRC/FAA/ACT-510
See Also:
SimEventActionState, Serialized Form

Field Summary
private  java.lang.String aircraftID
          The aircraft ID of the flight to be activated.
static java.lang.String CVS_VERSION_ID
          The CVS Version ID
private  Flight flight
          The Flight to be activated.
(package private) static long serialVersionUID
           
 
Constructor Summary
ActivateFlightAction(Flight theFlight)
          Construct an ActivateFlightAction with theFlight to be activated.
 
Method Summary
 void execute(Scenario scenario)
          Activate the flight.
 java.lang.String getName()
          Returns a String that can be used as the name of this object.
 SimEventActionState getRecordable(SimulationTime timeStamp)
          This is to satisfy the implementation of RecordableConditionalState (from SimEventAction).
 java.lang.String toString()
          Returns the SpCommand information as a String.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Field Detail

serialVersionUID

static final long serialVersionUID
See Also:
Constant Field Values

CVS_VERSION_ID

public static final java.lang.String CVS_VERSION_ID
The CVS Version ID

See Also:
Constant Field Values

flight

private transient Flight flight
The Flight to be activated. Will be null after deserialization.


aircraftID

private java.lang.String aircraftID
The aircraft ID of the flight to be activated.

Constructor Detail

ActivateFlightAction

public ActivateFlightAction(Flight theFlight)
Construct an ActivateFlightAction with theFlight to be activated.

Parameters:
theFlight - to be activated.
Method Detail

execute

public void execute(Scenario scenario)
             throws ExecutionException
Activate the flight.

Specified by:
execute in interface SimEventAction
Throws:
ExecutionException - If a problem in execution.

getName

public java.lang.String getName()
Returns a String that can be used as the name of this object.


getRecordable

public SimEventActionState getRecordable(SimulationTime timeStamp)
This is to satisfy the implementation of RecordableConditionalState (from SimEventAction).

Specified by:
getRecordable in interface RecordableConditionalState<SimulationTime>
Specified by:
getRecordable in interface SimEventAction
Parameters:
timeStamp - the current time of the Scenario.
Returns:
SimEventActionState with State information for this Class.

toString

public java.lang.String toString()
Returns the SpCommand information as a String.

Overrides:
toString in class java.lang.Object
Returns:
SpCommand information as a String.