.to(FileRefDatabase.class)//
.in(Scopes.SINGLETON);
MapBinder<VersionedFormat, ObjectDatabase> objectPlugins = MapBinder.newMapBinder(
binder(), VersionedFormat.class, ObjectDatabase.class);
objectPlugins //
.addBinding(new VersionedFormat("bdbje", "0.2"))//
.to(JEObjectDatabase_v0_2.class)//
.in(Scopes.SINGLETON);//
objectPlugins //
.addBinding(new VersionedFormat("bdbje", "0.1"))//
.to(JEObjectDatabase_v0_1.class)//
.in(Scopes.SINGLETON);
objectPlugins //
.addBinding(new VersionedFormat("mongodb", "0.1"))//
.to(MongoObjectDatabase.class)//
.in(Scopes.SINGLETON);
objectPlugins //
.addBinding(
new VersionedFormat(SQLiteStorage.FORMAT_NAME, SQLiteStorage.VERSION))//
.to(XerialObjectDatabase.class)//
.in(Scopes.SINGLETON);
MapBinder<VersionedFormat, StagingDatabase> stagingPlugins = MapBinder.newMapBinder(
binder(), VersionedFormat.class, StagingDatabase.class);
stagingPlugins //
.addBinding(new VersionedFormat("mongodb", "0.1"))//
.to(MongoStagingDatabase.class)//
.in(Scopes.SINGLETON);
stagingPlugins //
.addBinding(new VersionedFormat("bdbje", "0.2"))//
.to(JEStagingDatabase_v0_2.class)//
.in(Scopes.SINGLETON);
stagingPlugins //
.addBinding(new VersionedFormat("bdbje", "0.1"))//
.to(JEStagingDatabase_v0_1.class)//
.in(Scopes.SINGLETON);
stagingPlugins //
.addBinding(
new VersionedFormat(SQLiteStorage.FORMAT_NAME, SQLiteStorage.VERSION))//
.to(XerialStagingDatabase.class)//
.in(Scopes.SINGLETON);
MapBinder<VersionedFormat, GraphDatabase> graphPlugins = MapBinder.newMapBinder(
binder(), VersionedFormat.class, GraphDatabase.class);
graphPlugins //
.addBinding(new VersionedFormat("bdbje", "0.2")) //
.to(JEGraphDatabase_v0_2.class) //
.in(Scopes.SINGLETON);
graphPlugins //
.addBinding(new VersionedFormat("bdbje", "0.1")) //
.to(JEGraphDatabase_v0_1.class) //
.in(Scopes.SINGLETON);
graphPlugins //
.addBinding(new VersionedFormat("mongodb", "0.1")) //
.to(MongoGraphDatabase.class) //
.in(Scopes.SINGLETON);
graphPlugins //
.addBinding(
new VersionedFormat(SQLiteStorage.FORMAT_NAME, SQLiteStorage.VERSION)) //
.to(XerialGraphDatabase.class) //
.in(Scopes.SINGLETON);
}