Question: In Java Im trying to create a planner instanitated to a list of course objects with a no argument constructor, but Im confused how to

In Java Im trying to create a planner instanitated to a list of course objects with a no argument constructor, but Im confused how to do it, I have to follow an abstract data type and I have no idea where to go from here. How do I change what I have so far to follow this ADT. I am not allowed to use array lists.
 In Java Im trying to create a planner instanitated to a
list of course objects with a no argument constructor, but Im confused

public class Planner The Planner class implements an abstract data type for a list of courses supporting some common operations public Planner Constructs an instance of the Planner with no Course objects in it. Postcondition: This Planner has been initialized to an empty list of Courses. public int size ) Determines the number of courses currently in the list. Preconditions: This Planner has been instatiated. Returns: The number of Courses in this Planner. ,public void addCourse (Course newcourse, int position) Parameters: newCourse the new course to add to the list position - the position (preference) of this course on the list Preconditions: This Course object has been instantiated and 1sposition s items currently in list +1. The nun MAX COURSES Postconditions: The new Course is now listed in the correct preference on the list. All Courses that were originally (e.g. If there are 5 Courses in a Planner, positioned 1-5, and you insert a Course in position 4, the n position 4 will be moved to position 5, and the Course that was in position 5 will be moved to positi Throws: IllegalArgumentException Indicates that position is not within the valid range. FullPlannerExpcetion Indicates that there is no more room in the Planner to record an additional Course. Note 1: position refers to the position in the Planner and not the position in the array. Note 2: Inserting an item in position (items currently_in list+1) is effectively the same as adding the ite

Step by Step Solution

There are 3 Steps involved in it

1 Expert Approved Answer
Step: 1 Unlock blur-text-image
Question Has Been Solved by an Expert!

Get step-by-step solutions from verified subject matter experts

Step: 2 Unlock
Step: 3 Unlock

Students Have Also Explored These Related Databases Questions!