当前位置: 首页>>代码示例>>Java>>正文


Java OWLObjectPropertyRangeAxiom类代码示例

本文整理汇总了Java中org.semanticweb.owlapi.model.OWLObjectPropertyRangeAxiom的典型用法代码示例。如果您正苦于以下问题:Java OWLObjectPropertyRangeAxiom类的具体用法?Java OWLObjectPropertyRangeAxiom怎么用?Java OWLObjectPropertyRangeAxiom使用的例子?那么, 这里精选的类代码示例或许可以为您提供帮助。


OWLObjectPropertyRangeAxiom类属于org.semanticweb.owlapi.model包,在下文中一共展示了OWLObjectPropertyRangeAxiom类的15个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Java代码示例。

示例1: visit

import org.semanticweb.owlapi.model.OWLObjectPropertyRangeAxiom; //导入依赖的package包/类
public void visit(OWLObjectPropertyRangeAxiom axiom) {
        try {
            OWLObjectProperty op = Utils.ensureObjectProperty(axiom.getProperty());
            OWLClass clz = Utils.ensureClass(axiom.getRange());

            opRanges.put(op, clz);
//            processSubClassConstraintCandidate(f.getOWLThing(),
//                OWLManager.getOWLDataFactory().getOWLObjectAllValuesFrom(op, clz));
        } catch (UnsupportedICException e) {
            notSupported(axiom);
        }
    }
 
开发者ID:kbss-cvut,项目名称:jopa,代码行数:13,代码来源:IntegrityConstraintParser.java

示例2: visit

import org.semanticweb.owlapi.model.OWLObjectPropertyRangeAxiom; //导入依赖的package包/类
@Override
public T visit(OWLObjectPropertyRangeAxiom axiom) {
	throw new IllegalArgumentException(
			OWLObjectPropertyRangeAxiom.class.getSimpleName()
					+ " cannot be converted to "
					+ getTargetClass().getSimpleName());
}
 
开发者ID:liveontologies,项目名称:elk-reasoner,代码行数:8,代码来源:AbstractOwlAxiomConverterVisitor.java

示例3: getRange

import org.semanticweb.owlapi.model.OWLObjectPropertyRangeAxiom; //导入依赖的package包/类
/**
 * It returns the (first) value of the range tag
 * 
 * @param prop
 * @return range or null
 */
public String getRange(OWLObjectProperty prop){
	for(OWLObjectPropertyRangeAxiom axiom : sourceOntology.getObjectPropertyRangeAxioms(prop)) {
		OWLClassExpression ce = axiom.getRange();
		return getIdentifier(ce);
	}
	return null;
}
 
开发者ID:owlcollab,项目名称:owltools,代码行数:14,代码来源:OWLGraphWrapperExtended.java

示例4: visit

import org.semanticweb.owlapi.model.OWLObjectPropertyRangeAxiom; //导入依赖的package包/类
@Override
public Set<ComplexIntegerAxiom> visit(OWLObjectPropertyRangeAxiom axiom) throws TranslationException {
	Objects.requireNonNull(axiom);
	OWLObjectProperty property = asOWLObjectProperty(axiom.getProperty());
	OWLClassExpression classExpression = axiom.getRange();
	IntegerObjectProperty propExpr = getDataTypeFactory().createObjectProperty(translateObjectProperty(property));
	ComplexIntegerAxiom ret = getAxiomFactory().createPropertyRangeAxiom(propExpr,
			translateClassExpression(classExpression), translateAnnotations(axiom.getAnnotations()));
	return Collections.singleton(ret);
}
 
开发者ID:julianmendez,项目名称:jcel,代码行数:11,代码来源:AxiomTranslator.java

示例5: visit

import org.semanticweb.owlapi.model.OWLObjectPropertyRangeAxiom; //导入依赖的package包/类
/**
 * A utility method to process OWL <code>ObjectPropertyRange(OPE CE)</code> axiom and produce
 * inferred mapping assertions. This axiom is equivalent to
 * <code>SubClassOf(ObjectSomeValuesFrom(ObjectInverseOf(OPE) owl:Thing) CE)</code>.
 */
