public class Time
extends java.lang.Object
Constructor and Description |
---|
Time(Time t)
Creates a new time representing the same time as t.
|
Modifier and Type | Method and Description |
---|---|
Time |
add(Duration increment)
Returns a new Time representing
this + increment . |
int |
compareTo(Time t) |
static Time |
now()
Returns the current system time.
|
Duration |
sub(Time t)
Returns a new Duration representing
this - t . |
java.lang.String |
toString() |
public Time(Time t)