Package org.semanticweb.owlapi.vocab

Examples of org.semanticweb.owlapi.vocab.OWLFacet


                // Restricted data range
                consumeToken();
                String sep = COMMA.keyword();
                Set<OWLFacetRestriction> facetRestrictions = new HashSet<>();
                while (COMMA.matches(sep)) {
                    OWLFacet fv = parseFacet();
                    if (fv == null) {
                        throw new ExceptionBuilder().withKeyword(
                                OWLFacet.getFacets()).build();
                    }
                    OWLLiteral con = parseLiteral(datatype);
View Full Code Here


        OWLDatatype intDatatype = factory.getIntegerOWLDatatype();
        // Create the value "18", which is an int.
        OWLLiteral eighteenConstant = factory.getOWLLiteral(18);
        // Now create our custom datarange, which is int greater than or equal
        // to 18. To do this, we need the minInclusive facet
        OWLFacet facet = MIN_INCLUSIVE;
        // Create the restricted data range by applying the facet restriction
        // with a value of 18 to int
        OWLDataRange intGreaterThan18 = factory.getOWLDatatypeRestriction(
                intDatatype, facet, eighteenConstant);
        // Now we can use this in our datatype restriction on hasAge
View Full Code Here

        OWLDatatype intDatatype = factory.getIntegerOWLDatatype();
        // Create the value "18", which is an int.
        OWLLiteral eighteenConstant = factory.getOWLLiteral(18);
        // Now create our custom datarange, which is int greater than or equal
        // to 18. To do this, we need the minInclusive facet
        OWLFacet facet = MIN_INCLUSIVE;
        // Create the restricted data range by applying the facet restriction
        // with a value of 18 to int
        OWLDataRange intGreaterThan18 = factory.getOWLDatatypeRestriction(
                intDatatype, facet, eighteenConstant);
        // Now we can use this in our datatype restriction on hasAge
View Full Code Here

        }
        throw new Error("Missing return statement in function");
    }

    final public OWLDataRange DataRangeRestriction() throws ParseException {
        OWLFacet v;
        OWLDatatype rng;
        OWLFacetRestriction facetRestriction;
        Set<OWLFacetRestriction> facetRestrictions = new HashSet<OWLFacetRestriction>();
        jj_consume_token(DATATYPERESTRICTION);
        jj_consume_token(OPENPAR);
View Full Code Here

            throws ParseException {
        IRI iri;
        OWLLiteral con;
        iri = IRI();
        con = Literal();
        OWLFacet v = OWLFacet.getFacetByShortName(iri.getFragment());
        {
            if ("" != null) {
                return dataFactory.getOWLFacetRestriction(v, con);
            }
        }
View Full Code Here

                       
                        Literal lit = getLiteral(l);
                       
                        if(lit != null) {
                            checkInconsistentProperty(dp, l.getDatatype());
                            OWLFacet facet = fr.getFacet();
                           
                            switch(facet) {
                                case MAX_EXCLUSIVE:
                                    conjuncts.add(new Datatype(f, Operator.LESS_THAN, lit));
                                    break;
View Full Code Here

                // Restricted data range
                consumeToken();
                String sep = ",";
                Set<OWLFacetRestriction> facetRestrictions = new HashSet<OWLFacetRestriction>();
                while (sep.equals(",")) {
                    OWLFacet fv = parseFacet();
                    if (fv == null) {
                        throw createException(OWLFacet.getFacets().toArray(new String[OWLFacet.getFacetIRIs().size()]));
                    }
          OWLLiteral con = parseConstant();
          // if (!con.isRDFPlainLiteral()) {
View Full Code Here

  final public OWLFacetRestriction DataRangeFacetRestriction() throws ParseException {
    IRI iri;
    OWLLiteral con;
    iri = IRI();
    con = Literal();
        OWLFacet v = OWLFacet.getFacetByShortName(iri.getFragment());
        return dataFactory.getOWLFacetRestriction(v, con);
   
  }
View Full Code Here

TOP

Related Classes of org.semanticweb.owlapi.vocab.OWLFacet

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.