Examples of OWLClass


Examples of org.semanticweb.owlapi.model.OWLClass

    @Nonnull
    @Override
    protected Set<? extends OWLAxiom> createAxioms() {
        Set<OWLAxiom> axioms = new HashSet<>();
        OWLIndividual ind = AnonymousIndividual("a");
        OWLClass cls = Class(iri("A"));
        axioms.add(ClassAssertion(cls, ind));
        axioms.add(Declaration(cls));
        return axioms;
    }
View Full Code Here

Examples of org.semanticweb.owlapi.model.OWLClass

public class ObjectOneOfTestCase extends AbstractFileRoundTrippingTestCase {

    @Test
    public void testCorrectAxioms() {
        Set<OWLAxiom> axioms = new HashSet<>();
        OWLClass clsA = Class(iri("A"));
        OWLNamedIndividual indA = NamedIndividual(iri("a"));
        OWLNamedIndividual indB = NamedIndividual(iri("b"));
        axioms.add(SubClassOf(clsA, ObjectOneOf(indA, indB)));
        assertEquals(getOnt().getAxioms(), axioms);
    }
View Full Code Here

Examples of org.semanticweb.owlapi.model.OWLClass

    }

    @Nonnull
    private OWLOntology createOntology(@Nonnull OWLAnnotationProperty p)
            throws OWLOntologyCreationException {
        OWLClass a = Class(IRI("http://test.org/MissingDeclaration.owl#A"));
        OWLOntology ontology = m.createOntology();
        OWLAxiom axiom = AnnotationAssertion(p, a.getIRI(), Literal("Hello"));
        m.addAxiom(ontology, axiom);
        return ontology;
    }
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.