Package ubic.basecode.ontology.jena
Class AbstractOntologyMemoryBackedService
- java.lang.Object
-
- ubic.basecode.ontology.jena.AbstractOntologyService
-
- ubic.basecode.ontology.jena.AbstractOntologyMemoryBackedService
-
- All Implemented Interfaces:
OntologyService
- Direct Known Subclasses:
CellLineOntologyService
,CellTypeOntologyService
,ChebiOntologyService
,DiseaseOntologyService
,ExperimentalFactorOntologyService
,FMAOntologyService
,GenericOntologyService
,HumanDevelopmentOntologyService
,HumanPhenotypeOntologyService
,MammalianPhenotypeOntologyService
,MedicOntologyService
,MouseDevelopmentOntologyService
,NIFSTDOntologyService
,ObiService
,SequenceOntologyService
,UberonOntologyService
,UnitsOntologyService
public abstract class AbstractOntologyMemoryBackedService extends AbstractOntologyService
This class has some stuff that's specific to in-memory ontologies. Unlike database backed ontologies we don't use a pool keeping only one instance of model in memory.- Author:
- paul
-
-
Nested Class Summary
-
Nested classes/interfaces inherited from interface ubic.basecode.ontology.providers.OntologyService
OntologyService.InferenceMode, OntologyService.LanguageLevel
-
-
Field Summary
-
Fields inherited from class ubic.basecode.ontology.jena.AbstractOntologyService
log
-
-
Constructor Summary
Constructors Constructor Description AbstractOntologyMemoryBackedService()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description protected String
getOntologyUrl()
Defines the location of the ontology eg: MGEDprotected OntologyModel
loadModel(boolean processImports, OntologyService.LanguageLevel languageLevel, OntologyService.InferenceMode inferenceMode)
Delegates the call as to load the model into memory or leave it on disk.protected OntologyModel
loadModelFromStream(InputStream is, boolean processImports, OntologyService.LanguageLevel languageLevel, OntologyService.InferenceMode inferenceMode)
Load a model from a given input stream.-
Methods inherited from class ubic.basecode.ontology.jena.AbstractOntologyService
cancelInitializationThread, closeIndex, findIndividuals, findResources, findTerm, findUsingAlternativeId, getAdditionalPropertyUris, getAllURIs, getCacheName, getChildren, getInferenceMode, getLanguageLevel, getOntologyName, getParents, getProcessImports, getResource, getTerm, getTermIndividuals, index, initialize, initialize, isEnabled, isInitializationThreadAlive, isInitializationThreadCancelled, isOntologyLoaded, isSearchEnabled, loadTermsInNameSpace, setAdditionalPropertyUris, setInferenceMode, setLanguageLevel, setProcessImports, setSearchEnabled, startInitializationThread, toString, waitForInitializationThread
-
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
-
Methods inherited from interface ubic.basecode.ontology.providers.OntologyService
findIndividuals, findResources, findTerm, getChildren, getParents
-
-
-
-
Method Detail
-
getOntologyUrl
protected String getOntologyUrl()
Description copied from class:AbstractOntologyService
Defines the location of the ontology eg: MGED- Specified by:
getOntologyUrl
in classAbstractOntologyService
-
loadModel
protected OntologyModel loadModel(boolean processImports, OntologyService.LanguageLevel languageLevel, OntologyService.InferenceMode inferenceMode) throws IOException
Description copied from class:AbstractOntologyService
Delegates the call as to load the model into memory or leave it on disk. Simply delegates to either OntologyLoader.loadMemoryModel( url ); OR OntologyLoader.loadPersistentModel( url, spec );- Specified by:
loadModel
in classAbstractOntologyService
- Throws:
IOException
-
loadModelFromStream
protected OntologyModel loadModelFromStream(InputStream is, boolean processImports, OntologyService.LanguageLevel languageLevel, OntologyService.InferenceMode inferenceMode) throws IOException
Description copied from class:AbstractOntologyService
Load a model from a given input stream.- Specified by:
loadModelFromStream
in classAbstractOntologyService
- Throws:
IOException
-
-