Contact Us
Projects | Assignments
sellfycode@gmail.com
More
Get Homework Help
English
Español
Português
Français
Deutsch
Italiano
Русский
close
Contact Us
Projects | Assignments
sellfycode@gmail.com
Starting from:
$15
Add to cart
COP2337C Project Version 1 – Solution
For version 1 your job will be to create an Employee class. Requirements:
• (10 pts) An Employee should have the following fields:
o First Name o Last Name
o ID number, in the format AA-XXXX
o Social Security Number, in the format XXX-XX-XXXX o Start Year o Department o Department code
• (10 pts) Constructors:
o Default constructor that initializes the data members to the following values:
Employee Name: John Doe
Start Year: 2017
o Parameter Constructor that sets the following fields:
First Name, Last Name, Social Security Number, Start Year, Department, Department Code
• (10 pts) Include mutator methods for the following fields:
First Name, Last Name, Social Security Number, Start Year, Department, Department Code
• (10 pts) Include accessor methods for the following fields:
First Name, Last Name, ID number, Social Security Number, Start Year, Department, Department Code
• (20 pts) Include the following private method called CreateIDNumber().
The purpose of this method is to generate the ID number.
The ID number should be generated randomly, in the format AA-XXXX with the following rules:
o The first letter should be generated from the first character of the first name
o The second letter should be generated from the first character of the last name
o The 4 digits should be generated randomly. For example:
Employee Name: John Doe
ID number: JD-8232
Note: This method should be called from both constructors.
• (10 pts) Include a toString() method. You can decide the format of the string.
• (20 pts) Create a driver class called EmployeeTester. Be sure to fully test your class.
Starting from:
$15
Add to cart
1 file (11.5KB)
More products
CSE120-Lab 3 Design Phase Solved
$30
Add to cart
CSE120-Lab 2 Mobile App Project Analysis Phase Solved
$30
Add to cart
CLOUD COMPUTING-Lab 8 Cloudlet Solved
$30
Add to cart