class BlobExportMechanismModule extends AbstractModule {

    @VisibleForTesting
    @Provides
    @Singleton
    BlobExportMechanism provideMechanism(BlobExportImplChoice implChoice,
                                         Provider<LocalFileBlobExportMechanism> localFileMechanismProvider,
                                         Provider<LinshareBlobExportMechanism> linshareMechanismProvider) {
        switch (implChoice) {
            case LOCAL_FILE:
                return localFileMechanismProvider.get();
            case LINSHARE:
                return linshareMechanismProvider.get();
            default:
                throw new RuntimeException("blobExportMechanism '" + implChoice.getImplName() + "' is not supported yet");
        }
    }

}