Package org.semanticweb.owlapi.model

Examples of org.semanticweb.owlapi.model.OWLDataIntersectionOf


    }

    @Test
    public void shouldBuildDataIntersectionOf() {
        // given
        OWLDataIntersectionOf expected = df.getOWLDataIntersectionOf(d,
                df.getFloatOWLDatatype());
        BuilderDataIntersectionOf builder = new BuilderDataIntersectionOf(
                expected, df);
        // when
        OWLObject built = builder.buildObject();
View Full Code Here


        OWLDatatype dt = Datatype(IRI("file:/c/test.owlapi#SSN"));
        OWLFacetRestriction fr = FacetRestriction(OWLFacet.PATTERN,
                Literal("[0-9]{3}-[0-9]{2}-[0-9]{4}"));
        OWLDataRange dr = DatatypeRestriction(
                Datatype(IRI("http://www.w3.org/2001/XMLSchema#string")), fr);
        OWLDataIntersectionOf disj1 = DataIntersectionOf(DataComplementOf(dr),
                dt);
        // here I negate dr
        OWLDataIntersectionOf disj2 = DataIntersectionOf(DataComplementOf(dt),
                dr);
        // here I negate dt
        OWLDataUnionOf union = DataUnionOf(disj1, disj2);
        OWLDataProperty prop = DataProperty(iri("prop"));
        OWLDataPropertyRangeAxiom ax = DataPropertyRange(prop, union);
View Full Code Here

        return DataRangeType.DATA_INTERSECTION_OF;
    }

    @Override
    protected int compareObjectOfSameType(OWLObject object) {
        OWLDataIntersectionOf other = (OWLDataIntersectionOf) object;
        return compareSets(getOperands(), other.getOperands());
    }
View Full Code Here

            return true;
        }
        if (!(obj instanceof OWLDataIntersectionOf)) {
            return false;
        }
        OWLDataIntersectionOf other = (OWLDataIntersectionOf) obj;
        return getOperands().equals(other.getOperands());
    }
View Full Code Here

            OWLDataFactory factory=reasoner.getDataFactory();
            OWLIndividual freshIndividual=factory.getOWLAnonymousIndividual("fresh-individual");
            OWLDataProperty freshDataProperty=factory.getOWLDataProperty(IRI.create("fresh-data-property"));
            OWLDataRange dataRange=axiom.getDataRange();
            OWLDatatype dt=axiom.getDatatype();
            OWLDataIntersectionOf dr1=factory.getOWLDataIntersectionOf(factory.getOWLDataComplementOf(dataRange),dt);
            OWLDataIntersectionOf dr2=factory.getOWLDataIntersectionOf(factory.getOWLDataComplementOf(dt),dataRange);
            OWLDataUnionOf union=factory.getOWLDataUnionOf(dr1,dr2);
            OWLClassExpression c=factory.getOWLDataSomeValuesFrom(freshDataProperty,union);
            OWLClassAssertionAxiom ax=factory.getOWLClassAssertionAxiom(c,freshIndividual);
            Tableau tableau=reasoner.getTableau(ax);
            return !tableau.isSatisfiable(true,true,null,null,null,null,null,ReasoningTaskDescription.isAxiomEntailed(axiom));
View Full Code Here

        return DataRangeType.DATA_INTERSECTION_OF;
    }

    @Override
  protected int compareObjectOfSameType(OWLObject object) {
        OWLDataIntersectionOf other = (OWLDataIntersectionOf) object;
        return compareSets(getOperands(), other.getOperands());
    }
View Full Code Here

            return true;
        }
        if (!(obj instanceof OWLDataIntersectionOf)) {
            return false;
        }
        OWLDataIntersectionOf other = (OWLDataIntersectionOf) obj;
        return this.getOperands().equals(other.getOperands());
    }
View Full Code Here

TOP

Related Classes of org.semanticweb.owlapi.model.OWLDataIntersectionOf

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.