Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

java 10 16 15 Tame 2:24:30 1. the UML dass diagram with the relative associations for the flowing code and then 2. Mention what is

java
image text in transcribed
image text in transcribed
image text in transcribed
10 16 15 Tame 2:24:30 1. the UML dass diagram with the relative associations for the flowing code and then 2. Mention what is the out what will as the application complet Tihamer private video Create a button to calculate the charge Calcutta ton calculate Changes") list to the button alcutton. Cler() #crutes wit the pplication tuttan Button A star to the button that concentre tutto ister() I MIN lutti til butto tutto alcutta public class sive extends private Routinel routine, IL A nel for routine charge checkers private outinellotine, 1 A panel foron routine changes private nel buttanel, private Jutton calcotton Wipe for the buttons W calculate everything private hutton esitetton // exits the application que Jesutomotive // Display a title Supero's Automotive // Specify what happens when the close button is liked DefaultCloseOperation frame.EXITO CLOSE), // Create Hostinereloject coutine Routine 10 // Creste in object nontotine notinet) I ia the panel that contains the button twistPanel() W/ Add the pels to the content on adicroutine, Borderlayout.) Coutine. Bordetayout.CENTER): (tutteel, onderwyout. Sono Pack and display the wind atvisible(true) 1 private sector in Actions will raid wordt de tota Che Detector Decorate Declarati." Calculate the stat by the catala. frattachar procent thaton.tel atletier SCORE calcButton Time left 2:24:21 Calculate Charges"); // Add an action listener to the button. calcButton.addActionListener(new CalcButtonListener(); // Create a button to exit the application. exitButton = new JButton("Exit"); // Add an action listener to the button. exitButton.addActionListener(new ExitButtonListener()); 1/ Put the buttons in their own panel. buttonPanel = new JPanel(); buttonPanel.add(calcButton); buttonPanel.add(exitButton); private class CalcButtonListener implements ActionListener { } public void actionPerformed (ActionEvent e) double totalCharges; // Total charges // Create a DecimalFormat object to format output. DecinalFormat dollar - new DecimalFormat("0.00"); // calculate the total charges total charges - routine.getCharges() + nonRoutine.getCharges(); // Display the message. optionPane.showMessageDialog(null, "Total Charges: $" + dollar.format(totalCharges)); } // End of inner class private class ExitButtonListener implements ActionListener 11 End of public void actionPerformed (ActionEvent e) { System.exit(0); 1 // End of inner class public static void main(String[] args) JoesAutomotive jas - new JoesAutomotive(); > engash (en C double charges public class RoutinePanel extends JPanel private final double OIL_CHANGE_CHARGE 26.0; private final double LUBE_JOB CHARGE = 18.0; private final double RADIATOR FLUSH_CHARGE - 30.8; private final double TRANS_FLUSH_CHARGE = 80.0 private final double INSPECTION CHARGE *15.0; private final double MUFFLER_CHARGE - 100.0; private final double TIRE ROTATION CHARGE - 20.0; private CheckBox oil change; // Check box for oil change private CheckBox TubeJob; // Check box for lube job private CheckBox radiatorFlush; // Check box for radiator flush private CheckBox transFlush; // Check box for transmission flush private CheckBox inspection; // Check box for inspection private CheckBox muffler; // Check box for muffler replacement private CheckBox tireRotation; // Check box for tire rotation if (oil change. isselected) charges + OIL_CHANGE_CHARGE; if (lubeJob. isSelected() charges + - LUBE_JOB CHARGE; if (radiatorFlush. isselected()) charges ++ RADIATOR FLUSH_CHARGE; if (transFlush. isSelected) charges + TRANS FLUSH CHARGE; if (inspection.isselected()) charges INSPECTION CHARGE; if (muffler. isselected()) charges + MUFFLER_CHARGE; if (tireRotation. isselected()) charges + TIRE ROTATION_CHARGE; return charges; > 3 public RoutinePanel() DecimalFormat dollar new DecimalFormat("#,##0.00"); oilChance new CheckBox("Oil Change ($". dollar.format(OIL CHANGE CHARGE). ""); lube Job - new 3CheckBox("Lube Job ($" + dollar, format (LUBE_JOB_CHARGE))); radiator Flush-new checkBox("Radiator Flush (s". dollar.format(RADIATOR FLUSH_CHARGE).")) transFlush = new JCheckBox("Transmission Flush ($ dollar.format(TRANS FLUSH_CHARGE) + " "); inspection = new checkBox("Inspection (". dollar.format(INSPECTION CHARGE) + ")); muffler new "checkbox("Muffler Replacement ($" dollar.format(MUFFLER_CHARGE) + ")); tireRotation - new 3CheckBox("Tire Rotation (s". dollar.format(TIRE ROTATION CHARGE) + ">"); setLayout(new Gridl.ayout(7, 1)); setBorder (BorderFactory.createTitledBorder("Routine Services"); add(oilChange); add(lube Job); add(radiatorFlush) add(transFlush) add (inspection); add(muffler); add(tireRotation); 10 16 15 Tame 2:24:30 1. the UML dass diagram with the relative associations for the flowing code and then 2. Mention what is the out what will as the application complet Tihamer private video Create a button to calculate the charge Calcutta ton calculate Changes") list to the button alcutton. Cler() #crutes wit the pplication tuttan Button A star to the button that concentre tutto ister() I MIN lutti til butto tutto alcutta public class sive extends private Routinel routine, IL A nel for routine charge checkers private outinellotine, 1 A panel foron routine changes private nel buttanel, private Jutton calcotton Wipe for the buttons W calculate everything private hutton esitetton // exits the application que Jesutomotive // Display a title Supero's Automotive // Specify what happens when the close button is liked DefaultCloseOperation frame.EXITO CLOSE), // Create Hostinereloject coutine Routine 10 // Creste in object nontotine notinet) I ia the panel that contains the button twistPanel() W/ Add the pels to the content on adicroutine, Borderlayout.) Coutine. Bordetayout.CENTER): (tutteel, onderwyout. Sono Pack and display the wind atvisible(true) 1 private sector in Actions will raid wordt de tota Che Detector Decorate Declarati." Calculate the stat by the catala. frattachar procent thaton.tel atletier SCORE calcButton Time left 2:24:21 Calculate Charges"); // Add an action listener to the button. calcButton.addActionListener(new CalcButtonListener(); // Create a button to exit the application. exitButton = new JButton("Exit"); // Add an action listener to the button. exitButton.addActionListener(new ExitButtonListener()); 1/ Put the buttons in their own panel. buttonPanel = new JPanel(); buttonPanel.add(calcButton); buttonPanel.add(exitButton); private class CalcButtonListener implements ActionListener { } public void actionPerformed (ActionEvent e) double totalCharges; // Total charges // Create a DecimalFormat object to format output. DecinalFormat dollar - new DecimalFormat("0.00"); // calculate the total charges total charges - routine.getCharges() + nonRoutine.getCharges(); // Display the message. optionPane.showMessageDialog(null, "Total Charges: $" + dollar.format(totalCharges)); } // End of inner class private class ExitButtonListener implements ActionListener 11 End of public void actionPerformed (ActionEvent e) { System.exit(0); 1 // End of inner class public static void main(String[] args) JoesAutomotive jas - new JoesAutomotive(); > engash (en C double charges public class RoutinePanel extends JPanel private final double OIL_CHANGE_CHARGE 26.0; private final double LUBE_JOB CHARGE = 18.0; private final double RADIATOR FLUSH_CHARGE - 30.8; private final double TRANS_FLUSH_CHARGE = 80.0 private final double INSPECTION CHARGE *15.0; private final double MUFFLER_CHARGE - 100.0; private final double TIRE ROTATION CHARGE - 20.0; private CheckBox oil change; // Check box for oil change private CheckBox TubeJob; // Check box for lube job private CheckBox radiatorFlush; // Check box for radiator flush private CheckBox transFlush; // Check box for transmission flush private CheckBox inspection; // Check box for inspection private CheckBox muffler; // Check box for muffler replacement private CheckBox tireRotation; // Check box for tire rotation if (oil change. isselected) charges + OIL_CHANGE_CHARGE; if (lubeJob. isSelected() charges + - LUBE_JOB CHARGE; if (radiatorFlush. isselected()) charges ++ RADIATOR FLUSH_CHARGE; if (transFlush. isSelected) charges + TRANS FLUSH CHARGE; if (inspection.isselected()) charges INSPECTION CHARGE; if (muffler. isselected()) charges + MUFFLER_CHARGE; if (tireRotation. isselected()) charges + TIRE ROTATION_CHARGE; return charges; > 3 public RoutinePanel() DecimalFormat dollar new DecimalFormat("#,##0.00"); oilChance new CheckBox("Oil Change ($". dollar.format(OIL CHANGE CHARGE). ""); lube Job - new 3CheckBox("Lube Job ($" + dollar, format (LUBE_JOB_CHARGE))); radiator Flush-new checkBox("Radiator Flush (s". dollar.format(RADIATOR FLUSH_CHARGE).")) transFlush = new JCheckBox("Transmission Flush ($ dollar.format(TRANS FLUSH_CHARGE) + " "); inspection = new checkBox("Inspection (". dollar.format(INSPECTION CHARGE) + ")); muffler new "checkbox("Muffler Replacement ($" dollar.format(MUFFLER_CHARGE) + ")); tireRotation - new 3CheckBox("Tire Rotation (s". dollar.format(TIRE ROTATION CHARGE) + ">"); setLayout(new Gridl.ayout(7, 1)); setBorder (BorderFactory.createTitledBorder("Routine Services"); add(oilChange); add(lube Job); add(radiatorFlush) add(transFlush) add (inspection); add(muffler); add(tireRotation)

Step by Step Solution

There are 3 Steps involved in it

Step: 1

blur-text-image

Get Instant Access to Expert-Tailored Solutions

See step-by-step solutions with expert insights and AI powered tools for academic success

Step: 2

blur-text-image

Step: 3

blur-text-image

Ace Your Homework with AI

Get the answers you need in no time with our AI-driven, step-by-step assistance

Get Started

Students also viewed these Databases questions

Question

How can you defend against SQL injection attacks?

Answered: 1 week ago

Question

Prepare for a successful job interview.

Answered: 1 week ago

Question

Describe barriers to effective listening.

Answered: 1 week ago

Question

List the guidelines for effective listening.

Answered: 1 week ago