Examples of containsAnnotationPropertyInSignature()


Examples of org.semanticweb.owlapi.model.OWLOntology.containsAnnotationPropertyInSignature()

    @Test
    public void shouldFindOneAxiom() throws Exception {
        OWLAnnotationProperty p = AnnotationProperty(IRI("http://test.org/MissingDeclaration.owl#p"));
        OWLOntology ontology = createOntology(p);
        assertTrue(ontology.containsAnnotationPropertyInSignature(p.getIRI(),
                EXCLUDED));
        assertEquals(1, ontology.getAxiomCount());
        RDFXMLDocumentFormat format = new RDFXMLDocumentFormat();
        format.setAddMissingTypes(false);
        ontology = loadOntologyStrict(saveOntology(ontology, format));
View Full Code Here

Examples of org.semanticweb.owlapi.model.OWLOntology.containsAnnotationPropertyInSignature()

                EXCLUDED));
        assertEquals(1, ontology.getAxiomCount());
        RDFXMLDocumentFormat format = new RDFXMLDocumentFormat();
        format.setAddMissingTypes(false);
        ontology = loadOntologyStrict(saveOntology(ontology, format));
        assertFalse(ontology.containsAnnotationPropertyInSignature(p.getIRI(),
                EXCLUDED));
        assertEquals(0, ontology.getAxiomCount());
    }

    @Nonnull
View Full Code Here

Examples of org.semanticweb.owlapi.model.OWLOntology.containsAnnotationPropertyInSignature()

    @Test
    public void testAnnotationProperties() throws OWLOntologyCreationException {
        OWLOntology ontology = createOntology();
        for (DublinCoreVocabulary vocabulary : DublinCoreVocabulary.values()) {
            assertTrue(ontology.containsAnnotationPropertyInSignature(
                    vocabulary.getIRI(), EXCLUDED));
        }
    }
}
View Full Code Here

Examples of org.semanticweb.owlapi.model.OWLOntology.containsAnnotationPropertyInSignature()

        OWLLiteral val = Literal("Test", "");
        OWLAnnotationSubject subject = Class(iri("A")).getIRI();
        OWLAnnotationAssertionAxiom ax = AnnotationAssertion(ap, subject, val);
        OWLOntology ont = getOWLOntology("Ont");
        ont.getOWLOntologyManager().addAxiom(ont, ax);
        assertTrue(ont.containsAnnotationPropertyInSignature(ap.getIRI(),
                EXCLUDED));
        assertTrue(ont.getAnnotationPropertiesInSignature(EXCLUDED)
                .contains(ap));
    }
View Full Code Here

Examples of org.semanticweb.owlapi.model.OWLOntology.containsAnnotationPropertyInSignature()

        OWLAnnotation anno = df.getOWLAnnotation(ap, val);
        OWLSubClassOfAxiom ax = df.getOWLSubClassOfAxiom(Class(iri("A")),
                Class(iri("B")), singleton(anno));
        OWLOntology ont = getOWLOntology("Ont");
        ont.getOWLOntologyManager().addAxiom(ont, ax);
        assertTrue(ont.containsAnnotationPropertyInSignature(anno.getProperty()
                .getIRI(), EXCLUDED));
        assertTrue(ont.getAnnotationPropertiesInSignature(EXCLUDED).contains(
                anno.getProperty()));
    }
View Full Code Here

Examples of org.semanticweb.owlapi.model.OWLOntology.containsAnnotationPropertyInSignature()

        OWLLiteral val = Literal("Test");
        OWLAnnotation anno = df.getOWLAnnotation(ap, val);
        OWLOntology ont = getOWLOntology("Ont");
        ont.getOWLOntologyManager().applyChange(
                new AddOntologyAnnotation(ont, anno));
        assertTrue(ont.containsAnnotationPropertyInSignature(anno.getProperty()
                .getIRI(), EXCLUDED));
        assertTrue(ont.getAnnotationPropertiesInSignature(EXCLUDED).contains(
                anno.getProperty()));
    }
}
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.