Package org.semanticweb.owlapi.util
Class CommonBaseIRIMapper
java.lang.Object
org.semanticweb.owlapi.util.CommonBaseIRIMapper
- All Implemented Interfaces:
Serializable
,OWLOntologyIRIMapper
An ontology IRI mapper that can be used to map ontology IRIs to ontology
document IRIs which share the same base.
- Since:
- 2.0.0
- Author:
- Matthew Horridge, The University Of Manchester, Bio-Health Informatics Group
- See Also:
-
Constructor Summary
ConstructorsConstructorDescriptionCommonBaseIRIMapper
(IRI base) Creates a mapper, which maps ontology URIs to URIs which share the specified base. -
Method Summary
Modifier and TypeMethodDescriptionvoid
addMapping
(IRI ontologyIRI, String localName) Adds a mapping from an ontology IRI to an ontology document IRI which has a base of this mapper and a specified local name - in other words the document IRI will be determined by resolving the local name against the URI base of this mapper.getDocumentIRI
(IRI ontologyIRI) Given an ontology IRI, this method maps the ontology IRI to a document IRI.
-
Constructor Details
-
CommonBaseIRIMapper
Creates a mapper, which maps ontology URIs to URIs which share the specified base.- Parameters:
base
- the base IRI
-
-
Method Details
-
addMapping
Adds a mapping from an ontology IRI to an ontology document IRI which has a base of this mapper and a specified local name - in other words the document IRI will be determined by resolving the local name against the URI base of this mapper.- Parameters:
ontologyIRI
- the ontology IRIlocalName
- the document IRI
-
getDocumentIRI
Description copied from interface:OWLOntologyIRIMapper
Given an ontology IRI, this method maps the ontology IRI to a document IRI.- Specified by:
getDocumentIRI
in interfaceOWLOntologyIRIMapper
- Parameters:
ontologyIRI
- The ontology IRI to be mapped.- Returns:
- The document IRI of the ontology, or
null
if the mapper doesn't have mapping for the specified ontology IRI.
-