class Date // Class Declaration (Date.h) { private: // Begin with private member variables int day; int month; // Internal representation int year; // (hidden from class users) public: // this is the public interface // that users will use to create Date objects // Constructors Date(); Date( int m, int d, int y ); // Mutator functions -- change the object void setDay( int d ); void setMonth( int m ); void setYear( int y ); void increment(); // add one day void decrement(); // subtract one day // Accessor functions (often defined using const) int getDay() const; int getMonth() const; // <== const means member variables int getYear() const; // will not be changed bool isEqual( const Date &date2 ) const; // same day, month, year? // bool isSameDayAndMonth( const Date& date2 ) const; bool isLeapYear() const; bool isLastDayInMonth() const; int lastDayInMonth() const; void print() const; // void add_days( int days ); // e.g. mutator functioN Date operator+ ( int days ) const; // e.g. Date d2 = d1 + 40; // Date d3 = d1 + 50 + 60; // postfix // void operator++ ( int dummy ); Date operator++ ( int dummy ); // prefix Date& operator++ (); }; bool sameDayAndMonth( const Date &date1, const Date &date2 ); bool isLessThan( const Date& date1, const Date& date2 ); bool operator< ( const Date& date1, const Date& date2 ); ostream& operator<< ( ostream& os, const Date& d ); Date operator- ( const Date& d1, int days ); bool operator== ( const Date& d1, const Date& d2 );