public class
TimeAndDistance
extends Object
A TimeAndDistance is an immutable class which represents both time and distance to a destination.
Nested Class Summary
@interface | TimeAndDistance.DelaySeverity | Indicates how heavy traffic is. |
Constant Summary
int | DELAY_HEAVY | |
int | DELAY_LIGHT | |
int | DELAY_MEDIUM | |
int | DELAY_NODATA |
Public Constructor Summary
TimeAndDistance(int seconds, int meters)
|
|
TimeAndDistance(int seconds, int meters, int delaySeverity)
|
Public Method Summary
int | |
int | |
int |
Inherited Method Summary
boolean |
equals(Object arg0)
|
final Class<?> |
getClass()
|
int |
hashCode()
|
final void |
notify()
|
final void |
notifyAll()
|
String |
toString()
|
final void |
wait(long arg0, int arg1)
|
final void |
wait(long arg0)
|
final void |
wait()
|
Constants
public static final int DELAY_HEAVY
Constant Value:
1
public static final int DELAY_LIGHT
Constant Value:
3
public static final int DELAY_MEDIUM
Constant Value:
2
public static final int DELAY_NODATA
Constant Value:
0
Public Constructors
public TimeAndDistance (int seconds, int meters)
Parameters
seconds | |
---|---|
meters |
public TimeAndDistance (int seconds, int meters, int delaySeverity)
Parameters
seconds | |
---|---|
meters | |
delaySeverity |