Java queue assignment | Computer Science homework help

Your assignment is to create and test a class for a queue of objects. You may use any object class of your choice as the data for the queue.   The instances of the class should have at least one field that distinguishes each instance from other instances of the class (key property, also called a key field).

You should complete the software to implement and test your queue and submit the software along with a project report. 

Your queue class should maintain a head pointer to the first element in the queue, a tail pointer to the last element in the queue, and the size of the queue as queue properties.  

We will add elements to the tail of the queue and remove elements from the head of the queue.  The head pointer points to the spot from which elements are deleted from the queue, and the tail pointer points to the end of the queue where elements are added to the queue.

Note that elements move though the queue in the opposite direction of the pointers from one element to the next.  Head points to the first element in the queue.  Head.next points to the element that will become the head when the head is removed (de-queue method) – the pointers point back in the queue.

You should have methods to:

  • instantiate a null queue
  • enqueue – add an element to the queue
  • dequeue – remove an element from the queue
  • size – return the size of the queue
  • a boolean isEmpty method

You will need to create a class of nodes for the data in the queue, which we call a queueElement.

Each queueElement should have data and a pointer to the next queueElement.

We need:

  • A null constructor (default)
  • An initializing constructor (instantiates a queueElement from a data element)

and methods to :

  • set the data in a queue element
  • return the data in a queue element
  • set the pointer to the next element
  • return the pointer to the next element

This assignment requires four classes – Queue, QueueElement, the data object class, and a class for your test project.   Each class should be a separate file in your NetBeans project, all in the same source directory.

Calculate the price
Make an order in advance and get the best price
Pages (550 words)
$0.00
*Price with a welcome 15% discount applied.
Pro tip: If you want to save more money and pay the lowest price, you need to set a more extended deadline.
We know how difficult it is to be a student these days. That's why our prices are one of the most affordable on the market, and there are no hidden fees.

Instead, we offer bonuses, discounts, and free services to make your experience outstanding.
How it works
Receive a 100% original paper that will pass Turnitin from a top essay writing service
step 1
Upload your instructions
Fill out the order form and provide paper details. You can even attach screenshots or add additional instructions later. If something is not clear or missing, the writer will contact you for clarification.
Pro service tips
How to get the most out of your experience with Australia Assessments
One writer throughout the entire course
If you like the writer, you can hire them again. Just copy & paste their ID on the order form ("Preferred Writer's ID" field). This way, your vocabulary will be uniform, and the writer will be aware of your needs.
The same paper from different writers
You can order essay or any other work from two different writers to choose the best one or give another version to a friend. This can be done through the add-on "Same paper from another writer."
Copy of sources used by the writer
Our college essay writers work with ScienceDirect and other databases. They can send you articles or materials used in PDF or through screenshots. Just tick the "Copy of sources" field on the order form.
Testimonials
See why 20k+ students have chosen us as their sole writing assistance provider
Check out the latest reviews and opinions submitted by real customers worldwide and make an informed decision.
Computer science
Didn't find until the last minute that I needed to pay extra money for an extra page, which caused my stuff to be turned in late...
Customer 452515, March 25th, 2020
Education
GOOD WORK
Customer 463813, April 19th, 2023
English 101
Good job
Customer 454209, June 2nd, 2020
Retail
great
Customer 463473, November 14th, 2022
Business and administrative studies
Excellent.
Customer 460073, June 15th, 2022
History
Outstanding clarity.
Customer 456665, April 21st, 2022
Business and administrative studies
The grade was 100%- Oh man I will be back again. Thank you.
Customer 463293, April 27th, 2023
Business
Excellent!
Customer 463469, October 17th, 2022
English 101
Always use Grammarly before submitting your papers.
Customer 462495, April 6th, 2022
Medicine
Good work.
Customer 462931, May 4th, 2022
Military
good job
Customer 456821, February 28th, 2022
Military
good job
Customer 456821, November 21st, 2021
11,595
Customer reviews in total
96%
Current satisfaction rate
3 pages
Average paper length
37%
Customers referred by a friend
OUR GIFT TO YOU
15% OFF your first order
Use a coupon FIRST15 and enjoy expert help with any task at the most affordable price.
Claim my 15% OFF Order in Chat