Fill This Form To Receive Instant Help
Homework answers / question archive / CS 112 Final Exam Programming Exercise Programming Languages: Please download FinalExam_ProgrammingLanguages
CS 112 Final Exam
Programming Exercise
Programming Languages: Please download FinalExam_ProgrammingLanguages.zip and open
this existing project in IntelliJ. This application serves as a database of the top programming languages (most followed people) in the world.
The first time the code is executed, you should see the following JavaFX application:
In this app, the user has the ability to add a new programming language or remove an existing one.
When adding, all fields are required. An error label will appear next to any text field that is left empty.
A successful addition to the reviews (appears and the end of the list view):
Now an addition of a Functional programming language (Haskell):
Finally, when the app closes, all data is written to (and read from) a binary file for persistence. Here are the steps we’ll need to accomplish these features:
This Java class utilizes the Singleton design pattern, such that there is only one controller for the entire application. A controller accepts input from the View (Java FX) and converts it into commands for the Model (Model.java). Specifically, the Controller will load an ObservableList with Programming Language data from the binary file (using the populateListFromBinaryFile() method) only if the binary file has data, otherwise it will instantiate an empty list.
This Java class serves as the model (data, calculations and business logic) for our application and will use the binary file file to populate an ObservableList<ProgrammingLanguage>. Here are the steps needed to create a working data model.
[10 points] public static
ObservableList<ProgrammingLanguage> populateListFromBinaryFile()
[10 points] public static boolean
writeDataToBinaryFile(ObservableList<Programming Language> allLanguagesList)
This Java class provides the view (the visualization) of nodes which present data from the Controller. Most of the design has been done for you already (since this is old material), but there are a few new tasks to complete, as follows:
[5 points] private void addLanguage ()
1. If the selected item in the programming language type combo box is "Object Oriented", then instantiate new ObjectOriented object and add it to the list of programming languages 2. Otherwise, instantiate new Functional object and add it to the list of programming languages
[5 points] private void removeLanguage ()
Extra Credit Challenge [+6 points]
In this Scene, a user will be able to modify any existing programming language. For extra credit, you will need to create the Scene from scratch and navigate to it from the MainScene whenever the modifyButton is clicked. Again, you will need to add the modifyButton to the Main Scene. Here’s a sample transaction with the user:
Now the user clicks the ~ Modify Language button, which loads a new ModifyScene
(for you to create). Note that all the selected information is preloaded in the text fields.
Now the user modifies the data.
After clicking the modifyButton, user is returned back to the MainScene, showing the updated data:
Please download the answer file using this link
https://drive.google.com/file/d/1yxfqiGdA0ZIDiCOsp6c3BtU0gA0z2oHH/view?usp=sharing