Questions
#1 a. When to use an Interface vs when to use an abstract class. For each...

#1 a. When to use an Interface vs when to use an abstract class. For each “when” provide extended example(s) (with class/interface codes). b. Suppose you have an interface Moveable. Think of some interface that can extend it. Implement this two interfaces. (java oop)-> laboratory work

In: Computer Science

Chapter 9 Programming Project (Inheritance, Abstract Class/Methods, Overriding Methods) -For all classes, you need to provide...

Chapter 9 Programming Project (Inheritance, Abstract Class/Methods, Overriding Methods)

-For all classes, you need to provide the accessor and mutator methods for all instance variables, and provide/override the toString methods.

-Create a Customer class that has the attributes of name and age. Provide a method named importanceLevel. Based on the requirements below, I would make this method abstract.

-Extend Customer to two subclasses: FlightCustomer, and RetailCustomer

-FlightCustomer attributes: ticketPrice, seatNumber (The seat number should be a randomly generated number between 1 to 200)

-RetailCustomer attributes: itemsPurchased, totalSpent.

-For both FlighCustomer and RetailCustomer, you need to provide the implementation for the importanceLevel method. There are four levels: gold, silver, bronze, regular. For FlighCustomer, the level is based on the ticketPrice; for RetailCustomer, the level is based on the average price of each item.

-Instantiate three Customers for each class (six allotter) and tests ALL methods in a meaningful/informative way.

-Programming Language is Java

In: Computer Science

DUE IN TWO HOURS ASAP PLEASE!!! Given the following specification, design a class diagram using PlantUML....

DUE IN TWO HOURS

ASAP PLEASE!!!

Given the following specification, design a class diagram using PlantUML. To design the class diagram, use abstract (10 points), static (10 points), package (20 points ), namespace (20 points ), association (20 points ), and generalization (20 points ) on PlantUML

Specification:

  • A school has a principal, many students, and many teachers. Each of these persons has a name, birthdate, and may borrow and return books. The book class must contain a title, abstract, and when it is available. Teachers and the principal are both paid a salary.
  • A school has many playgrounds and rooms. A playground has many swings. Each room has many chairs and doors. Rooms include offices, restrooms, classrooms, and a cafeteria. Each classroom has many computers and desks. Each desk has many rulers.  

Submit a DOC/PDF file including PlantUML script and diagram.

In: Computer Science

Hello I'm currently having an error that says "main is not abstract and does not override...

Hello I'm currently having an error that says "main is not abstract and does not override abstract method" is there a way to fix the error?

import java.io.IOException;
import javafx.application.Application;
import javafx.event.ActionEvent;
import javafx.event.EventHandler;
import javafx.scene.Scene;
import javafx.scene.control.Button;
import javafx.stage.Stage;
import static javafx.application.Application.launch;
import javafx.scene.layout.StackPane;
public class Main extends Application implements EventHandler<ActionEvent>{
    public static void main(String[] args){
        launch(args);
    }
    @Override
    public void Start(Stage stage){
        stage.setTitle("Test");
        Button calcButton = new Button("Steam");
      
        StackPane root = new StackPane();
        calcButton.setOnAction(this);
      
        Scene scene = new Scene(root, 100, 100);
      
        stage.setScene(scene);
        stage.setTitle("Test");      
        stage.show();

    }
    class CalcButtonHandle {
      
        public void handle(ActionEvent event) throws IOException
        {
        Main fo = new Main();
        fo.runOt("D:\\Steam\\Steam.exe");
        }
    }
  
    public void runOt(String path) throws IOException{
        Runtime.getRuntime().exec("rundll32 url.dll,FileProtocolHandler " + path);
    }
}
  

In: Computer Science

Explain the importance of B2B relationships and how to make them effective. Mention the entry modes...

Explain the importance of B2B relationships and how to make them effective.

Mention the entry modes for International Markets and explain at least 2 of them (include advantages and disadvantages).

In: Finance

1. What are the advantages of per unit system? 2. What is Jacobian matrix? 3. What...

1. What are the advantages of per unit system?

2. What is Jacobian matrix?

3. What is a slack bus?

4. Mention the objectives of short circuit analysis

In: Electrical Engineering

Name or describe in some detail a technique that can be used to determine the elemental...

Name or describe in some detail a technique that can be used to determine the elemental composition of surfaces. YOU SHOULD mention one technique and write more details about it

In: Mechanical Engineering

Discuss how countries end up with their import/ export structure and how they detected their comparative...

Discuss how countries end up with their import/ export structure and how they detected their comparative advantage; mention how Brazil's terms of trade changed over time.

In: Economics

Environmental pollution is a major threat for today's contemporary world. Explain the intervention measures available to...

Environmental pollution is a major threat for today's contemporary world. Explain the
intervention measures available to limit externalities by a country. Mention at least one example for each measure.

In: Economics

How Shenzhen has developed from a paddy field into China’s manufacturing hub like today? Please mention...

  1. How Shenzhen has developed from a paddy field into China’s manufacturing hub like today? Please mention about economic policies from Deng Xiaoping.

In: Economics