摘要: 依赖注入优于硬连接资源 许多类依赖于一个或多个底层资源。例如,拼写检查器依赖于字典。将此类类实现为静态工具类并 不少见 (详见第 4 条): xxxxxxxxxx // Inappropriate use of static utility - inflexible & untestable! pu 阅读全文
posted @ 2020-03-19 03:19 webzom 阅读(190) 评论(0) 推荐(0)