Find centralized, trusted content and collaborate around the technologies you use most.
Teams
Q&A for work
Connect and share knowledge within a single location that is structured and easy to search.
Errai 是一个 GWT 库,除其他外,它实现了 CDI。
通常 CDI API 是由 IOC 容器实现的,您能否帮助理解 GWT 库如何在客户端(即浏览器)上实现它?
我真的很难理解它。
Errai 通过为其生成 java 代码来实现依赖注入。基本上是一些提供手动反射/实例化的代码。
如果您有项目,可以查看“target.generated\org\jboss\erai\ioc\client”中的 java 代码