Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

Your program must be split into 4 files: the driver program, the class interface, the class header file (class definition), and class implementation file. please

image text in transcribed

Your program must be split into 4 files: the driver program, the class interface, the class header file (class definition), and class implementation file.

please code using C++ LANGUAGE. Please program must be split into 4 files.

When you have completed and tested your code, submit the following files.

1, your driver (test program)

2, RectangleInterface.h

3, Rectangle.h

4, Rectangle.cpp

Note that you will not use a class template for this assignoment. But you will use an abstract class with inheritance. Assignment Delails these files to the project, and be sure that you can compile and run the example code. Rectangle C.lass Members Your cliss should bave private data fields (member variables or data members) of type double to represent the lengeh and wideh of the rectingle. Your cliss should bive the following public methods (member functions): - A default (no argument) constructor that sets initializes the length and width of the rectangle to 10. . return fulse. - A constant method called get ength that retums the length of the rectangle. - A constant method called getWidi that returns the width of the rectangle. - A constant method called getArea that retums the area of the rectangle. The area of a rectangle is the length times the width. Your method prototypes should be: Reotanple( ) bool eet ( double newLength, double newWidth if double petcenpth() coneti double petwidth() conetr double petsres() voneti a class header file and the implementations for the class methods in a class implementation file. Rectangle Interface File example Circle class in Blackboard. It is important to note: - Constructor methods are not included in the abstract class. - You must include a virtual destructor for the abstract class with an empty implementation (sec the examples). Debugging and Testing Tips 1. If you sec linker error nessages like: undefined reference to vtable ... undefined reference to 'interface-deetruotor-nethod' and link your changes

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

Recommended Textbook for

Building The Data Warehouse

Authors: W. H. Inmon

4th Edition

0764599445, 978-0764599446

More Books

Students also viewed these Databases questions

Question

3. Select a font that's easy for your readers to read.

Answered: 1 week ago