PRG420 PRG 420 PRG/420 version 10 Individual Assignments Week 5
    PRG420 PRG 420 PRG/420 version 10 Individual Assignments Week 5

PRG420 PRG 420 PRG/420 version 10 Individual Assignments Week 5

$15.99

PRG/420 version 10 Individual Assignments Week 5

Individual: Java Exceptions Application

Write a Java application using NetBeans Integrated Development Environment (IDE) for one (1) 

of the following programming assignments listed.   

#1 Employee Exception

Write a Java application that assigns hourly wages to employees.  Create an 

EmployeeException class whose constructor receives a String that consists of an employee ID 

and pay rate.  Create an Employee class with two fields, an identification number  and an hourly 

wage.  The employee constructor requires values for both fields.  Upon construction, throw an 

EmployeeException if the hourly wage is less than $6.00 or over $50.00.  Write an application 

that creates at least three employees with hourly wages below, above and within the given 

range.  Make sure that at least 2 exceptions are thrown and displayed.  Call this main class 

ThrowEmployee.

 

Turn in your source files named--

Employee.java

EmployeeException.java

ThrowEmployee.java

#2 Grade Exception

Write a Java application that displays a student ID number and asks the user to enter a test letter 

grade for the student.  Create an Exception class named GradeException and throw a grade 

exception if the user does not enter a valid grade, A, B, C, D, F, I, W.  Allow for both upper and 

lower cases.  Catch the grade exception and display an appropriate message. Save the main 

class as TestGrade.

Turn in your source files named--

            GradeException.java

            TestGrade.java

Include a prolog stating what each class does and document your code. 

Remove all package statements.

Submit your Java application .java files using the Assignment Files tab.