Oracle Fusion Middleware Java API Reference for Oracle ADF Mobile Client
11g Release 1 (11.1.1)

E17503-02

oracle.adfnmc.java.sql
Class Date

java.lang.Object
  extended by java.util.Date
      extended by oracle.adfnmc.java.sql.BaseDate
          extended by oracle.adfnmc.java.sql.Date
All Implemented Interfaces:
Comparable

public class Date
extends BaseDate

A Date class which can consume and produce dates in SQL Date format.

The SQL date format represents a date as yyyy-mm-dd. Note that this date format only deals with year, month and day values. There are no values for hours, minutes, seconds.

This contrasts with regular java.util.Date values, which include time values for hours, minutes, seconds, milliseconds.

Time points are handled as millisecond values - milliseconds since the epoch, January 1st 1970, 00:00:00.000 GMT. Time values passed to the java.sql.Date class are "normalized" to the time 00:00:00.000 GMT on the date implied by the time value.


Field Summary
static java.lang.Class CLASS_INSTANCE
           
static java.lang.String CLASS_INSTANCE_NAME
           
 
Constructor Summary
Date(long theDate)
          Creates a Date which corresponds to the day implied by the supplied theDate milliseconds time value.
 
Method Summary
 int getHours()
          Deprecated. This method is deprecated and must not be used. SQL Date values do not have an hours component.
 int getMinutes()
          Deprecated. This method is deprecated and must not be used. SQL Date values do not have a minutes component.
 int getSeconds()
          Deprecated. This method is deprecated and must not be used. SQL Date values do not have a seconds component.
 void setHours(int theHours)
          Deprecated. This method is deprecated and must not be used. SQL Date values do not have an hours component.
 void setMinutes(int theMinutes)
          Deprecated. This method is deprecated and must not be used. SQL Date values do not have a minutes component.
 void setSeconds(int theSeconds)
          Deprecated. This method is deprecated and must not be used. SQL Date values do not have a seconds component.
static Date valueOf(java.lang.String dateString)
           
 
Methods inherited from class oracle.adfnmc.java.sql.BaseDate
compare, compareTo, parseDate, setTime, toString, valueOfInternal
 
Methods inherited from class java.util.Date
equals, getTime, hashCode
 
Methods inherited from class java.lang.Object
getClass, notify, notifyAll, wait, wait, wait
 

Field Detail

CLASS_INSTANCE

public static final java.lang.Class CLASS_INSTANCE

CLASS_INSTANCE_NAME

public static final java.lang.String CLASS_INSTANCE_NAME
Constructor Detail

Date

public Date(long theDate)
Creates a Date which corresponds to the day implied by the supplied theDate milliseconds time value.

Parameters:
theDate - - a time value in milliseconds since the epoch - January 1 1970 00:00:00 GMT. The time value (hours, minutes, seconds, milliseconds) stored in the Date object is adjusted to correspond to 00:00:00 GMT on the day implied by the supplied time value.
Method Detail

valueOf

public static Date valueOf(java.lang.String dateString)

getHours

public int getHours()
Deprecated. This method is deprecated and must not be used. SQL Date values do not have an hours component.

Returns:
does not return
Throws:
java.lang.IllegalArgumentException - if this method is called

getMinutes

public int getMinutes()
Deprecated. This method is deprecated and must not be used. SQL Date values do not have a minutes component.

Returns:
does not return
Throws:
java.lang.IllegalArgumentException - if this method is called

getSeconds

public int getSeconds()
Deprecated. This method is deprecated and must not be used. SQL Date values do not have a seconds component.

Returns:
does not return
Throws:
java.lang.IllegalArgumentException - if this method is called

setHours

public void setHours(int theHours)
Deprecated. This method is deprecated and must not be used. SQL Date values do not have an hours component.

Parameters:
theHours - the number of hours to set
Throws:
java.lang.IllegalArgumentException - if this method is called

setMinutes

public void setMinutes(int theMinutes)
Deprecated. This method is deprecated and must not be used. SQL Date values do not have a minutes component.

Parameters:
theMinutes - the number of minutes to set
Throws:
java.lang.IllegalArgumentException - if this method is called

setSeconds

public void setSeconds(int theSeconds)
Deprecated. This method is deprecated and must not be used. SQL Date values do not have a seconds component.

Parameters:
theSeconds - the number of seconds to set
Throws:
java.lang.IllegalArgumentException - if this method is called

Oracle Fusion Middleware Java API Reference for Oracle ADF Mobile Client
11g Release 1 (11.1.1)

E17503-02

Copyright © 2011, Oracle and/or its affiliates. All rights reserved.