Open-Closed Principle

TS
Sep 21, 2021

The open–closed principle states “software entities (classes, modules, functions, etc.) should be open for extension, but closed for modification”; that is, such an entity can allow its behaviour to be extended without modifying its source code.

It would help if you built your classes in a way to be able to extend them. Well writing class should not be changed to integrate new future.

http://blog.cleancoder.com/uncle-bob/2014/05/12/TheOpenClosedPrinciple.html

https://www.youtube.com/watch?v=-ptMtJAdj40

--

--