public class Date extends Object
Constructor and Description |
---|
Date()
Allocates a Date object and initializes it to represent the current time specified number of milliseconds since the standard base time known as "the epoch", namely January 1, 1970, 00:00:00 GMT.
|
Date(long date)
Allocates a Date object and initializes it to represent the specified number of milliseconds since the standard base time known as "the epoch", namely January 1, 1970, 00:00:00 GMT.
|
Modifier and Type | Method and Description |
---|---|
boolean |
equals(Object obj)
Compares two dates for equality.
|
long |
getTime()
Returns the number of milliseconds since January 1, 1970, 00:00:00 GMT represented by this Date object.
|
int |
hashCode()
Returns a hash code value for this object.
|
void |
setTime(long time)
Sets this Date object to represent a point in time that is time milliseconds after January 1, 1970 00:00:00 GMT.
|
String |
toString()
Converts this Date object to a String of the form: dow mon dd hh:mm:ss zzz yyyy where: dow is the day of the week (Sun, Mon, Tue, Wed, Thu, Fri, Sat).
|
public Date()
public Date(long date)
public boolean equals(Object obj)
public long getTime()
public int hashCode()
public void setTime(long time)
public String toString()