addToList(Task* t)
points to the address and I am unable to think of a way to dereference that pointer so I can get the data. TaskList is a underlying data structure that I will use for another class to implement completed and incomplete tasks. My logic behind TaskList
is by making a vector of Task
pointers point to the address of the Task created. Then I can iterate through the vector to output the data stored in the address. Later on, in another class, I will implement 2 TaskList objects incomplete
and completed
and be able to use TaskList functions to remove tasks from complete / incomplete, have the data stored in incomplete.at(index)
point to completed
, store the data and then remove the data at incomplete
.
|
|
|
|
|
|
|
|
TaskList
and call it
|
|
SortedVector
of type Task*
and return the data. So would the copy constructor allow me to store the data into each element of the vector?
|
|
SortedVector
that uses vector
as the underlying data structure. It has it own functionality, such as inserting the data into the vector based on deadline date.Task
and 3 derived classes ShoppingTask
, EventTask
& Homework
. My TaskList
would be an underlying data structure for another class that has to deal with 2 TaskList objects complete
& incomplete
, where I would be able to call the functions of TaskList to manipulate the two lists. An example would be removing an element on outstanding. I would use outstanding.removeFromList(2)
, would remove the element at index 1. My command outstanding.addToList(anEventTask)
would return the address of the task, but would not display the actual data of the of that address. I was originally thinking about using lists as my original design proposal, but due to time constraints i opt to use vectors since I am more familiar with it than linked list. After the project, I plan on rewriting the code using lists to familiar myself with the list data structure. My program will not have any error checking, for I can assume the user would input correct values.