Overview
For this project you will implement a basic linked list.
Notice that no public tests are part of this project as all tests are either
release or secret. You must implement this project by yourself.
Objectives
This project will allow you practice linked lists and testing.
Grading
- (35%) Release Tests
- (55%) Secret Tests
- (10%) Style
Code Distribution
The project's code distribution provides you with the following:
- listClasses package → Where the class implementing the linked list will appear.
- tests package → Where you should place your student tests.
Specifications
- You are expected to implement one class: BasicLinkedList. The javadoc describing
what you need to implement can be found at
Project Javadoc.
-
The linked list in our project has a head and tail reference.
The next link of the last node points to null.
-
Methods addToEnd(), getLast(), retrieveLastElement() rely on
(and must use) the tail reference.
-
The head and tail must be set correctly when operations
update the list.
-
Your code must be efficient. For example, you will lose credit if
you perform an unnecessary list traversal(s) during the implementation
of a method.
-
If you see in the submit server the error "missing_component", the problem is usually that you
are missing a required class. You can also get this error if you are not defining a generic
class correctly.
It is recommended that you try submitting your project frequently (if you have not done
so yet) so you can identify this problem, if it exists.
Requirements
- You may not use recursion in this project.
- For this project you are not required to write student tests, but you are strongly
encouraged to do so. If you have a problem with your code and need assistance during
office hours, you need to have a student test(s) that illustrates the problem you are
experiencing.
-
The iterator you are required to define
may NOT be used to implement any of the other list operations (e.g., add).
-
You need to implement a singly-linked list that relies on a head and tail reference. Making
use of the Java collections framework or implementing the list in some other way will result
in a grade of 0. (In particular, you may not use arrays,
you may not ArrayList or any other Java collection, and you may not implement a doubly-linked list.)