OWLOntologyImpl.java revision 2
/*
* Created on Dec 10, 2004
*/
/**
* @author Evren Sirin
*/
public class OWLOntologyImpl extends OWLModelImpl implements OWLOntology, org.mindswap.owls.OWLSOntology {
private OWLKnowledgeBase kb;
private OWLIndividual ontResource;
private OWLOntology sourceOntology;
super(jenaModel);
super.setBaseOntology(this);
sourceOntology = this;
}
public OWLKnowledgeBase getKB() {
return kb;
}
public Set getImports() {
}
if(!direct) {
orderedList.add( this );
continue;
else
continue;
else
}
}
return importsClosure;
}
return getImports();
}
}
}
try {
}
// probably a cast exception, someone trying to add an ontology that
// isnt actually an ontology object. just ignore, try the next one
}
}
//this.imports.addAll(theImports);
}
if(c == null) {
c = new OWLClassImpl(this, r);
}
return c;
}
if(c == null) {
c = new OWLObjectPropertyImpl(this, r);
}
return c;
}
if(c == null) {
c = new OWLDataPropertyImpl(this, r);
}
return c;
}
ind = new OWLIndividualImpl(this, r);
}
return ind;
}
return ind;
}
return ind;
}
}
}
else
}
if(value instanceof OWLDataValue )
return (OWLDataValue) value;
else
}
return uri;
}
public URI getFileURI() {
return fileURI;
}
/* (non-Javadoc)
* @see org.mindswap.owl.OWLObject#debugString()
*/
public String debugString() {
}
/* (non-Javadoc)
* @see org.mindswap.owl.OWLOntology#getOntologyObject()
*/
public OWLEntity getOntologyObject() {
return ontResource;
}
/* (non-Javadoc)
* @see org.mindswap.owl.OWLOntology#asSingletonKB()
*/
public OWLKnowledgeBase asKB() {
return asKB(true);
}
/* (non-Javadoc)
* @see org.mindswap.owl.OWLOntology#asSingletonKB(boolean)
*/
return kb;
}
return new OWLDataValueImpl(l);
}
return new OWLIndividualImpl(this, r);
}
return new OWLClassImpl(this, r);
}
return new OWLObjectPropertyImpl(this, p);
}
return new OWLDataPropertyImpl(this, p);
}
return "Ontology()";
}
}
}
// public void setKB(OWLKnowledgeBase kb) {
// this.kb = kb;
// }
// public void setImports(Set imports) {
// this.imports = imports;
// }
public void refresh() {
}
}
}
}
else
throw new IllegalArgumentException();
}
}
}
}
}
{
refresh();
}
}
}
(Resource) c.getImplementation());
}
}
public OWLOntology getTranslationSource() {
return sourceOntology;
}
}
public Service getService() {
}
int outCount = 0;
return ind;
{
}
else
{
{
}
}
}
return res;
}
// create empty ont
// add the contents of both ontologies
return newOnt;
}
}
public List getServices() {
return kb.getServices();
return super.getServices();
}
}