org.salespointframework.core
Class Date

java.lang.Object
  extended by org.salespointframework.core.Date
All Implemented Interfaces:
Time

Deprecated. As this class is not Y2K safe, it is of no use any more. Use CalendarTime instead.

@Deprecated
public class Date
extends java.lang.Object
implements Time

This class is an implementation of the Time interface.

The time is represented in the form of a simple date. The format is "dd.mm.yy".

Note: This is a very simple implementation and it is not Y2K safe!

Since:
v2.0
Version:
2.0 15/06/1999
Author:
Sven Matznick

Field Summary
private  boolean m_fSpecialYear
          Deprecated. Is this a special year?
private  java.lang.String m_sDate
          Deprecated. The current date.
private  java.lang.String m_sDefaultInterval
          Deprecated. The default interval for Dates.
 
Constructor Summary
Date()
          Deprecated. Creates a new date with standard starting time "01.01.00".
Date(java.lang.String sNewDate)
          Deprecated. Creates a new date with the given starting time.
 
Method Summary
 java.util.Date getDateValue()
          Deprecated. Convert the date to a Date object.
 java.lang.Object getDefaultInterval()
          Deprecated. Get the default time interval.
 java.lang.Object getTime()
          Deprecated. Get the current date.
 java.lang.Comparable<java.lang.String> getTimeStamp(long lStampNumber)
          Deprecated. Create and return a time stamp.
 void goAhead(java.lang.Object oInterval)
          Deprecated. Increment the time by the given time interval.
 void setTime(java.lang.Object oTime)
          Deprecated. Set the given date.
 java.lang.String toString()
          Deprecated. Returns the current date.
private  void validate(java.lang.Object oToValidate)
          Deprecated. Validate a given String, i.e. check it represents a date.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Field Detail

m_sDate

private java.lang.String m_sDate
Deprecated. 
The current date.


m_sDefaultInterval

private java.lang.String m_sDefaultInterval
Deprecated. 
The default interval for Dates.


m_fSpecialYear

private boolean m_fSpecialYear
Deprecated. 
Is this a special year?

Constructor Detail

Date

public Date()
Deprecated. 
Creates a new date with standard starting time "01.01.00".


Date

public Date(java.lang.String sNewDate)
     throws java.lang.IllegalArgumentException
Deprecated. 
Creates a new date with the given starting time.

Parameters:
sNewDate - a String representing the date to be set, format: dd.mm.yy (day.month.year)
Throws:
java.lang.IllegalArgumentException - if the given String has an invalid format
Method Detail

setTime

public void setTime(java.lang.Object oTime)
             throws java.lang.IllegalArgumentException
Deprecated. 
Set the given date.

Specified by:
setTime in interface Time
Parameters:
oTime - a String representing the date to be set, format: dd.mm.yy (day.month.year)
Throws:
java.lang.IllegalArgumentException - if the given String has an invalid format

getTime

public java.lang.Object getTime()
Deprecated. 
Get the current date.

Specified by:
getTime in interface Time
Returns:
a String representing the current date

goAhead

public void goAhead(java.lang.Object oInterval)
             throws java.lang.IllegalArgumentException
Deprecated. 
Increment the time by the given time interval.

Specified by:
goAhead in interface Time
Parameters:
oInterval - the interval to increment time. Must be a String that gives the number of days by which to increment.
Throws:
java.lang.IllegalArgumentException - if the given interval is no String or cannot be transformed into a long value.

getDefaultInterval

public java.lang.Object getDefaultInterval()
Deprecated. 
Get the default time interval.

Specified by:
getDefaultInterval in interface Time
Returns:
a String describing the default time step in days (standard: "1").

getTimeStamp

public java.lang.Comparable<java.lang.String> getTimeStamp(long lStampNumber)
Deprecated. 
Create and return a time stamp.

Specified by:
getTimeStamp in interface Time
Parameters:
lStampNumber - the number of the stamp
Returns:
a fresh time stamp.

toString

public java.lang.String toString()
Deprecated. 
Returns the current date.

Overrides:
toString in class java.lang.Object
Returns:
a String describing the current date

validate

private void validate(java.lang.Object oToValidate)
               throws java.lang.IllegalArgumentException
Deprecated. 
Validate a given String, i.e. check it represents a date.

Throws:
java.lang.IllegalArgumentException

getDateValue

public java.util.Date getDateValue()
Deprecated. 
Convert the date to a Date object. Note: As the entire org.salespointframework.sale.Date class is not Y2K compliant, this method also is not.

Returns:
The converted date.
Since:
v2.0 (06/07/2000)