This assignment lets you practice concepts such as Object Serialization, and Swing (or Java FX) GUI.
In this assignment, you will be working with some objects of a Student class (which should be serializable.)
This class has fields such as stdID (int), firstName (String), lastName (String), and courses (an array or preferably an ArrayList which contains the names of the courses the student currently has). Please provide constructors, getters, and setters, where appropriate.
In the second class, you will need to enter some information for some student objects from the console and save these student objects in a file.
And finally, in the third class of this project, you need to read those student objects from the file, and then show their info in the console, to verify that they had been saved (and serialized) correctly.
For Workshop 5, you should design a Swing (or Java FX) GUI-based Java application to do the same job. It could be as simple as (at least) a JFrame with some JTextFields and a
JButton (to let the user enter the information of the students and save them), and a
JTextArea and another JButton (to let the application to read the information of all saved students from the file and show them to the user.)
Note that we should be able to run the third class and retrieve the data (student objects) already stored in the file independent of running the second class first (assuming we have serialized some objects by running the second class in advance). These two classes should be treated and/or run as two independent processes/programs in your project. The same applies to the GUI version; you could have an interface which lets you choose whether you want to read/load or save students’ info.
Marking Criteria and Tasks:
Please note that you should:
- have appropriate indentation.
- have proper file structures and modularization.
- follow Java naming conventions. d- document all the classes properly.
- not have debug/useless code and/or file(s) left in assignment.
- have good intra and/or inter class designs.
in your code!
- Workshop 4: Developing and running the desired solution (The three classes mentioned above,) correctly, in the console:
- Workshop 5: Developing and running the desired solution (The three classes mentioned above,) correctly, using Swing (or Java FX) GUI:
- Note that you should submit your source code – just individual .java files and screenshots which demonstrate all the scenarios your code runs.)
Reviews
There are no reviews yet.