Using Java: 1 Description of the Program In this assignment, you are asked to implement a graphical application that displays a list of courses. Briefly, this GUI will take the inputs (i.e., course information), store them in an array list, and display course information in the output area. Figure 1 shows the layout of the CourseDisplay GUI. Figure 1: A screenshot of the CourseDisplay GUI. 2 Details of the program You should have three Java files: 1. CourseDisplayFrame class that extends JFrame class (The main part of your program). 2. CourseDisplayViewer class, which contains the main method where a CourseDisplay object will be created, and the GUI will pop up (Suggested frame width of 450, and frame height of 400). 3. Course class, which is the class that models the Course objects (This file will be given to you). 1 In your CourseDisplayFrame class file, you should have the followings: • Input area: – A text label and a text field (suggested width of 30) for course code; – A text label and a text field (suggested width of 30) for course name; – A text label and a text field (suggested width of 30) for course credit; – A text label and a text field (suggested width of 30) for course grade; • Buttons: – One button (AddCourse) used for adding a course into your course list, and append this course in the output area; – One button (SortByCode) used for sorting the course list by course code. The so the output should be displayed as in Figure 2. Figure 2: A screenshot of the sorted Courses by course code. – One button (SortByName) used for sorting the course list by course name. The output should be displayed as in Figure 3. – One button (SortByGrade) used for sorting the course list by course grade. The output should be displayed as in Figure 4. – One button (ResetInput) used for resetting all input fields; • Output area: – One text area (suggested row of 10 and column of 35) that displays course information; You may initialize the text area by including the headings (Code, Name, Credit, and Grade)
Using Java:
1 Description of the Program In this assignment, you are asked to implement a graphical application that displays a list of courses. Briefly, this GUI will take the inputs (i.e., course information), store them in an array list, and display course information in the output area. Figure 1 shows the layout of the CourseDisplay GUI. Figure 1: A screenshot of the CourseDisplay GUI. 2 Details of the program You should have three Java files: 1. CourseDisplayFrame class that extends JFrame class (The main part of your program). 2. CourseDisplayViewer class, which contains the main method where a CourseDisplay object will be created, and the GUI will pop up (Suggested frame width of 450, and frame height of 400). 3. Course class, which is the class that models the Course objects (This file will be given to you). 1 In your CourseDisplayFrame class file, you should have the followings: • Input area: – A text label and a text field (suggested width of 30) for course code; – A text label and a text field (suggested width of 30) for course name; – A text label and a text field (suggested width of 30) for course credit; – A text label and a text field (suggested width of 30) for course grade; • Buttons: – One button (AddCourse) used for adding a course into your course list, and append this course in the output area; – One button (SortByCode) used for sorting the course list by course code. The so the output should be displayed as in Figure 2. Figure 2: A screenshot of the sorted Courses by course code. – One button (SortByName) used for sorting the course list by course name. The output should be displayed as in Figure 3. – One button (SortByGrade) used for sorting the course list by course grade. The output should be displayed as in Figure 4. – One button (ResetInput) used for resetting all input fields; • Output area: – One text area (suggested row of 10 and column of 35) that displays course information; You may initialize the text area by including the headings (Code, Name, Credit, and Grade)
Trending now
This is a popular solution!
Step by step
Solved in 2 steps with 3 images