Package org.insa.graphs.gui.observers
Class ShortestPathGraphicObserver
- java.lang.Object
-
- org.insa.graphs.gui.observers.ShortestPathGraphicObserver
-
- All Implemented Interfaces:
ShortestPathObserver
public class ShortestPathGraphicObserver extends java.lang.Object implements ShortestPathObserver
-
-
Field Summary
Fields Modifier and Type Field Description protected Drawingdrawingprotected PointSetOverlaypsOverlay1protected PointSetOverlaypsOverlay2
-
Constructor Summary
Constructors Constructor Description ShortestPathGraphicObserver(Drawing drawing)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description voidnotifyDestinationReached(Node node)Notify the observer that the destination has been reached.voidnotifyNodeMarked(Node node)Notify the observer that a node has been marked, i.e.voidnotifyNodeReached(Node node)Notify the observer that a node has been reached for the first time.voidnotifyOriginProcessed(Node node)Notify the observer that the origin has been processed.
-
-
-
Field Detail
-
drawing
protected Drawing drawing
-
psOverlay1
protected PointSetOverlay psOverlay1
-
psOverlay2
protected PointSetOverlay psOverlay2
-
-
Constructor Detail
-
ShortestPathGraphicObserver
public ShortestPathGraphicObserver(Drawing drawing)
-
-
Method Detail
-
notifyOriginProcessed
public void notifyOriginProcessed(Node node)
Description copied from interface:ShortestPathObserverNotify the observer that the origin has been processed.- Specified by:
notifyOriginProcessedin interfaceShortestPathObserver- Parameters:
node- Origin.
-
notifyNodeReached
public void notifyNodeReached(Node node)
Description copied from interface:ShortestPathObserverNotify the observer that a node has been reached for the first time.- Specified by:
notifyNodeReachedin interfaceShortestPathObserver- Parameters:
node- Node that has been reached.
-
notifyNodeMarked
public void notifyNodeMarked(Node node)
Description copied from interface:ShortestPathObserverNotify the observer that a node has been marked, i.e. its final value has been set.- Specified by:
notifyNodeMarkedin interfaceShortestPathObserver- Parameters:
node- Node that has been marked.
-
notifyDestinationReached
public void notifyDestinationReached(Node node)
Description copied from interface:ShortestPathObserverNotify the observer that the destination has been reached.- Specified by:
notifyDestinationReachedin interfaceShortestPathObserver- Parameters:
node- Destination.
-
-