|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object | +--TransitBusSymbol
This class holds all the parts of a symbol that represents a bus on a map.
Constructor Summary | |
TransitBusSymbol(hw7.TransitBusEvent evt)
Create a new TransitBusSymbol. |
Method Summary | |
void |
addTo(uwcse.graphics.GWindow gw)
Add this symbol to the given GWindow. |
void |
doClickAction()
This method is called whenever this Prop is clicked on. |
boolean |
intersects(uwcse.graphics.Shape other)
Decide if the other Shape intersects this symbol. |
void |
removeFromWindow()
Remove this symbol from the GWindow it was added to earlier. |
void |
setVehicleLocation(TransitMap m,
double lat,
double lon)
Set the Location of the LocatedVehicle we are tracking, based on new latitude and longitude values. |
java.lang.String |
toString()
Provide a String representing this symbol. |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
Constructor Detail |
public TransitBusSymbol(hw7.TransitBusEvent evt)
Method Detail |
public void setVehicleLocation(TransitMap m, double lat, double lon)
m
- the TransitMap that we are being displayed on. Supplies
the pixelX and pixelY methods that convert coordinates.lat
- the new latitude to uselon
- the new longitude to use.public void addTo(uwcse.graphics.GWindow gw)
addTo
in interface uwcse.animation.Prop
gw
- the GWindow to add ourselves topublic void removeFromWindow()
removeFromWindow
in interface uwcse.animation.Prop
public boolean intersects(uwcse.graphics.Shape other)
intersects
in interface hw7.ClickableProp
other
- the other Shape that we might intersect with
public void doClickAction()
doClickAction
in interface hw7.ClickableProp
public java.lang.String toString()
toString
in class java.lang.Object
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |