Package edu.pitt.ontology

Examples of edu.pitt.ontology.LogicExpression


    // TODO Auto-generated method stub
    return new IInstance [0];
  }

  public ILogicExpression getNecessaryRestrictions() {
    return new LogicExpression(ILogicExpression.EMPTY);
  }
View Full Code Here


  /**
   * get necessary restrictions
   */
  public ILogicExpression getNecessaryRestrictions() {
    ILogicExpression exp = new LogicExpression(ILogicExpression.AND);
    for(Object o: getDirectNecessaryRestrictions())
      exp.add(o);
    for(IClass parent: getSuperClasses()){
      for(Object o: parent.getDirectNecessaryRestrictions())
        exp.add(o);
    }
    return exp;
  }
View Full Code Here

    }
    return null;
  }
  public ILogicExpression createLogicExpression(int type, Object param) {
    if(param instanceof Collection)
      return new LogicExpression(type,(Collection) param);
    else if(param instanceof Object [])
      return new LogicExpression(type,(Object []) param);
    else
      return new LogicExpression(type,param);
  }
View Full Code Here

      return new LogicExpression(type,(Object []) param);
    else
      return new LogicExpression(type,param);
  }
  public ILogicExpression createLogicExpression() {
    return new LogicExpression(ILogicExpression.EMPTY);
  }
View Full Code Here

      List<OWLOntologyChange> changes = renamer.changeIRI((OWLEntity)obj,newIRI);
      getOWLOntologyManager().applyChanges(changes);
     }
  }
  public ILogicExpression getLogicExpression() {
    return new LogicExpression(this);
  }
View Full Code Here

        }else{
          return new String("string");
        }
      }
    }else if(val instanceof OWLNaryBooleanClassExpression){
      LogicExpression exp = new LogicExpression(LogicExpression.EMPTY);
      if(val instanceof OWLObjectIntersectionOf || val instanceof OWLDataIntersectionOf)
        exp.setExpressionType(ILogicExpression.AND);
      else if(val instanceof OWLObjectUnionOf || val instanceof OWLDataUnionOf)
        exp.setExpressionType(ILogicExpression.OR);
      for(OWLClassExpression e: ((OWLNaryBooleanClassExpression)val).getOperands()){
        exp.add(convertOWLObject(e));
      }
      return exp;
    }else if(val instanceof OWLObjectComplementOf){
      LogicExpression exp = new LogicExpression(LogicExpression.NOT);
      exp.add(convertOWLObject(((OWLObjectComplementOf) val).getOperand()));
      return exp;
    }else if(val instanceof OWLRestriction){
      return new ORestriction((OWLRestriction)val,getOntology());
    }
   
View Full Code Here

      int  r = ((OWLCardinalityBase) rest).getCardinality();
      obj = new Integer(r);
    }
    if(obj instanceof ILogicExpression)
      return (ILogicExpression) obj;
    return new LogicExpression(obj);
  }
View Full Code Here

   * usually this is an empty expression with this as its parameter
   * if resource is LogicClass, then it might do something interesting
   * @return
   */
  public ILogicExpression getLogicExpression(){
    return new LogicExpression(this);
  }
View Full Code Here

TOP

Related Classes of edu.pitt.ontology.LogicExpression

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.