All Packages Class Hierarchy This Package Previous Next Index
Class rebelsky.util.SimpleDate
java.lang.Object
|
+----java.util.Calendar
|
+----java.util.GregorianCalendar
|
+----rebelsky.util.SimpleDate
- public class SimpleDate
- extends GregorianCalendar
A simple form of dates. Provides a way to work with dates without
worrying about the details that accompany Java's Calendar and Date
classes. Probably violates the elegant design those classes were
intended to provide.
Copyright (c) 1998 Samuel A. Rebelsky. All rights reserved.
- Version:
- 1.0 of January 1998
- Author:
- Samuel A. Rebelsky
Constructor Index
- o
SimpleDate(Date)
- Create a new SimpleDate based on a Java date.
Method Index
- o
after(SimpleDate)
- Determine if the current SimpleDate is after another SimpleDate.
- o
before(SimpleDate)
- Determine if the current SimpleDate is before another SimpleDate.
- o
equals(Object)
- Compare the current SimpleDate to another object.
- o
equals(SimpleDate)
- Compare two SimpleDates.
- o
toString()
- Convert the date to a string.
Constructors
o
SimpleDate
public SimpleDate(Date date)
- Create a new SimpleDate based on a Java date.
Methods
o
equals
public boolean equals(SimpleDate other)
- Compare two SimpleDates. A more specific version of
GregorianCalendar.equals().
o
equals
public boolean equals(Object other)
- Compare the current SimpleDate to another object. Overrides
GregorianCalendar.equals(). Behaves like that method except
when the parameter is a SimpleDate.
- Overrides:
- equals in class GregorianCalendar
o
before
public boolean before(SimpleDate other)
- Determine if the current SimpleDate is before another SimpleDate.
o
after
public boolean after(SimpleDate other)
- Determine if the current SimpleDate is after another SimpleDate.
o
toString
public String toString()
- Convert the date to a string.
- Overrides:
- toString in class Object
All Packages Class Hierarchy This Package Previous Next Index