Package au.csiro.ontology.model

Examples of au.csiro.ontology.model.Axiom


                } else if (ent.isOWLDataProperty()) {
                    // Do nothing for now.
                }
            } else if (axiom instanceof OWLSubPropertyChainOfAxiom) {
                OWLSubPropertyChainOfAxiom a = (OWLSubPropertyChainOfAxiom) axiom;
                Axiom ax = transformOWLSubPropertyChainOfAxiom(a);
                if(ax != null) res.add(ax);
                monitor.step(workDone, totalAxioms);
            } else if (axiom instanceof OWLSubObjectPropertyOfAxiom) {
                OWLSubObjectPropertyOfAxiom a = (OWLSubObjectPropertyOfAxiom) axiom;
                res.add(transformOWLSubObjectPropertyOfAxiom(a));
                monitor.step(++workDone, totalAxioms);
            } else if (axiom instanceof OWLReflexiveObjectPropertyAxiom) {
                OWLReflexiveObjectPropertyAxiom a = (OWLReflexiveObjectPropertyAxiom) axiom;
                res.add(transformOWLReflexiveObjectPropertyAxiom(a));
                monitor.step(++workDone, totalAxioms);
            } else if (axiom instanceof OWLTransitiveObjectPropertyAxiom) {
                OWLTransitiveObjectPropertyAxiom a = (OWLTransitiveObjectPropertyAxiom) axiom;
                res.add(transformOWLTransitiveObjectPropertyAxiom(a));
                monitor.step(++workDone, totalAxioms);
            } else if (axiom instanceof OWLSubClassOfAxiom) {
                OWLSubClassOfAxiom a = (OWLSubClassOfAxiom) axiom;
                Axiom ax = transformOWLSubClassOfAxiom(a);
                if(ax != null) res.add(ax);
                monitor.step(++workDone, totalAxioms);
            } else if (axiom instanceof OWLEquivalentClassesAxiom) {
                OWLEquivalentClassesAxiom a = (OWLEquivalentClassesAxiom) axiom;
                res.addAll(transformOWLEquivalentClassesAxiom(a));
                monitor.step(++workDone, totalAxioms);
            } else if (axiom instanceof OWLDisjointClassesAxiom) {
                OWLDisjointClassesAxiom a = (OWLDisjointClassesAxiom) axiom;
                Axiom ax = transformOWLDisjointClassesAxiom(a);
                if(ax != null) res.add(ax);
                monitor.step(++workDone, totalAxioms);
            } else if (axiom instanceof OWLEquivalentObjectPropertiesAxiom) {
                OWLEquivalentObjectPropertiesAxiom a = (OWLEquivalentObjectPropertiesAxiom) axiom;
                res.addAll(transformOWLEquivalentObjectPropertiesAxiom(a));
View Full Code Here


    @Override
    public void loadAxioms(Iterator<Axiom> axioms) {
        Set<Axiom> axiomSet = new HashSet<Axiom>();
        while(axioms.hasNext()) {
            Axiom axiom = axioms.next();
            if(axiom == null) continue;
            axiomSet.add(axiom);
            if(axiomSet.size() == BUFFER_SIZE) {
                loadAxioms(axiomSet);
                axiomSet.clear();
View Full Code Here

        uuidToDescMap.put(newId, "Special Appendicits");
       
        Concept specialAppendicitis = f.createNamedConcept(newId);
        String appendicitsUuid = "55450fab-6786-394d-89f9-a0fd44bd7e7e";
        Concept appendicitis = f.createNamedConcept(appendicitsUuid);
        Axiom a1 = f.createConceptInclusion(specialAppendicitis, appendicitis);
        Set<Axiom> axioms = new HashSet<Axiom>();
        axioms.add(a1);
       
        // 4. Classify incrementally
        System.out.println("Classifying incrementally");
View Full Code Here

        Feature hasWidth = f.createNamedFeature("hasWidth");
       
        Set<Axiom> axioms = new HashSet<Axiom>();
       
        // This is an example of a primitive child with no roles.
        Axiom a0 = new ConceptInclusion(glassBottle, bottle);
        axioms.add(a0);
       
        // This is an example of a fully defined child with one role. In this
        // case two axioms are needed because the API does not support
        // equivalence directly.
        Axiom a1 = new ConceptInclusion(
                plasticBottle,
                f.createConjunction(
                        bottle,
                        f.createExistential(isMadeOf, plastic)
                )
        );
        Axiom a1b = new ConceptInclusion(
                f.createConjunction(
                        bottle,
                        f.createExistential(isMadeOf, plastic)
                ),
                plasticBottle
        );
        axioms.add(a1);
        axioms.add(a1b);
       
        // This is an example of a primitive child with no roles
        Axiom a2 = new ConceptInclusion(
                purplePlasticBottle,
                plasticBottle
        );
        axioms.add(a2);
       
        // This is an example of a fully defined child with a concrete domain
        Axiom a3 = new ConceptInclusion(
                tallBottle,
                f.createConjunction(
                        bottle,
                        f.createDatatype(
                                hasHeight,
                                Operator.GREATER_THAN,
                                f.createIntegerLiteral(5))
                )
        );
       
        Axiom a3b = new ConceptInclusion(
                f.createConjunction(
                        bottle,
                        f.createDatatype(
                                hasHeight,
                                Operator.GREATER_THAN,
                                f.createIntegerLiteral(5))
                ),
                tallBottle
        );
        axioms.add(a3);
        axioms.add(a3b);
       
        // This is another example of a fully defined child with a concrete
        // domain
        Axiom a4 = new ConceptInclusion(
                wideBottle,
                f.createConjunction(
                        bottle,
                        f.createDatatype(
                                hasWidth,
                                Operator.GREATER_THAN,
                                f.createIntegerLiteral(5))
                )
        );
       
        Axiom a4b = new ConceptInclusion(
                f.createConjunction(
                        bottle,
                        f.createDatatype(
                                hasWidth,
                                Operator.GREATER_THAN,
                                f.createIntegerLiteral(5))
                ),
                wideBottle
        );
        axioms.add(a4);
        axioms.add(a4b);
       
        // Yet another example of a fully defined child with a concrete domain
        Axiom a5 = new ConceptInclusion(
                wineBottle,
                f.createConjunction(
                        glassBottle,
                        f.createDatatype(
                                hasWidth,
                                Operator.EQUALS,
                                f.createIntegerLiteral(2)),
                        f.createDatatype(
                                hasHeight,
                                Operator.EQUALS,
                                f.createIntegerLiteral(6))
                )
        );
        Axiom a5b = new ConceptInclusion(
                f.createConjunction(
                        glassBottle,
                        f.createDatatype(
                                hasWidth,
                                Operator.EQUALS,
View Full Code Here

    @Override
    public void loadAxioms(Iterator<Axiom> axioms) {
        Set<Axiom> axiomSet = new HashSet<Axiom>();
        while(axioms.hasNext()) {
            Axiom axiom = axioms.next();
            if(axiom == null) continue;
            axiomSet.add(axiom);
            if(axiomSet.size() == BUFFER_SIZE) {
                loadAxioms(axiomSet);
                axiomSet.clear();
View Full Code Here

TOP

Related Classes of au.csiro.ontology.model.Axiom

Copyright © 2018 www.massapicom. 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.