@Override
public void visit(OWLObjectPropertyRangeAxiom axiom)
{
   asSubClassOfAxiom(axiom).accept(this);
   resetIsInverse(); // reset the isInverse = false.
}
 
开发者ID:obidea,项目名称:semantika,代码行数:12,代码来源:TMappingProcessor.java

示例6: visit

import org.semanticweb.owlapi.model.OWLObjectPropertyRangeAxiom; //导入依赖的package包/类
@Override
public void visit(OWLObjectPropertyRangeAxiom axiom)
{
   addSubClassAxiom(asSubClassOfAxiom(axiom));
   
   OWLObjectPropertyExpression op = axiom.getProperty();
   OwlNodeSet<OWLPropertyExpression<?,?>> descendants = mPropertyStructureHandler.getDescendants(op, false);
   for (OwlNode<OWLPropertyExpression<?,?>> node : descendants.getNodes()) {
      op = (OWLObjectPropertyExpression) node.getEntity();
      axiom = mOwlDataFactory.getOWLObjectPropertyRangeAxiom(op, axiom.getRange());
      addSubClassAxiom(asSubClassOfAxiom(axiom));
   }
}
 
开发者ID:obidea,项目名称:semantika,代码行数:14,代码来源:OwlClassStructureHandler.java

示例7: asSubClassOfAxiom

import org.semanticweb.owlapi.model.OWLObjectPropertyRangeAxiom; //导入依赖的package包/类
private OWLSubClassOfAxiom asSubClassOfAxiom(OWLObjectPropertyRangeAxiom axiom)
{
   OWLObjectInverseOf inverseExpression = mOwlDataFactory.getOWLObjectInverseOf(axiom.getProperty());
   OWLClassExpression classExpression = axiom.getRange();
   OWLClassExpression sub = mOwlDataFactory.getOWLObjectSomeValuesFrom(inverseExpression, mOwlDataFactory.getOWLThing());
   return mOwlDataFactory.getOWLSubClassOfAxiom(sub, classExpression);
}
 
开发者ID:obidea,项目名称:semantika,代码行数:8,代码来源:OwlClassStructureHandler.java

示例8: visit

import org.semanticweb.owlapi.model.OWLObjectPropertyRangeAxiom; //导入依赖的package包/类
@Override
public void visit(OWLObjectPropertyRangeAxiom axiom) {
	OWLSubClassOfAxiom subClassOfAxiom = axiom.asOWLSubClassOfAxiom();
	subClassOfAxiom.accept(this);
	String tmp = subjectVar;
	subjectVar = objectVar;
	objectVar = tmp;
}
 
开发者ID:SmartDataAnalytics,项目名称:OWL2SPARQL,代码行数:9,代码来源:OWLAxiomToSPARQLConverter.java

示例9: visit

import org.semanticweb.owlapi.model.OWLObjectPropertyRangeAxiom; //导入依赖的package包/类
@Override
public void visit(OWLObjectPropertyRangeAxiom axiom) {
    hashCode = primes[26];
    hashCode = hashCode * MULT + axiom.getProperty().hashCode();
    hashCode = hashCode * MULT + axiom.getRange().hashCode();
    hashCode = hashCode * MULT + axiom.getAnnotations().hashCode();
}
 
开发者ID:matthewhorridge,项目名称:owlapi-gwt,代码行数:8,代码来源:HashCode.java

示例10: equals

import org.semanticweb.owlapi.model.OWLObjectPropertyRangeAxiom; //导入依赖的package包/类
@Override
public boolean equals(Object obj) {
    if (this == obj) {
        return true;
    }
    if (!super.equals(obj)) {
        return false;
    }
    return obj instanceof OWLObjectPropertyRangeAxiom;
}
 
开发者ID:matthewhorridge,项目名称:owlapi-gwt,代码行数:11,代码来源:OWLObjectPropertyRangeAxiomImpl.java

示例11: getAxiomWithoutAnnotations

