Question: You are asked to create a small database for a Cricket team, make an ArrayList that contains information of players (in other words, each element

You are asked to create a small database for a Cricket team, make an ArrayList that contains information of players (in other words, each element within the list is a CricketPlayer object), and have this information accessible/editable through a GUI (Graphical User Interface). For this, you will design a CricketPlayer class and a GUI class used to implement the methods and interact with the user. CricketPlayer Class Write a CricketPlayer Class. This class should contain the player's name, player's jersey number and salary (in INR). These fields should be accepted as arguments in the constructor. The CricketPlayer class should include a getName, a getNumber and a getSalary method which return the name, the number, and the salary of the player, respectively. You should implement two more methods of your choice. For example, a setFieldingPosition method. GUI Class Write a GUI Class. This class should keep track of the players that are on the roster. It should also have an addPlayer method which adds a player to the roster. It should also have a removePlayer method which is given a player name and delete this player from the roster. Your GUI should have an "Add Player" button, a "Remove Player" button and a "Show Roster" button. These buttons should be found in one pane whereas the other pane can be used to show output
Step by Step Solution
There are 3 Steps involved in it
Get step-by-step solutions from verified subject matter experts
