面向对象设计原则之二:开放封闭原则
开放封闭原则(Open-Closed Principle OCP) Software entities(classes,modules,functions etc) should open for ...
开放封闭原则(Open-Closed Principle OCP) Software entities(classes,modules,functions etc) should open for ...
Python 入门之 Python三大器 之 装饰器 1、开放封闭原则: (1)代码扩展进行开放 任何一个程序,不可能在设计之初就已经想好了所有的功能并且未来不做任何更新和修改。所以我们必须 ...