July 1999
Intermediate to advanced
502 pages
19h 52m
English
Time
Class Name: java.sql.Time |
Superclass: java.util.Date |
| Immediate Subclasses: None |
| Interfaces Implemented: None |
| Availability: JDK 1.1 |
This version of the java.util.Date class maps to an SQL TIME datatype.
public class Time extends java.util.Date {
static public Time valueOf(String s);
public Time(int hour, int minute, int second);
public Time(long time);
#public int getDate();
#public int getDay();
#public int getMonth();
#public int getYear();
#public int setDate(int i);
#public int setMonth(int i);
public void setTime(long time);
#public void setYear(int i);
public String toString();
}public Timestamp(int hour, int minute, intsecond) public Timestamp(long time)
Description: Constructs a new
Time object. The first prototype constructs a
Time for the hour, minute, and seconds specified.
The second constructs one based on the number of seconds since
12:00:00 January 1, 1970 GMT.
#public int getDate() #public int getDay() #public int getMonth() #public int getYear() #public int setDate(int i) #public int setMonth(int i) #public void setYear(int i)
Description: These attributes represent the
individual segments of a Time object.
public void setTime(long time)
Description: This method sets the
Time object to the specified time as the number of
seconds since 12:00:00 January 1, 1970 GMT.
public String toString() ...
Read now
Unlock full access