All Downloads are FREE. Search and download functionalities are using the official Maven repository.

edu.stanford.protege.webprotege.crud.obo.OBOIdSuffixEntityCrudKitPlugin Maven / Gradle / Ivy

The newest version!
package edu.stanford.protege.webprotege.crud.obo;

import edu.stanford.protege.webprotege.crud.*;
import edu.stanford.protege.webprotege.crud.gen.GeneratedAnnotationsSettings;
import edu.stanford.protege.webprotege.crud.oboid.OboIdSuffixKit;
import edu.stanford.protege.webprotege.crud.oboid.OboIdSuffixSettings;

import javax.annotation.Nonnull;
import javax.inject.Inject;

import static com.google.common.base.Preconditions.checkNotNull;

/**
 * Author: Matthew Horridge
* Stanford University
* Bio-Medical Informatics Research Group
* Date: 8/19/13 */ public class OBOIdSuffixEntityCrudKitPlugin implements EntityCrudKitPlugin { @Nonnull private final OboIdSuffixKit kit; @Nonnull private final OBOIdSuffixEntityCrudKitHandlerFactory factory; @Inject public OBOIdSuffixEntityCrudKitPlugin(@Nonnull OboIdSuffixKit kit, @Nonnull OBOIdSuffixEntityCrudKitHandlerFactory factory) { this.kit = checkNotNull(kit); this.factory = checkNotNull(factory); } @Override public EntityCrudKit getEntityCrudKit() { return kit; } @Override public EntityCrudKitHandler getEntityCrudKitHandler() { return factory.create(EntityCrudKitPrefixSettings.get(), OboIdSuffixSettings.get(), GeneratedAnnotationsSettings .empty()); } @Override public EntityCrudKitHandler getEntityCrudKitHandler(EntityCrudKitSettings settings) { return factory.create(settings.getPrefixSettings(), (OboIdSuffixSettings) settings.getSuffixSettings(), settings.getGeneratedAnnotationsSettings()); } @Override public OboIdSuffixSettings getDefaultSettings() { return OboIdSuffixSettings.get(); } }




© 2015 - 2025 Weber Informatics LLC | Privacy Policy