Home
API
Releases
Github
example_src
rectangle.h
1
#ifndef RECTANGLE_H_
2
#define RECTANGLE_H_
3
4
#include "shape.h"
5
14
class
Rectangle
:
public
Shape
15
{
16
private
:
18
int
length;
20
int
width;
21
22
public
:
23
33
Rectangle
(
int
l,
int
w,
int
x,
int
y);
34
43
Rectangle
(
int
l,
int
w,
Point
c);
44
52
virtual
std::string
getType
()
const
;
53
62
virtual
double
getArea
()
const
;
63
};
64
65
#endif
Rectangle::getArea
virtual double getArea() const
Definition:
rectangle.cpp:26
Rectangle
Definition:
rectangle.h:14
Shape
Definition:
shape.h:16
Rectangle::getType
virtual std::string getType() const
Definition:
rectangle.cpp:20
Rectangle::Rectangle
Rectangle(int l, int w, int x, int y)
Definition:
rectangle.cpp:6
Point
Definition:
point.h:12