Open alexey-malov opened 4 years ago
[ ] Удалить избыточные #include-ы из заголовочного файла
[ ] Метод GetShapeByIndex небезопасен. Мы не знаем, какой диапазон индексов является безопасным. Если вам нужен доступ к коллекции, то лучше передать в ShapesProcessor ссылку на коллекцию фигур снаружи.
[ ] Этот класс сейчас решает несколько задач: считывает фигуры, хранит фигур, ищет минимальную и максимальную фигуры. Выглядит так, что его стоило бы разделить на несколько более простых
IShape* triangle = new CTriangle; delete triangle; В таком случае деструктор CTriangle не вызывается Добавил виртуальные деструкторы в IShape и ISolidShape
https://github.com/RomanovAleksandr/oop/blob/625f4dc7f7babbf9140241f6a8fb1ee193baf22f/lab4/Shapes/Shapes/CPoint.h#L4-L14