Commits

Sam Adams committed a077898

Refactored plugin / template loading

  • Participants
  • Parent commits 730b8ff

Comments (0)

Files changed (1)

File chemistry-jmol-plugin/src/main/java/uk/ac/cam/ch/wwmm/chempound/plugins/jmol/JmolModule.java

 package uk.ac.cam.ch.wwmm.chempound.plugins.jmol;
 
-import com.google.inject.AbstractModule;
-import com.google.inject.multibindings.MapBinder;
-import uk.ac.cam.ch.wwmm.chempound.webapp.plugins.ChempoundWebPlugin;
+import uk.ac.cam.ch.wwmm.chempound.webapp.plugins.ChempoundPluginModule;
 
 /**
  * @author sea36
  */
-public class JmolModule extends AbstractModule {
+public class JmolModule extends ChempoundPluginModule {
 
     @Override
     protected void configure() {
-        MapBinder<String,ChempoundWebPlugin> binder = MapBinder.newMapBinder(binder(), String.class, ChempoundWebPlugin.class);
-        binder.addBinding("jmol").to(JmolPlugin.class);
+        bindWebPlugin("jmol", JmolPlugin.class);
     }
 
 }