public class Date extends java.util.Date implements SCODate
Date,
Serialized Form| Constructor and Description |
|---|
Date()
Creates a
Date object that represents the time at which
it was allocated. |
Date(long date)
Creates a
Date object that represents the given time
in milliseconds. |
| Modifier and Type | Method and Description |
|---|---|
java.lang.Object |
clone()
Creates and returns a copy of this object.
|
java.lang.String |
getFieldName()
Returns the field name
|
java.lang.Object |
getOwner()
Returns the owner object of the SCO instance
|
void |
setDate(int date)
Deprecated.
As of JDK version 1.1,
replaced by
Calendar.set(Calendar.DAY_OF_MONTH, int date). |
void |
setHours(int hours)
Deprecated.
As of JDK version 1.1,
replaced by
Calendar.set(Calendar.HOUR_OF_DAY, int hours). |
void |
setMinutes(int minutes)
Deprecated.
As of JDK version 1.1,
replaced by
Calendar.set(Calendar.MINUTE, int minutes). |
void |
setMonth(int month)
Deprecated.
As of JDK version 1.1,
replaced by
Calendar.set(Calendar.MONTH, int month). |
void |
setOwner(java.lang.Object owner,
int fieldNumber)
Sets the owner and field number.
|
void |
setSeconds(int seconds)
Deprecated.
As of JDK version 1.1,
replaced by
Calendar.set(Calendar.SECOND, int seconds). |
void |
setTime(long time)
Sets the Date object to represent a point in time that is
time milliseconds after January 1, 1970 00:00:00 GMT.
|
void |
setTimeInternal(long time)
Sets the Date object without notification of the Owner
field.
|
void |
setYear(int year)
Deprecated.
As of JDK version 1.1,
replaced by
Calendar.set(Calendar.YEAR, year + 1900). |
void |
unsetOwner(java.lang.Object owner,
int fieldNumber)
Nullifies references to the owner Object iff the passed in owner and
fieldNumber match.
|
public Date()
Date object that represents the time at which
it was allocated.public Date(long date)
Date object that represents the given time
in milliseconds.date - the number of millisecondspublic void setTime(long time)
setTime in class java.util.Datetime - the number of milliseconds.Datepublic java.lang.Object clone()
Mutable Second Class Objects are required to provide a public clone method in order to allow for copying PersistenceCapable objects. In contrast to Object.clone(), this method must not throw a CloneNotSupportedException.
public void setYear(int year)
Calendar.set(Calendar.YEAR, year + 1900).setYear in class java.util.Dateyear - the year value.Calendar,
Datepublic void setMonth(int month)
Calendar.set(Calendar.MONTH, int month).setMonth in class java.util.Datemonth - the month value between 0-11.Calendar,
Datepublic void setDate(int date)
Calendar.set(Calendar.DAY_OF_MONTH, int date).setDate in class java.util.Datedate - the day of the month value between 1-31.Calendar,
Datepublic void setHours(int hours)
Calendar.set(Calendar.HOUR_OF_DAY, int hours).setHours in class java.util.Datehours - the hour value.Calendar,
Datepublic void setMinutes(int minutes)
Calendar.set(Calendar.MINUTE, int minutes).setMinutes in class java.util.Dateminutes - the value of the minutes.Calendar,
Datepublic void setSeconds(int seconds)
Calendar.set(Calendar.SECOND, int seconds).setSeconds in class java.util.Dateseconds - the seconds value.Calendar,
Datepublic void setTimeInternal(long time)
setTimeInternal in interface SCODatetime - the number of milliseconds.Datepublic void unsetOwner(java.lang.Object owner,
int fieldNumber)
SCOunsetOwner in interface SCOowner - the existing owner object.fieldNumber - the existing number of the field.SCO.unsetOwner(Object owner, int fieldNumber)public void setOwner(java.lang.Object owner,
int fieldNumber)
SCOsetOwner in interface SCOowner - the owner object.fieldNumber - the number of the field associated with this instance.(Object owner, int fieldNumber)public java.lang.Object getOwner()
SCOpublic java.lang.String getFieldName()
SCOgetFieldName in interface SCO()Copyright © 2005-2012 Apache Software Foundation. All Rights Reserved.