这很奇怪,MapBinder 没有包含在我从 Maven 存储库获得的 Gucie 3.0 中:
我的 maven 配置是这样的:
<dependencies>
....
<dependency>
<groupId>com.google.inject</groupId>
<artifactId>guice</artifactId>
<version>3.0</version>
</dependency>
....
</dependencies>
我的 Guice 3.0 在 maven 库中甚至没有包:
com.google.inject.multibindings
有人可以指出我正确的方向吗?
非常感谢
最佳答案
添加多绑定(bind)模块 - 它是扩展的一部分:
<dependency>
<groupId>com.google.inject.extensions</groupId>
<artifactId>guice-multibindings</artifactId>
<version>3.0</version>
</dependency>
关于java - MapBinder 在 Guice 3.0 中不可用,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/18304138/