Java Project Intro Overview The Java Project is designed to allow

advertisement
Java Project Intro
Overview
The Java Project is designed to allow you the chance to produce a Java application using the skills,
coding, and problem solving that you learn throughout this course.
Goal
The goal of the project is for you to create a working java application that calculates various traveling
elements (gas mileage, oil changes, and tank capacity) and applies the code and Java skills that you
acquire throughout the course.
Due Date
Your Java Project has several "mini-parts" that are strewn throughout the course and are due in
various weeks. Your final project is due Week 10 of the course. Please see the timeline below for
specific due dates related to this project.
Time Line
Week
Deliverable
02
Getting Started
05
Splash Screen
06
Starting the Code
08
Enhancing Your Application
09
Custom Calculation
10
Finishing Touches
The Project
Consumers rely on fuel/gas for their vehicles along with oil and maintenance. Consumers use more
fuel during the summer months, and around the holidays (Christmas, Thanksgiving, Labor Day, etc).
It is often very difficult for travelers to budget for travel because of all of the "unknowns" (fuel type,
price, gas mileage, repairs/oil changes, etc).
AAA, MapQuest and various other businesses have tools to help travelers calculate the miles they will
travel, which in turn translates into the amount of gas needed. Based on the distance being traveled
and the particular car, the mechanic can advise how often an oil change and/or other vehicle
maintenance is recommended.
For this project you are developing an application called the Traveler's Gasoline Calculator (TGC),
which (as the name states) calculates gasoline costs for the drivers of several different types of
vehicles.
Requirements
The application should initially allow users to enter values for the number of miles, the number of
gallons, and the cost of gasoline. The application should also accept input from users that enables
them to reset the value on the screen to zero (0) so that another calculation can be performed.
Your application should also display output, and users should be able to access the calculator via the
Web, a console application and a PDA. The application should include the company logo in the
interface (create your own logo). Your application also allows users to size the window and exit the
application at any time.
The specifics of the mileage, oil changes, gas costs, and vehicle types are listed below:
Miles Per Gallon (MPG)
15
Oil Change Cost
$30.00
Oil Change Required
Every 3,000 miles
Price Per Gallon
Type of Gas
$3.00
Super Unleaded
$2.90
Unleaded
$2.50
Leaded
$4.00
Diesel
Vehicle Type
Tank Capacity
Compact
13 Gallons
Mid-Size
18 Gallons
Luxury
15 Gallons
SUV
23 Gallons
The first part of your Java project involves listing the relevant requirements necessary to design a
complete program. You need the requirements that are listed on the Java Project –
Introduction.
Using the list of requirements complete the following:
1. List the inputs and outputs necessary to calculate travel costs for people who own the various
vehicles specified in the project.
2. Create a flow chart.
3. Design five sets of test data.
4. Step the test data through the algorithm requirements listed on the introduction page.
5. Present the expected outcome of the problem.
Save your assignment as a Microsoft Word document.
Previously you began the layout and initial development of your Java Project. This week you create a
splash screen for your application. To complete your splash screen please use the information below:
Create a splash screen for the TGC application that displays:

the application's name

an address

a description
The screen should calculate:

the cost per mile

the total cost, including oil change if applicable
Save your assignment as a text file.
Write code for the application that allows users to calculate the expected cost of a trip as follows:

User can enter anticipated miles

User can enter anticipated cost of gas per gallon
The application should:

Provide interface options to allow the user to calculate anticipated cost and exit the application

Calculate and display the approximate cost, including oil change
Save your assignment as a text file.
Create a Drop box List for the application's applet to include:

Beginning locations (at least six)

Destination locations (at least six)

Vehicle size (compact, mid, luxury, SUV)

Gas type (leaded, unleaded, super unleaded, diesel)
Also create the following:

A field for approximate miles

A field for cost of gas per gallon

A Submit button

A Clear button
Save your assignment as a text file.
Now that you have created most of the code as well as the front end features and buttons, create a
calculator function to enable users to calculate their own costs if they choose. Be sure to follow the
same format that you have been using for the previous assignments.
Save your assignment as a text file.
Download