cdx
Class InputFrameHandler
java.lang.Object
javax.safetycritical.AbstractAsyncEventHandler
javax.safetycritical.AsyncEventHandler
javax.safetycritical.BoundAsyncEventHandler
javax.safetycritical.ManagedEventHandler
javax.safetycritical.PeriodicEventHandler
cdx.InputFrameHandler
- All Implemented Interfaces:
- java.lang.Runnable, javax.safetycritical.ManagedSchedulable, javax.safetycritical.Schedulable
public class InputFrameHandler
- extends javax.safetycritical.PeriodicEventHandler
InputFrameHandler is a periodic handler that reads and stores radar frames
as they arrive. It also updates the shared variable "state" for previous
aircraft positions.
Field Summary |
CDxMission |
mission
The current mission |
javax.safetycritical.AperiodicEvent |
reduce
The event to release ReducerHandler |
Method Summary |
void |
handleEvent()
Major method of a handler: store the previous frame to `state'
and get a new frame. |
void |
StoreFrame(RawFrame frame)
This method correspond to the StoreFrame action in the S anchor. |
void |
updateState()
This method records the current positions of all aircrafts in the
shared state variable of type StateTable. |
Methods inherited from class javax.safetycritical.PeriodicEventHandler |
register |
Methods inherited from class javax.safetycritical.ManagedEventHandler |
cleanup, getName |
Methods inherited from class javax.safetycritical.AsyncEventHandler |
handleAsyncEvent |
Methods inherited from class javax.safetycritical.AbstractAsyncEventHandler |
run |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Methods inherited from interface java.lang.Runnable |
run |
mission
public final CDxMission mission
- The current mission
reduce
public final javax.safetycritical.AperiodicEvent reduce
- The event to release ReducerHandler
InputFrameHandler
public InputFrameHandler(CDxMission mission,
javax.safetycritical.AperiodicEvent event)
- Constructor
- Parameters:
mission
- the current missionevent
- the event to release ReducerHandler
handleEvent
public void handleEvent()
- Major method of a handler: store the previous frame to `state'
and get a new frame. Finally it releases the ReducerHandler.
StoreFrame
public void StoreFrame(RawFrame frame)
- This method correspond to the StoreFrame action in the S anchor.
- Parameters:
frame
- the new frame
updateState
public void updateState()
- This method records the current positions of all aircrafts in the
shared state variable of type StateTable.