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.
gin 教程似乎暗示要注入远程服务,您需要做的就是用@Inject.
@Inject
您是否仍然需要在某个模块中定义它,或者您可以使用它进行注释@Inject并且它会起作用?
如您提到的教程中所述,Gin 自动支持远程服务:
每次要求 Gin 注入异步远程服务时,它都会在其常规远程服务上注入通过调用 GWT.create 检索到的实例。
因此,它将“正常工作”。