edu.stanford.smi.protegex.owl.repository.util
Class OntologyNameExtractor

java.lang.Object
  extended byedu.stanford.smi.protegex.owl.repository.util.OntologyNameExtractor

public class OntologyNameExtractor
extends Object

User: matthewhorridge
The University Of Manchester
Medical Informatics Group
Date: Sep 12, 2005

matthew.horridge@cs.man.ac.uk
www.cs.man.ac.uk/~horridgm

A utility class that extracts the name (URI) of an ontology from an OWL file. The name of an ontology is the xml:base URI.


Field Summary
private  InputStream is
           
private  boolean rdfRootPresent
           
private  URI uri
           
private  URL url
           
 
Constructor Summary
OntologyNameExtractor(InputStream is, URL documentURL)
          Constructs an OntologyNameExtractor that should obtain the name of an ontology which can be read via the specified input stream.
 
Method Summary
 URI getOntologyName()
           
private  void init()
           
 boolean isRDFRootElementPresent()
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

is

private InputStream is

uri

private URI uri

url

private URL url

rdfRootPresent

private boolean rdfRootPresent
Constructor Detail

OntologyNameExtractor

public OntologyNameExtractor(InputStream is,
                             URL documentURL)
Constructs an OntologyNameExtractor that should obtain the name of an ontology which can be read via the specified input stream.

Parameters:
is - The input stream from which the ontology can be read.
Method Detail

init

private void init()

isRDFRootElementPresent

public boolean isRDFRootElementPresent()

getOntologyName

public URI getOntologyName()
                    throws IOException
Throws:
IOException