Question: 2018 Fall CIS 200 Lab 5 Class, Inheritance and UML Assignment date: October 10, 2018 Due: October 17, 2018 Program 1 The following is a

 2018 Fall CIS 200 Lab 5 Class, Inheritance and UML Assignment

date: October 10, 2018 Due: October 17, 2018 Program 1 The following

2018 Fall CIS 200 Lab 5 Class, Inheritance and UML Assignment date: October 10, 2018 Due: October 17, 2018 Program 1 The following is a specification of three classes: Class Vehicle: Attributes: Age, an integer The age of the vehicle Price, a float The price of the vehicle Behaviors: setAge () Vehicle) default constructor sets age-o, and price-o.o Takes an integer parameter, returns nothing setPrice() Takes a float parameter, returns nothing getAge ) Takes no parameters, returns the vehicle's age getPrice ()Takes no parameters, returns the vehicle's price End class Vehicle Class Car: Attributes An object of type Car has all the attributes of an object of type Vehicle Additionally, Cars have attributes that Vehicles do not: RaceCarStatus , a boolean-> true or false Behaviors An object of type Car has all the behaviors of an object of type Vehicle Additionally, Cars have behaviors that Vehicles do not: Car() default constructor sets RaceCarstatus-false setRaceCarStatus() Takes an boolean parameter, returns nothing getRaceCarStatus() Takes no parameters, returns the car's race car status End Class Car 2018 Fall CIS 200 Lab 5 Class, Inheritance and UML Assignment date: October 10, 2018 Due: October 17, 2018 Program 1 The following is a specification of three classes: Class Vehicle: Attributes: Age, an integer The age of the vehicle Price, a float The price of the vehicle Behaviors: setAge () Vehicle) default constructor sets age-o, and price-o.o Takes an integer parameter, returns nothing setPrice() Takes a float parameter, returns nothing getAge ) Takes no parameters, returns the vehicle's age getPrice ()Takes no parameters, returns the vehicle's price End class Vehicle Class Car: Attributes An object of type Car has all the attributes of an object of type Vehicle Additionally, Cars have attributes that Vehicles do not: RaceCarStatus , a boolean-> true or false Behaviors An object of type Car has all the behaviors of an object of type Vehicle Additionally, Cars have behaviors that Vehicles do not: Car() default constructor sets RaceCarstatus-false setRaceCarStatus() Takes an boolean parameter, returns nothing getRaceCarStatus() Takes no parameters, returns the car's race car status End Class Car

Step by Step Solution

There are 3 Steps involved in it

1 Expert Approved Answer
Step: 1 Unlock blur-text-image
Question Has Been Solved by an Expert!

Get step-by-step solutions from verified subject matter experts

Step: 2 Unlock
Step: 3 Unlock

Students Have Also Explored These Related Databases Questions!