Create an application that accepts employee data interactively. Users might make any of the following errors as
Question:
Create an application that accepts employee data interactively. Users might make any of the following errors as they enter data:
The employee number is not numeric, less than 1000, or more than 9999.
The hourly pay rate is not numeric, less than $9.00, or more than $25.00.
Create a class that stores an array of six usable error messages that describe the preceding mistakes; save the file as EmployeeMessages.java. Create an EmployeeException class; each object of this class will store one of the messages. Save the file as EmployeeException.java. Create an application that prompts the user for employee data, and display the appropriate message when an error occurs. If no error occurs, display the message “Valid employee data”. Save the program as EmployeeDataEntry.java.
Step by Step Answer:
EmployeeDataEntry import javautil public class EmployeeDataEntry public static void mainString args ...View the full answer
Students also viewed these Computer science questions
-
A company accepts user orders for its products interactively. Users might make the following errors as they enter data: The item number ordered is not numeric, too low (less than 0), or too high...
-
Create a class that stores an array of usable error messages save the file as Data Messages java Create a Data Exception class each object of this class will store one of the messages Save the file...
-
Create a TaxReturn class with fields that hold a taxpayers Social Security number, last name, first name, street address, city, state, zip code, annual income, marital status, and tax liability....
-
Harvold Company's quality cost report is to be based on the following data: Test and inspection of incoming materials. $71,000 Supplies used in testing and inspection . Re-entering data because of...
-
Assume that female students' heights are normally distributed with a mean given by = 64.2 in and a standard deviation given by = 2.6 in. a. If 4 female students are randomly selected, find the...
-
Express as a sum or a difference of logarithms. loga V9 - x
-
What are some of symptoms of Functional Decompositions?
-
The following tasks are to be performed on an assembly line: The workday is seven hours long. Demand for completed product is 750 per day. a. Find the cycle time required to produce 750 units per...
-
KJSC , Inc. - Using the following information, create journal entries and t - accounts ON A SEPARATE PIECE OF PAPER. PLEASE NOTE - these facts will only be presented in this question. You will need...
-
A mixture of chloroform (CHC13) and acetic acid at 18oC and 1 atm (101.3 kPa) is to be extracted with water to recover the acid.(a) Forty-five kilograms of a mixture containing 35 wt% CHC13 and 65...
-
Create a UsedCarException class that extends Exception; its constructor receives a value for a vehicle identification number (VIN) that is passed to the parent constructor so it can be used in a...
-
Design an application for a pizzeria. The user makes pizza order choices from list boxes, and the application displays the price. The user can choose a pizza size of small ($7), medium ($9), large...
-
Consider two perfectly insulated vessels. Vessel 1 initially contains an ice cube at 0 C and water at 0 C. Vessel 2 initially contains an ice cube at 0 C and a saltwater solution at 0 C. Consider...
-
In organizational behavior, there are four different types of models: autocratic, custodial, collegial, and supportive model. In the models how can motivation, power, and influence, decision making,...
-
CathFoods will release a new range of candies which contain anti-oxidants. New equipment to manufacture the candy will cost $3 million, which will be depreciated by straight-line depreciation over...
-
What are the current behavioral organization models? Autocratic, custodial, supportive, collegiate, and system. Are these current?
-
Best Buy originally priced a private-label portable DVD player at $90, and sold 1,500 units per week. After raising the price to $100, sales dropped to 1,000 units per week. What would the item's...
-
The net sales for The Halloween Costume Shop in 2005 was $45,000; its cost of goods sold was $28,000, its average inventory at cost was $16,000; its average inventory at retail was $30,000; and its...
-
When conducting a systems conversion audit, why does the auditor need to test the data details between the old and the new master files in both directions, that is, from old to new and from new to...
-
Chapter 9 Stock Valuation at Ragan Engines Input area: Shares owned by each sibling Ragan EPS Dividend to each sibling Ragan ROE Ragan required return Blue Ribband Motors Corp. Bon Voyage Marine,...
-
The this reference _____________. a. Can be used implicitly b. Must be used implicitly c. Must not be used implicitly d. Must not be used
-
Methods that you reference with individual objects are _____________. a. private b. public c. static d. nonstatic
-
Variables that are shared by every instantiation of a class are _____________. a. Class variables b. Private variables c. Public variables d. Illegal
-
BRAND SELF COLLATERAL What is your brand name? What is your logo (YOU MUST DESIGN IT What is your brand slogan (the phrase that defines your brand and yourself) What are celebrity spokesperson is...
-
Amidst the burgeoning complexity of contemporary business landscapes, how do advanced organizations employ sophisticated design principles and ergonomic considerations to optimize physical workspaces...
-
JavaScript Assignment 1: Personal Web site This assignment is linked to your final project. Thus far, you have completed a total of 4 sections as part of the Final Project. You have created a basic...
Study smarter with the SolutionInn App