import org.semanticweb.owlapi.model.OWLObjectPropertyRangeAxiom; //导入依赖的package包/类
@Nonnull
@Override
public OWLObjectPropertyRangeAxiom getAxiomWithoutAnnotations() {
    if (!isAnnotated()) {
        return this;
    }
    return new OWLObjectPropertyRangeAxiomImpl(getProperty(), getRange(),
            NO_ANNOTATIONS);
}
 
开发者ID:matthewhorridge,项目名称:owlapi-gwt,代码行数:10,代码来源:OWLObjectPropertyRangeAxiomImpl.java

示例12: visit

import org.semanticweb.owlapi.model.OWLObjectPropertyRangeAxiom; //导入依赖的package包/类
public Object visit(OWLSubPropertyChainOfAxiom axiom) {
     Set<OWLObjectPropertyRangeAxiom> rangeAxioms = getCurrentOntology().getAxioms(AxiomType.OBJECT_PROPERTY_RANGE, true);
     if (rangeAxioms.isEmpty()) {
return false;
     }

     // Do we have a range restriction imposed on our super property?
     for (OWLObjectPropertyRangeAxiom rngAx : rangeAxioms) {
if (getPropertyManager().isSubPropertyOf(axiom.getSuperProperty(), rngAx.getProperty())) {
  // Imposed range restriction!
  OWLClassExpression imposedRange = rngAx.getRange();
  // There must be an axiom that imposes a range on the last prop in the chain
  List<OWLObjectPropertyExpression> chain = axiom.getPropertyChain();
  if (!chain.isEmpty()) {
    OWLObjectPropertyExpression lastProperty = chain.get(chain.size() - 1);
    boolean rngPresent = false;
    for (OWLOntology ont : getCurrentOntology().getImportsClosure()) {
      for (OWLObjectPropertyRangeAxiom lastPropRngAx : ont.getObjectPropertyRangeAxioms(lastProperty)) {
	if (lastPropRngAx.getRange().equals(imposedRange)) {
	  // We're o.k.
	  rngPresent = true;
	  break;
	}
      }
    }
    if (!rngPresent) {
      profileViolations.add(new LastPropertyInChainNotInImposedRange(getCurrentOntology(), axiom, rngAx));
    }
  }
}
     }


     return null;
   }
 
开发者ID:ag-csw,项目名称:SVoNt,代码行数:36,代码来源:PelletOWL2ELProfile.java

示例13: visit

import org.semanticweb.owlapi.model.OWLObjectPropertyRangeAxiom; //导入依赖的package包/类
public void visit(OWLObjectPropertyRangeAxiom axiom) {
    OWLObjectAllValuesFrom allPropertyRange=m_factory.getOWLObjectAllValuesFrom(axiom.getProperty().getSimplified(),positive(axiom.getRange()));
    m_classExpressionInclusionsAsDisjunctions.add(new OWLClassExpression[] { allPropertyRange });
}
 
开发者ID:robertoyus,项目名称:HermiT-android,代码行数:5,代码来源:OWLNormalization.java

示例14: visit

import org.semanticweb.owlapi.model.OWLObjectPropertyRangeAxiom; //导入依赖的package包/类
public Boolean visit(OWLObjectPropertyRangeAxiom axiom) {
    return reasoner.isSubClassOf(factory.getOWLThing(),factory.getOWLObjectAllValuesFrom(axiom.getProperty(),axiom.getRange()));
}
 
开发者ID:robertoyus,项目名称:HermiT-android,代码行数:4,代码来源:EntailmentChecker.java

示例15: visit

import org.semanticweb.owlapi.model.OWLObjectPropertyRangeAxiom; //导入依赖的package包/类
@Override
public OWLObjectPropertyRangeAxiom visit(
		ElkObjectPropertyRangeAxiom axiom) {
	return owlFactory_.getOWLObjectPropertyRangeAxiom(
			convert(axiom.getProperty()), convert(axiom.getRange()));
}
 
开发者ID:liveontologies,项目名称:elk-reasoner,代码行数:7,代码来源:AbstractElkObjectConverter.java


注:本文中的org.semanticweb.owlapi.model.OWLObjectPropertyRangeAxiom类示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。