The “guice” package
- Inside the package “edu.utdallas.mavs.evacuation.simulation.guice” create a class named “SimulationModule” that extends the abstract class “AbstractModule” defined in the package “edu.utdallas.mavs.divas.core.host”.
- Provide a concrete implementation of the “configure” method as in the following code:
package edu.utdallas.mavs.evacuation.simulation.guice;
import com.google.inject.AbstractModule;
import com.google.inject.Singleton;
import edu.utdallas.mavs.evacuation.simulation.host.EvacuationHost;
public class SimulationModule extends AbstractModule {
@Override
protected void configure() {
bind(EvacuationHost.class).in(Singleton.class);
}
}