本文整理匯總了Java中org.semanticweb.owlapi.apibinding.OWLManager.createConcurrentOWLOntologyManager方法的典型用法代碼示例。如果您正苦於以下問題:Java OWLManager.createConcurrentOWLOntologyManager方法的具體用法?Java OWLManager.createConcurrentOWLOntologyManager怎麽用?Java OWLManager.createConcurrentOWLOntologyManager使用的例子?那麽, 這裏精選的方法代碼示例或許可以為您提供幫助。您也可以進一步了解該方法所在類org.semanticweb.owlapi.apibinding.OWLManager
的用法示例。
在下文中一共展示了OWLManager.createConcurrentOWLOntologyManager方法的7個代碼示例,這些例子默認根據受歡迎程度排序。您可以為喜歡或者感覺有用的代碼點讚,您的評價將有助於係統推薦出更棒的Java代碼示例。
示例1: inconsistentOwlThing
import org.semanticweb.owlapi.apibinding.OWLManager; //導入方法依賴的package包/類
@Test
public void inconsistentOwlThing() throws Exception {
OWLOntologyManager owlManager = OWLManager
.createConcurrentOWLOntologyManager();
// creating an ontology
final OWLOntology ontology = owlManager.createOntology();
OWLClass a = factory.getOWLClass(IRI.create("http://example.org/A"));
OWLClass b = factory.getOWLClass(IRI.create("http://example.org/B"));
// top subclass bottom => inconsistent
owlManager.addAxiom(ontology, factory.getOWLSubClassOfAxiom(
factory.getOWLThing(), factory.getOWLNothing()));
final OWLProver prover = OWLAPITestUtils.createProver(ontology);
ProofTestUtils.provabilityTest(prover,
factory.getOWLSubClassOfAxiom(a, b));
ProofTestUtils.provabilityTest(prover,
factory.getOWLSubClassOfAxiom(
factory.getOWLObjectIntersectionOf(a, b),
factory.getOWLNothing()));
}
示例2: inconsistentIndividual
import org.semanticweb.owlapi.apibinding.OWLManager; //導入方法依賴的package包/類
@Test
public void inconsistentIndividual() throws Exception {
OWLOntologyManager owlManager = OWLManager
.createConcurrentOWLOntologyManager();
// creating an ontology
final OWLOntology ontology = owlManager.createOntology();
OWLNamedIndividual ind = factory
.getOWLNamedIndividual(IRI.create("http://example.org/i"));
OWLClass a = factory.getOWLClass(IRI.create("http://example.org/A"));
OWLClass b = factory.getOWLClass(IRI.create("http://example.org/B"));
// ind instance of bottom => inconsistent
owlManager.addAxiom(ontology, factory
.getOWLClassAssertionAxiom(factory.getOWLNothing(), ind));
final OWLProver prover = OWLAPITestUtils.createProver(ontology);
ProofTestUtils.provabilityTest(prover,
factory.getOWLSubClassOfAxiom(a, b));
ProofTestUtils.provabilityTest(prover,
factory.getOWLSubClassOfAxiom(
factory.getOWLObjectIntersectionOf(a, b),
factory.getOWLNothing()));
}
示例3: inconsistentClass
import org.semanticweb.owlapi.apibinding.OWLManager; //導入方法依賴的package包/類
@Test
public void inconsistentClass() throws Exception {
OWLOntologyManager owlManager = OWLManager
.createConcurrentOWLOntologyManager();
// creating an ontology
final OWLOntology ontology = owlManager.createOntology();
OWLClass a = factory.getOWLClass(IRI.create("http://example.org/A"));
OWLClass b = factory.getOWLClass(IRI.create("http://example.org/B"));
// A subclass of bottom => A is inconsistent
owlManager.addAxiom(ontology,
factory.getOWLSubClassOfAxiom(a, factory.getOWLNothing()));
final OWLProver prover = OWLAPITestUtils.createProver(ontology);
ProofTestUtils.provabilityTest(prover,
factory.getOWLSubClassOfAxiom(a, b));
}
示例4: emptyDisjointUnion
import org.semanticweb.owlapi.apibinding.OWLManager; //導入方法依賴的package包/類
@Test
public void emptyDisjointUnion() throws Exception {
OWLOntologyManager owlManager = OWLManager
.createConcurrentOWLOntologyManager();
// creating an ontology
final OWLOntology ontology = owlManager.createOntology();
OWLClass a = factory.getOWLClass(IRI.create("http://example.org/A"));
OWLClass b = factory.getOWLClass(IRI.create("http://example.org/B"));
// DisjointUnion(A ) = EquivalentClasses(A owl:Nothing)
owlManager.addAxiom(ontology, factory.getOWLDisjointUnionAxiom(a,
Collections.<OWLClassExpression> emptySet()));
owlManager.addAxiom(ontology, factory.getOWLSubClassOfAxiom(b, b));
final OWLProver prover = OWLAPITestUtils.createProver(ontology);
prover.precomputeInferences(InferenceType.CLASS_HIERARCHY);
ProofTestUtils.provabilityTest(prover,
factory.getOWLSubClassOfAxiom(a, b));
}
示例5: emptyConjunction
import org.semanticweb.owlapi.apibinding.OWLManager; //導入方法依賴的package包/類
@Test
public void emptyConjunction() throws Exception {
OWLOntologyManager owlManager = OWLManager
.createConcurrentOWLOntologyManager();
// creating an ontology
final OWLOntology ontology = owlManager.createOntology();
OWLClass a = factory.getOWLClass(IRI.create("http://example.org/A"));
OWLClass b = factory.getOWLClass(IRI.create("http://example.org/B"));
OWLClass c = factory.getOWLClass(IRI.create("http://example.org/C"));
OWLClass d = factory.getOWLClass(IRI.create("http://example.org/D"));
// ObjectInteresectionOf() = owl:Thing
owlManager.addAxiom(ontology, factory.getOWLSubClassOfAxiom(a,
factory.getOWLObjectIntersectionOf()));
owlManager.addAxiom(ontology,
factory.getOWLSubClassOfAxiom(b, factory.getOWLThing()));
owlManager.addAxiom(ontology, factory.getOWLSubClassOfAxiom(
factory.getOWLObjectIntersectionOf(), c));
owlManager.addAxiom(ontology,
factory.getOWLSubClassOfAxiom(factory.getOWLThing(), d));
final OWLProver prover = OWLAPITestUtils.createProver(ontology);
prover.precomputeInferences(InferenceType.CLASS_HIERARCHY);
ProofTestUtils.provabilityTest(prover,
factory.getOWLSubClassOfAxiom(a, c));
ProofTestUtils.provabilityTest(prover,
factory.getOWLSubClassOfAxiom(a, d));
ProofTestUtils.provabilityTest(prover,
factory.getOWLSubClassOfAxiom(b, c));
ProofTestUtils.provabilityTest(prover,
factory.getOWLSubClassOfAxiom(b, d));
}
示例6: emptyDisjunction
import org.semanticweb.owlapi.apibinding.OWLManager; //導入方法依賴的package包/類
@Test
public void emptyDisjunction() throws Exception {
OWLOntologyManager owlManager = OWLManager
.createConcurrentOWLOntologyManager();
// creating an ontology
final OWLOntology ontology = owlManager.createOntology();
OWLClass a = factory.getOWLClass(IRI.create("http://example.org/A"));
OWLClass b = factory.getOWLClass(IRI.create("http://example.org/B"));
OWLClass c = factory.getOWLClass(IRI.create("http://example.org/C"));
// ObjectUnionOf() = owl:Nothing
owlManager.addAxiom(ontology, factory.getOWLSubClassOfAxiom(a,
factory.getOWLObjectUnionOf()));
owlManager.addAxiom(ontology,
factory.getOWLSubClassOfAxiom(b, factory.getOWLNothing()));
owlManager.addAxiom(ontology, factory
.getOWLSubClassOfAxiom(factory.getOWLObjectUnionOf(), c));
final OWLProver prover = OWLAPITestUtils.createProver(ontology);
prover.precomputeInferences(InferenceType.CLASS_HIERARCHY);
ProofTestUtils.provabilityTest(prover,
factory.getOWLSubClassOfAxiom(a, b));
ProofTestUtils.provabilityTest(prover,
factory.getOWLSubClassOfAxiom(b, a));
ProofTestUtils.provabilityTest(prover,
factory.getOWLSubClassOfAxiom(a, c));
ProofTestUtils.provabilityTest(prover,
factory.getOWLSubClassOfAxiom(b, c));
}
示例7: emptyEnumeration
import org.semanticweb.owlapi.apibinding.OWLManager; //導入方法依賴的package包/類
@Test
public void emptyEnumeration() throws Exception {
OWLOntologyManager owlManager = OWLManager
.createConcurrentOWLOntologyManager();
// creating an ontology
final OWLOntology ontology = owlManager.createOntology();
OWLClass a = factory.getOWLClass(IRI.create("http://example.org/A"));
OWLClass b = factory.getOWLClass(IRI.create("http://example.org/B"));
OWLClass c = factory.getOWLClass(IRI.create("http://example.org/C"));
// ObjectOneOf() = owl:Nothing
owlManager.addAxiom(ontology,
factory.getOWLSubClassOfAxiom(a, factory.getOWLObjectOneOf()));
owlManager.addAxiom(ontology,
factory.getOWLSubClassOfAxiom(b, factory.getOWLNothing()));
owlManager.addAxiom(ontology,
factory.getOWLSubClassOfAxiom(factory.getOWLObjectOneOf(), c));
final OWLProver prover = OWLAPITestUtils.createProver(ontology);
prover.precomputeInferences(InferenceType.CLASS_HIERARCHY);
ProofTestUtils.provabilityTest(prover,
factory.getOWLSubClassOfAxiom(a, b));
ProofTestUtils.provabilityTest(prover,
factory.getOWLSubClassOfAxiom(b, a));
ProofTestUtils.provabilityTest(prover,
factory.getOWLSubClassOfAxiom(a, c));
ProofTestUtils.provabilityTest(prover,
factory.getOWLSubClassOfAxiom(b, c));
}