Starting from:

$25

CSCI1302 - Programming Project 4 - Simple Linked List and Maven - Solved

The amount of time to complete this project is not very long, so you should start working on it right away. 

In this project, you will complete a partial implementation of the SimpleLinkedList<E> generic class

(the partial implementation will be provided) and also implement a suitable JUnit-based test class SimpleLinkedListTest for your completed SimpleLinkedList<E> class.  Furthermore, you will provide the JavaDoc documentation for your SimpleLinkedList class.

You will have to read and fully understand the partial implementation provided to you.

The whole project must be organized using Apache Maven, which is a popular build tool for Java.  I will provide additional explanations in a separate document.

You must compile, test your project using maven commands.  You must also create the JavaDoc documentation using Maven, as well.

 

Submit your project directory called project4 to csci-1302a on odin, using the submit command.    

Your project4 directory must have a standard Maven project directory structure and must include:

•      All the source code, i.e., .java files and.  JavaDoc comments are required for some classes (as described below).  Usual “program logic” comments are required in your source code, as well.  Furthermore, your source code should be well formatted.   

•      A JUnit test class is required for some methods of one class (as described below).

•      A README.txt file explaining how to compile your program and how to test it.

Project requirements 

Complete the implementation of SimpleLinkedList and the test class 

1.      Create an initial Maven project structure.

2.      Copy the SimpleLinkedList class implementing the SimpleList interface (available on odin in /home/myid/kkochut/cs1302/SimpleLinkedList) into your Maven project and complete the implementation of the following methods in this class (only headers are provided in the provided code):

boolean add(int index, E e)  adds an element e at a specified index position in the list.  

IndexOutOfBoundsException exception is thrown if the supplied index is out of bounds, i.e., if  index < 0 or index > size().  If index is equal to size(), the new element is added at the end of the list (it is appended).

E remove(int index) 

removes and returns an element at a specified index position in the list.  

IndexOutOfBoundsException exception is thrown if the supplied index is out of bounds, i.e., if  index < 0 or index >= size().

int indexOf(E e) returns the index of an element e or -1 if it is not on the list.

The meaning of the above methods should be the same as of the corresponding ones defined by the interface java.util.List<E>.  You must handle the concurrent modification error.  Please, consult the Java SE 8 API documentation, as needed.  You must not use Java’s LinkedList or ArrayList or similar Java classes in your solution.

3.      Develop a suitable testing plan to sufficiently test the add and remove methods implemented in point 2 above.  Create a class SimpleLinkedListTest which implements your testing plan using the JUnit 4 framework.  You do not have to provide a PDF file with your test plan.

4.      Your completed SimpleLinkedList class and SimpleLinkedListTest must be in the edu.uga.cs1302.list package.  However, they must be in different subdirectories in your Maven project, as expected by Maven:

•      project4/src/main/java/edu/uga/cs1302/list  should contain the list code

•      project4/src/test/java/edu/uga/cs1302/list  should contain the test code.

More products