34|DI Container(22):如何对Bind的逻辑进行重构?

2022-05-24 徐昊
《徐昊 · TDD 项目实战 70 讲》
课程介绍


讲述:李辰洋

时长:大小1.26M


你好,我是徐昊。今天我们继续使用 TDD 的方式实现注入依赖容器。

回顾代码与任务列表

到目前为止,我们的代码是这样的:
Component.javapackage geektime.tdd.di;import java.lang.annotation.Annotation;public record Component(Class<?> type, Annotation qualifiers) {}ComponentRef.javapackage geektime.tdd.di;import java.lang.annotation.Annotation;import java.lang.reflect.ParameterizedType;import java.lang.reflect.Type;import java.util.Objects;public class ComponentRef<ComponentType> { public static <...

展开全文
© 版权归极客邦科技所有,未经许可不得传播售卖。 页面已增加防盗追踪,如有侵权极客邦将依法追究其法律责任。

精选留言

  • 张铁林
    2022-06-04
    https://github.com/vfbiby/tdd-di-container/tree/master 已码完

    编辑回复: 假期愉快!

    
    
  • aoe
    2022-05-30
    21 ~ 34 笔记 https://wyyl1.com/post/19/09/

    编辑回复: good work!

    
    