Package org.semanticweb.owl.model

Examples of org.semanticweb.owl.model.OWLObjectPropertyExpression


        return !isAnonymous(object);
    }


    public void handleTriple(URI subject, URI predicate, URI object) throws OWLException {
        OWLObjectPropertyExpression prop = translateObjectProperty(subject);
        OWLDescription domain = translateDescription(subject);
        addAxiom(getDataFactory().getOWLObjectPropertyDomainAxiom(prop, domain));
    }
View Full Code Here


    }

    @Override
    public void handleTriple(URI subject, URI predicate, URI object) throws OWLException {
        List<OWLObjectPropertyExpression> subList = getConsumer().translateToObjectPropertyList(object);
        OWLObjectPropertyExpression superProperty = translateObjectProperty(subject);
        addAxiom(getDataFactory().getOWLObjectPropertyChainSubPropertyAxiom(subList, superProperty));
        consumeTriple(subject, predicate, object);
    }
View Full Code Here

        super(consumer);
    }


    protected OWLDescription translateRestriction(URI mainNode) throws OWLException {
        OWLObjectPropertyExpression prop = translateOnProperty(mainNode);
        boolean valid = false;
        OWLConstant con = getLiteralObject(mainNode, OWLRDFVocabulary.OWL_HAS_SELF.getURI(), true);
        if (con == null) {
            valid = getConsumer().isSelfRestriction(mainNode);
        } else {
View Full Code Here

    protected OWLDescription translateRestriction(URI mainNode) throws OWLException {
        URI hasValueObject = getResourceObject(mainNode, OWLRDFVocabulary.OWL_HAS_VALUE.getURI(), true);
        if (hasValueObject == null) {
            throw new MalformedDescriptionException(OWLRDFVocabulary.OWL_HAS_VALUE + " triple not present");
        }
        OWLObjectPropertyExpression prop = translateOnProperty(mainNode);
        OWLIndividual ind = getConsumer().getOWLIndividual(hasValueObject);
        getConsumer().addIndividual(ind.getURI());
        return getDataFactory().getOWLObjectValueRestriction(prop, ind);
    }
View Full Code Here

        if( targetIndividualURI != null ) {
            if( targetValue != null ) {
                throw new OWLRDFXMLParserMalformedNodeException(
                        "owl:targetIndividual and owl:targetValue triples with the same subject");
            }
            final OWLObjectPropertyExpression assertionProperty = translateObjectProperty(assertionPropertyURI);
            final OWLIndividual targetIndividual = translateIndividual(targetIndividualURI);
            ax = getDataFactory().getOWLNegativeObjectPropertyAssertionAxiom(sourceIndividual,
                    assertionProperty, targetIndividual);
        }
        else {
View Full Code Here

        Set<OWLObjectPropertyExpression> props = getOperands();
        if(props.size() > 2 || props.size() < 1) {
            throw new OWLXMLParserElementNotFoundException(getLineNumber(), "Expected 2 object property expression elements");
        }
        Iterator<OWLObjectPropertyExpression> it = props.iterator();
        OWLObjectPropertyExpression propA = it.next();
        OWLObjectPropertyExpression propB;
        if(it.hasNext()) {
            propB = it.next();
        }
        else {
            // Syntactic variant of symmetric property
View Full Code Here

      obj = factory.getOWLDataOneOf( (OWLConstant) obj );
  }

  public void visitSelf(ATermAppl term) {
    visit( (ATermAppl) term.getArgument( 0 ) );
    OWLObjectPropertyExpression prop = (OWLObjectPropertyExpression) obj;

    obj = factory.getOWLObjectSelfRestriction( prop );

  }
View Full Code Here

  /**
   * {@inheritDoc}
   */
  public void visitInverse(ATermAppl p) {
    OWLObjectPropertyExpression prop = (OWLObjectPropertyExpression) convert( (ATermAppl) p
        .getArgument( 0 ) );

    obj = factory.getOWLObjectPropertyInverse( prop );
  }
View Full Code Here

    else if( term.getAFun().equals( ATermUtils.SUBPROPFUN ) ) {
      if( term.getArgument( 0 ) instanceof ATermList ) {
        List<OWLObjectPropertyExpression> subs = new ArrayList<OWLObjectPropertyExpression>();
        for( ATermList list = (ATermList) term.getArgument( 0 ); !list.isEmpty(); list = list
            .getNext() ) {
          OWLObjectPropertyExpression p = (OWLObjectPropertyExpression) conceptConverter
              .convert( (ATermAppl) list.getFirst() );
          if( p == null ) {
            subs = null;
            break;
          }
View Full Code Here

TOP

Related Classes of org.semanticweb.owl.model.OWLObjectPropertyExpression

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.