在應用程序配置文件我有一個信號/命令映射 signalCommandMap.map(DisconnectUserSignal).toCommand(DisconnectUserCommand);
然後, 我有兩個連接類: public class BaseConnection implements IBaseConnection
{
// When I am trying to i
我有一個持有B類這樣的A類: class A {
private final B b;
@Inject
A(B b) {
this.b = b;
}
}
interface B {}
class B1 implements B {}
class B2 implements B {}
class Client() {
@Inj
我是否需要創建一個新的模塊,將接口綁定到不同的實現? Chef newChef = Guice.createInjector(Stage.DEVELOPMENT, new Module() {
@Override
public void configure(Binder binder) {
binder.bind(FortuneService.class).to(