uk.ac.ebi.microarray.zooma.retrieval
Class EFOOntocatRetriever

java.lang.Object
  extended by uk.ac.ebi.microarray.zooma.retrieval.EFOOntocatRetriever
All Implemented Interfaces:
OntologyTermRetriever

public class EFOOntocatRetriever
extends java.lang.Object
implements OntologyTermRetriever

An ontology term retriever that utilises the ontocat API to retrieve terms from EFO. EFO is loaded by using the "efo" URI supplied in the zooma-uris.properties file. This class utilises ontocat search algorithms to match values to terms.

Author:
Tony Burdett

Constructor Summary
EFOOntocatRetriever()
           
 
Method Summary
 java.util.Collection<OntologyMappingContext> fetchMappingContexts(Value value, uk.ac.ebi.ontocat.OntologyTerm term)
          Fetch the contexts in which the given description is mapped to the given term, if any.
 java.util.Collection<uk.ac.ebi.ontocat.OntologyTerm> fetchTerms(Value value)
          Fetch a collection of terms using the given description as a search parameter.
protected  java.util.Set<uk.ac.ebi.ontocat.OntologyTerm> getFetchedTerms()
          A cached set of all terms previously fetched using this retriever
protected  uk.ac.ebi.ontocat.OntologyService getService()
          A ontocat OntologyService that can be used to retrieve EFO terms.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

EFOOntocatRetriever

public EFOOntocatRetriever()
Method Detail

getService

protected uk.ac.ebi.ontocat.OntologyService getService()
A ontocat OntologyService that can be used to retrieve EFO terms.

Returns:
a service for fetching efo terms

getFetchedTerms

protected java.util.Set<uk.ac.ebi.ontocat.OntologyTerm> getFetchedTerms()
A cached set of all terms previously fetched using this retriever

Returns:
the cached set of fetched terms

fetchTerms

public java.util.Collection<uk.ac.ebi.ontocat.OntologyTerm> fetchTerms(Value value)
                                                                throws java.io.IOException
Description copied from interface: OntologyTermRetriever
Fetch a collection of terms using the given description as a search parameter.

Specified by:
fetchTerms in interface OntologyTermRetriever
Parameters:
value - the text description to search for
Returns:
a collection of OntologyTerms retrieved from the repository
Throws:
java.io.IOException - if terms could not be fetched from the underlying source.

fetchMappingContexts

public java.util.Collection<OntologyMappingContext> fetchMappingContexts(Value value,
                                                                         uk.ac.ebi.ontocat.OntologyTerm term)
                                                                  throws java.io.IOException
Description copied from interface: OntologyTermRetriever
Fetch the contexts in which the given description is mapped to the given term, if any. This returns a collection because there are no guarantees that a mapping has been supplied to the given description in exactly one way - there could be several possible context-dependent mappings in a single datasource, for example.

If there is no connection known between the supplied description and the supplied term in the datasource that backs this retriever, this method will return an empty list.

Specified by:
fetchMappingContexts in interface OntologyTermRetriever
Parameters:
value - the original description used to retrieve the supplied term
term - the term that is mapped to this description - usually, retrieved by OntologyTermRetriever.fetchTerms(uk.ac.ebi.microarray.zooma.lang.Value) first
Returns:
the contexts in which this mapping is described in the backing
Throws:
java.io.IOException - if context could not be fetched from the underlying source


Copyright © 2010. All Rights Reserved.