Write a graphical application that contains a class named RV whose objects are the recreational vehicle designed and digitized as described in Knowledge Exercises 20 and 21 (you can design your version as well. Simple car shape is will be appreciated. The class’s private data members should be the vehicle’s body color and (x, y) location. a) Give the UML diagram for the class. It should include a three-parameter constructor, a toString method, a method to input the values of all of an object’s data members, and a show method to draw the RV at its current (x, y) location. b) Progressively implement and test the RV class by adding a method and verifying it before adding the next method. A good order to add the methods to the class is the three-parameter constructor, followed by the toString method, the show method, and finally the inputmethod. The client code should create an RV object using the three-parameter constructor to test all of the methods as they are progressively added to the class. c) After all of the methods are verified, comment out the test code in the client application and add two RV instances to the program whose location and color are passed to the three-parameter constructor. Output these vehicles to the system console and the game board and then output them again after the user inputs a new color and a new (x, y) location for each vehicle. >> Please note this should be tested in replit.com online ide. You will get thumbs up if you also send the replit.com working url. And also in one frame there should be 2 cars... not each car in separate frame.
Write a graphical application that contains a class named RV whose objects are the recreational vehicle designed and digitized as described in Knowledge Exercises 20 and 21 (you can design your version as well. Simple car shape is will be appreciated. The class’s private data members should be the vehicle’s body color and (x, y) location. a) Give the UML diagram for the class. It should include a three-parameter constructor, a toString method, a method to input the values of all of an object’s data members, and a show method to draw the RV at its current (x, y) location. b) Progressively implement and test the RV class by adding a method and verifying it before adding the next method. A good order to add the methods to the class is the three-parameter constructor, followed by the toString method, the show method, and finally the inputmethod. The client code should create an RV object using the three-parameter constructor to test all of the methods as they are progressively added to the class. c) After all of the methods are verified, comment out the test code in the client application and add two RV instances to the program whose location and color are passed to the three-parameter constructor. Output these vehicles to the system console and the game board and then output them again after the user inputs a new color and a new (x, y) location for each vehicle. >> Please note this should be tested in replit.com online ide. You will get thumbs up if you also send the replit.com working url. And also in one frame there should be 2 cars... not each car in separate frame.

Trending now
This is a popular solution!
Step by step
Solved in 2 steps









