New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
重学 Java 设计模式:实战装饰器模式「SSO单点登录功能扩展,增加拦截用户访问方法范围场景」 - bugstack虫洞栈 #92
Comments
五.2的代码实现有个小错误: |
在介绍装饰类的重点时 应为3个重点 |
嘿嘿,好的 |
感谢🤭 |
为什么说这个模式没有增加子类?不也是使用了继承重写吗?我觉得解释成避免继承深度过深更好 |
// 模拟获取cookie |
|
问下装饰器和桥接模式有什么区别啊,我看着好像 |
但,设计模式仅仅是指导思想,不是落地方案,所以即使像也没关系,只要根据实际业务使用即可,不要纠结某一种设计模式。 |
我看是跟适配器模式像一点. |
https://bugstack.cn/itstack-demo-design/2020/06/09/%E9%87%8D%E5%AD%A6-Java-%E8%AE%BE%E8%AE%A1%E6%A8%A1%E5%BC%8F-%E5%AE%9E%E6%88%98%E8%A3%85%E9%A5%B0%E5%99%A8%E6%A8%A1%E5%BC%8F.html
很多人写代码往往是没有编程感觉的,也就是除了可以把功能按照固定的流程编写出流水式的代码外,很难去思考整套功能服务的扩展性和可维护性,就像江洋大盗与江洋大偷有着本质的区别!
The text was updated successfully, but these errors were encountered: