Question: Main class: public class EmployeeApp { public static final int MAX_EMPLOYEES = 5; public static void main(String[] args) { Scanner keyboard = new Scanner( System.in

 Main class: public class EmployeeApp { public static final int MAX_EMPLOYEES= 5; public static void main(String[] args) { Scanner keyboard = newScanner( System.in ); Employee[] employees = new Employee[MAX_EMPLOYEES]; Employee currentEmployee; String inputString;int inputInt; double inputDouble; char choice; int empCount=0; employees[empCount++] = new Employee("Mitchum", "Robert", 120402, 34000.0 ); employees[empCount++] = new Employee( "Ryan", "Cornelius" );employees[empCount++] = new Employee( "Asimov", "Isaac" ); do { System.out.println( " Enter

Main class:

public class EmployeeApp { public static final int MAX_EMPLOYEES = 5; public static void main(String[] args) { Scanner keyboard = new Scanner( System.in ); Employee[] employees = new Employee[MAX_EMPLOYEES]; Employee currentEmployee; String inputString; int inputInt; double inputDouble; char choice; int empCount=0; employees[empCount++] = new Employee( "Mitchum", "Robert", 120402, 34000.0 ); employees[empCount++] = new Employee( "Ryan", "Cornelius" ); employees[empCount++] = new Employee( "Asimov", "Isaac" );

do { System.out.println( " Enter Selection ===============" ); System.out.println( "A> Add new Employee" ); System.out.println( "E> Edit Employee" ); System.out.println( "L> List Employees" ); System.out.println( "Q> Quit" ); System.out.print( " Select: " ); inputString = keyboard.nextLine(); choice = inputString.toUpperCase().charAt( 0 ); System.out.println();

switch( choice ) { case 'A': if ( empCount

empCount++; } keyboard.nextLine(); break; case 'E': System.out.printf( "Enter Last Name of Employee to Edit: " ); inputString = keyboard.nextLine(); for ( int lp=0; lp YouTube | O Lab: Module 10-Objects and Cl CS-182-Module-10-Lab-Objects G taking screenshot-Google Sear x + file:///C/Users/laith/Downloads/CS-182.Module-10-Lab-Objects-and-Classes%20(2).pdf Receipt sss,rv (1).pdfNew Tabhttps://doclagouto CS 182_Module_10_Lab_Objects_and_Classes (2).pdf 113 private): . a first name (type String), firstName . a last name (type Stringl, lastName . a employee id (type integer), employeeld a alary (type double), salary Your class should have three different constructors that initializes the four instance variables. A default constructor will have no parameters; a constructor that includes the first and last names as parameters and a constructor that includes all instance variables as parameters: . public Employeel .public Employeel String last, String first) . public Employeel String last, String first, int id, double wage Create a set and a get method for each of the four instance variables. If the monthly salary is not positive, set it to 0.0. Create a toString method) which provides a formatted output in a String return value, to be used when the application prints the object. Create a equals methodll to compare a String parameter with the String that is stored in the lastName Lab Tasks Task 10A: Create a new projected called "EmployeeApp" in Netbeans. Either download the template from Canvas and copy the template into your newly created project. Task 10B: Modify the Employee class to include the four instance variables defined above, these instance variables should be defined as private to hide their existence from the application. Task 10C: Add three Constructors to the Employee class to properly create an object. These default constructor will contain no parameters and will initialize the four instances variables. The second constructor will include the first and last names as parameters, which will set the instance variables, initialize the other two. The third constructor will include all four parameters, which will set the instance variables Task 10D: Add four set (mutator) methods and four get (accessor) methods, for each of the four instance variables. The mutator and accessor method should be named appropriately to match the variables: i.e., setFirstName and getFirstName. These methods should be defined as public, so they are accessible by the application. 4-06 PM O Type here to search 10/28/20182

Step by Step Solution

There are 3 Steps involved in it

1 Expert Approved Answer
Step: 1 Unlock blur-text-image
Question Has Been Solved by an Expert!

Get step-by-step solutions from verified subject matter experts

Step: 2 Unlock
Step: 3 Unlock

Students Have Also Explored These Related Databases Questions!