Create a class named Order. The class should have the following properties:

String buyerName
String buyerAddress
double orderCost
Date orderDate
boolean priority

Create a GUI application that allows a user to take an order. Each time an order is placed, a list of all orders and their information should be displayed (in a text area). The orders should be displayed in ascending order according to date/time. Note that orders that have priority should be listed before orders that don't. This means that an order with a priority set to true will appear in the list before an order where the priority is set to false, regardless of time

Your application should either implement the Comparable interface (on the Order class) or implement the Comparator interface. Use a generic collection to hold your orders.

Tip: You can format a date in Java with the following:

Date date = null;
DateFormat formatter = new SimpleDateFormat("MM/dd/yyyy HH:mm:ss");
formatter.setLenient(false);
date = formatter.parse("07/04/1976 10:30:00");
Academic Honesty!
It is not our intention to break the school's academic policy. Posted solutions are meant to be used as a reference and should not be submitted as is. We are not held liable for any misuse of the solutions. Please see the frequently asked questions page for further questions and inquiries.
Kindly complete the form. Please provide a valid email address and we will get back to you within 24 hours. Payment is through PayPal, Buy me a Coffee or Cryptocurrency. We are a nonprofit organization however we need funds to keep this organization operating and to be able to complete our research and development projects.