Class Month
Class Month
java.lang.Object
|
+----Month
- public class Month
- extends Object
Month is a generic object for keeping the month.
-
month
- The month.
-
year
- The year.
-
Month(int, int)
- Creates a new Month from the specified month and year.
-
Month(Day)
- Creates a new Month object from the given Day
-
Month()
- Creates a new, empty Month object.
-
equals(Object)
- Compares this Month to the specified Object.
-
hashCode()
- Returns the hashing code for this month.
-
toString()
- Returns a new String representing the month.
month
public int month
- The month.
year
public int year
- The year.
Month
public Month(int m,
int y)
- Creates a new Month from the specified month and year.
- Parameters:
- m - the month
- y - the year
Month
public Month(Day d)
- Creates a new Month object from the given Day
- Parameters:
- d - the Day object to create the Month for
- See Also:
- Day
Month
public Month()
- Creates a new, empty Month object.
toString
public String toString()
- Returns a new String representing the month.
- Overrides:
- toString in class Object
hashCode
public int hashCode()
- Returns the hashing code for this month.
- Overrides:
- hashCode in class Object
- See Also:
- Hashtable
equals
public boolean equals(Object o)
- Compares this Month to the specified Object.
Returns true if the Object is equal to this Month; that is,
has the same month and year.
- Parameters:
- o - the object to compare this Month against.
- Returns:
- true if the Months are equal; false otherwise.
- Overrides:
- equals in class Object