Page 1 of 1

PLEASE USE THE JAVA CODE , THANK YOU !! Only use the concept from chapter 1 to Chapter 11,13 Chapter 1: Introduction to

Posted: Mon May 09, 2022 6:06 am
by answerhappygod
PLEASE USE THE JAVA CODE , THANK YOU
!!
Only use the concept from chapter 1 to Chapter
11,13
Chapter 1: Introduction to Computers, Programs, and Java
Chapter 2: Elementary Programming
Chapter 3: Selections
Chapter 4: Mathematical Functions, Characters, and Strings
Chapter 5: Loops
Chapter 6: Methods
Chapter 7: Arrays
Chapter 9: Objects and Classes
Chapter 10: Object-Oriented Thinking
Chapter 11: Inheritance and Polymorphism
Chapter 13: Abstract Classes and Interfaces
Please Use The Java Code Thank You Only Use The Concept From Chapter 1 To Chapter 11 13 Chapter 1 Introduction To 1
Please Use The Java Code Thank You Only Use The Concept From Chapter 1 To Chapter 11 13 Chapter 1 Introduction To 1 (206.71 KiB) Viewed 21 times
Assignment #5 - Interfaces You are creating an AirVehicle interface and SoundBarrier interface, and two classes that implement these interfaces. The two classes that implement the interfaces will be named FighterJet and CargoPlane. The Fighterlet class will implement both interfaces, while the CargoPlane will only implement the AirVehicle interface. You will be simulating a plane taking off, flying, breaking the sound barrier (if a fighter jet), and then landing using simple print statements (ie. "F-16 is taking off."). AirVehicle (interface) wwws This interface will have the following methods: public void axtakesff2 ; public void axlxD); public void axtande; . SoundBarrier (interface) This interface will have the following method: public void breakfoundbarsies2); FighterJet (class) This class will have the following private data members: . Number of Engines, type int Number of Crew Members, type int Name of Jet, type String Name of Manufacturer, type String . This class will have a default constructor, and a constructor that takes all the private data members as arguments. Create getters and setters for all data members, and also create a toString() method. Implement all methods from both interfaces. Using the interface methods, create print statements that simulate the actions being performed i.e. for avtakeoff, it should simply display something like "<name of fighter jet> has started the takeoff roll."). The fighter jet will break the sound barrier, so don't forget to implement that method. CargoPlane (class) This class will have the following private data members: . • Number of Engines, type int Number of Crew Members, type int Name of Plane, type String Name of Manufacturer, type String . . It will also have a default constructor, and a constructor that takes all the private data members as arguments. Create getters and setters for all data members, and also create a toString() method.
Implement the methods from the Air Vehicle interface. Using the interface methods, create print statements that simulate the actions being performed (ie. for avtakeoff, it should simply display something like "<name of cargo plane> has started the takeoff roll."). Cargo planes will not be breaking the sound barrier, so it does not implement the SoundBarrier interface. AirVehicleDemo (class that contains main) Create one fighter jet object and one cargo plane object and populate the data members using a constructor. Display each object's information, then simulate takeoff, flight, breaking the sound barrier (fighter jet), and landing. No user input is required for this assignment. Submit the following java files: FighterJet.java CargoPlane.java AirVehicle.java SoundBarrier.java AirVehicleDemo.java Sample Run Below: ####################### # Eighteetet. Info # Eighter jeten Counangines-2, bunCrew Members-1, Dame fjet-F-16, manufacturer-General Dynamics] F-16 is starting the takeoff roll. F-16 has taken off and is now flying. F-16 has broken the sound barrier!!! F-16 has successfully landed. ######### ############# # Sargsflare Info # Sarsaklans. Courensines=4, bunCrew Members=3, DamefreaDe=C-17, manufacturer=Boeing] C-17 is starting the takeoff roll. C-17 has taken off and is now flying. C-17 has successfully landed.