Class NotProcessingApp
java.lang.Object
org.eclipse.mosaic.fed.application.app.AbstractApplication<VehicleOperatingSystem>
org.eclipse.mosaic.app.tutorial.interappcommunication.NotProcessingApp
- All Implemented Interfaces:
Application,OperatingSystemAccess<VehicleOperatingSystem>,VehicleApplication,EventProcessor
public class NotProcessingApp
extends AbstractApplication<VehicleOperatingSystem>
implements VehicleApplication
This application is used only as an addition to the InterconnectApp.
It doesn't implement processEvent method,
thus not being able to receive the message that is sent from InterconnectApp.
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionvoidThe operating system calls this method to notify that the application is going to be torn down.voidThe operating system calls this method to notify that the application is started.voidonVehicleUpdated(VehicleData previousVehicleData, VehicleData updatedVehicleData) Is called when ever the vehicle has moved.voidprocessEvent(Event event) Processes the given event.Methods inherited from class org.eclipse.mosaic.fed.application.app.AbstractApplication
canProcessEvent, getLog, getOperatingSystem, getRandom, isTornDown, isValidStateAndLog, setUp, tearDownMethods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitMethods inherited from interface org.eclipse.mosaic.lib.util.scheduling.EventProcessor
canProcessEventMethods inherited from interface org.eclipse.mosaic.fed.application.app.api.OperatingSystemAccess
getOs
-
Constructor Details
-
NotProcessingApp
public NotProcessingApp()
-
-
Method Details
-
processEvent
Description copied from interface:EventProcessorProcesses the given event.- Specified by:
processEventin interfaceEventProcessor- Parameters:
event- the event to process
-
onStartup
public void onStartup()Description copied from interface:ApplicationThe operating system calls this method to notify that the application is started.- Specified by:
onStartupin interfaceApplication
-
onShutdown
public void onShutdown()Description copied from interface:ApplicationThe operating system calls this method to notify that the application is going to be torn down.- Specified by:
onShutdownin interfaceApplication
-
onVehicleUpdated
public void onVehicleUpdated(@Nullable VehicleData previousVehicleData, @Nonnull VehicleData updatedVehicleData) Description copied from interface:VehicleApplicationIs called when ever the vehicle has moved. That is, if theVehicleDataof the unit has been updated.- Specified by:
onVehicleUpdatedin interfaceVehicleApplication- Parameters:
previousVehicleData- the previous state of the vehicleupdatedVehicleData- the updated state of the vehicle
-