Package simulation
Class DrawTask
java.lang.Object
javafx.animation.AnimationTimer
simulation.DrawTask
public class DrawTask
extends javafx.animation.AnimationTimer
Specifies actions required for a simulation to be drawn and ran properly.
-
Constructor Summary
Constructors Constructor Description DrawTask(javafx.scene.canvas.GraphicsContext gc, Population population, java.util.ArrayList<Obstacle> obstacles)
-
Method Summary
Modifier and Type Method Description void
handle(long l)
Function required by javafx.animation.AnimationTimer containing actions ran every frame.
-
Constructor Details
-
DrawTask
public DrawTask(javafx.scene.canvas.GraphicsContext gc, Population population, java.util.ArrayList<Obstacle> obstacles)
-
-
Method Details
-
handle
public void handle(long l)Function required by javafx.animation.AnimationTimer containing actions ran every frame.- Specified by:
handle
in classjavafx.animation.AnimationTimer
- Parameters:
l
- The timestamp of the current frame given in nanoseconds.
-