Create the following class in C++
Create a new class call Date. Date will contain the
date stored as day of the month, month and the year. Provide
appropriate set and get methods for the class. Use doxygen comments
to document Date.h (Date specification).
Think about how the class will be used. Modify the input data file
to cater for dates. The date in the data file refers to when the
mark for the unit was obtained. Unit test the date class.
Result will now contain a date. The output* operator for Result
should output the unit information, the marks and the date these
marks were obtained. The output for registration in the output data
file will contain the Student ID, Semester, unit information, date
and marks for each unit. The output should be in a similar format
as the output in the previous exercise except it will have the date
information as well and there will be no “_” in the unit name. A
sample run is shown at the end.
*“Output” does not mean that the object will drag out the internal
data of nested objects. The nested objects will be asked to output
themselves. The containers do not micro-manage the details of
nested objects. Micro-managing creates dependencies and increases
coupling.
Ignore doxygen style comments
Program :
Output :
Get Answers For Free
Most questions answered within 1 hours.