Top "Guice" questions

Guice is a lightweight dependency injection framework for Java.

Alternative to dozer for bean mapping?

I am trying to figure out an easy way to map DTOs to entities without the boiler-plate code. While I …

guice dto dozer dto-mapping
Guice: how do you configure an @Provides and @Singleton in a module in this case?

I have a provider method in a module annotated with @Provides: @Provides public ChatServicePerformanceMonitor getChatServicePerfMon() { ... } and I have annotated my …

guice
Accessing Guice injector in its Module?

I am extending Guice's AbstractModule and inside of the extending class I need access to Guice's injector. It that possible, …

java dependency-injection guice
Why use/develop Guice, when You have Spring and Dagger?

To my knowledge, Dagger does generate code, while Guice and Spring rely on runtime processing, thus Dagger works faster, but …

java spring guice dagger-2
Java error: Found interface ... but class was expected

I am getting a strange runtime error from my code: "Found interface [SomeInterface] but class was expected" How can this …

java guice
How do I test Guice injections?

I gave to Google Guice the responsibility of wiring my objects. But, how can I test if the bindings are …

java testing dependency-injection guice
Guice injector.getInstance() - good practice?

Let's say I have two applications sharing the same library. This library contains common classes like DAOs, Utils, etc. Everything …

java dependency-injection guice
Guice and interface that has multiple implementations

If I have interface Validator and multiple implementations for this interface. How can I inject any of the multiple implementations …

java guice
Guice: Using @Named to create object

Using Guice, if I have @Inject @Named("light") Color light; I can use bind(Color.class).annotatedWith(Names.named("light")) .…

java dependency-injection guice
Can anyone provide a clear explanation of why Google Guice is useful?

I've read about Google Guice, and understand the general issues with other approaches to dependency injection, however I haven't yet …

java guice