Home » openjdk-7 » java » sql » [javadoc | source]
java.sql
public class: Time [javadoc | source]
java.lang.Object
   java.util.Date
      java.sql.Time

All Implemented Interfaces:
    Comparable, Cloneable, Serializable

A thin wrapper around the java.util.Date class that allows the JDBC API to identify this as an SQL TIME value. The Time class adds formatting and parsing operations to support the JDBC escape syntax for time values.

The date components should be set to the "zero epoch" value of January 1, 1970 and should not be accessed.
Field Summary
static final  long serialVersionUID    Private serial version unique ID to ensure serialization compatibility. 
Constructor:
 public Time(long time) 
 public Time(int hour,
    int minute,
    int second) 
Method from java.sql.Time Summary:
getDate,   getDay,   getMonth,   getYear,   setDate,   setMonth,   setTime,   setYear,   toString,   valueOf
Methods from java.util.Date:
UTC,   after,   before,   clone,   compareTo,   equals,   getDate,   getDay,   getHours,   getMillisOf,   getMinutes,   getMonth,   getSeconds,   getTime,   getTimezoneOffset,   getYear,   hashCode,   parse,   setDate,   setHours,   setMinutes,   setMonth,   setSeconds,   setTime,   setYear,   toGMTString,   toLocaleString,   toString
Methods from java.lang.Object:
clone,   equals,   finalize,   getClass,   hashCode,   notify,   notifyAll,   toString,   wait,   wait,   wait
Method from java.sql.Time Detail:
 public int getDate() 
Deprecated!
    This method is deprecated and should not be used because SQL TIME values do not have a date component.
 public int getDay() 
Deprecated!
    This method is deprecated and should not be used because SQL TIME values do not have a day component.
 public int getMonth() 
Deprecated!
    This method is deprecated and should not be used because SQL TIME values do not have a month component.
 public int getYear() 
Deprecated!
    This method is deprecated and should not be used because SQL TIME values do not have a year component.
 public  void setDate(int i) 
Deprecated!
    This method is deprecated and should not be used because SQL TIME values do not have a date component.
 public  void setMonth(int i) 
Deprecated!
    This method is deprecated and should not be used because SQL TIME values do not have a month component.
 public  void setTime(long time) 
    Sets a Time object using a milliseconds time value.
 public  void setYear(int i) 
Deprecated!
    This method is deprecated and should not be used because SQL TIME values do not have a year component.
 public String toString() 
    Formats a time in JDBC time escape format.
 public static Time valueOf(String s) 
    Converts a string in JDBC time escape format to a Time value.