org.deri.wsmo4j.logicalexpression.util
Class VisitorContainsCheck

java.lang.Object
  extended by org.deri.wsmo4j.logicalexpression.util.VisitorContainsCheck
All Implemented Interfaces:
org.omwg.logicalexpression.Visitor

public class VisitorContainsCheck
extends Object
implements org.omwg.logicalexpression.Visitor

Class to check if a specified operator of a logical expression is contained in an array of operators


Constructor Summary
protected VisitorContainsCheck(Class[] operators)
           
 
Method Summary
protected  boolean isContained()
          Checks if the previous logexp the visitor was applied to, contained the compound expression with the operator passed in constructor.
 void visitAtom(org.omwg.logicalexpression.Atom expr)
          Empty method, as an Atom can't contain an operator
 void visitAttributeContraintMolecule(org.omwg.logicalexpression.AttributeConstraintMolecule expr)
           
 void visitAttributeInferenceMolecule(org.omwg.logicalexpression.AttributeInferenceMolecule expr)
           
 void visitAttributeValueMolecule(org.omwg.logicalexpression.AttributeValueMolecule expr)
           
 void visitCompoundMolecule(org.omwg.logicalexpression.CompoundMolecule expr)
           
 void visitConjunction(org.omwg.logicalexpression.Conjunction expr)
          Checks if the operator of the Binary expression is contained in the array of operators
 void visitConstraint(org.omwg.logicalexpression.Constraint expr)
          Checks if the operator of the Unary expression is contained in the array of operators
 void visitDisjunction(org.omwg.logicalexpression.Disjunction expr)
          Checks if the operator of the Binary expression is contained in the array of operators
 void visitEquivalence(org.omwg.logicalexpression.Equivalence expr)
          Checks if the operator of the Binary expression is contained in the array of operators
 void visitExistentialQuantification(org.omwg.logicalexpression.ExistentialQuantification expr)
          Checks if the operator of the Quantified expression is contained in the array of operators
 void visitImplication(org.omwg.logicalexpression.Implication expr)
          Checks if the operator of the Binary expression is contained in the array of operators
 void visitInverseImplication(org.omwg.logicalexpression.InverseImplication expr)
          Checks if the operator of the Binary expression is contained in the array of operators
 void visitLogicProgrammingRule(org.omwg.logicalexpression.LogicProgrammingRule expr)
          Checks if the operator of the Binary expression is contained in the array of operators
 void visitMemberShipMolecule(org.omwg.logicalexpression.MembershipMolecule expr)
           
 void visitNegation(org.omwg.logicalexpression.Negation expr)
          Checks if the operator of the Unary expression is contained in the array of operators
 void visitNegationAsFailure(org.omwg.logicalexpression.NegationAsFailure expr)
          Checks if the operator of the Unary expression is contained in the array of operators
 void visitSubConceptMolecule(org.omwg.logicalexpression.SubConceptMolecule expr)
           
 void visitUniversalQuantification(org.omwg.logicalexpression.UniversalQuantification expr)
          Checks if the operator of the Quantified expression is contained in the array of operators
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

VisitorContainsCheck

protected VisitorContainsCheck(Class[] operators)
Parameters:
operators - array of classes that will be checked for
See Also:
ExpressionContainmentUtil.contains(LogicalExpression, Class)
Method Detail

visitAtom

public void visitAtom(org.omwg.logicalexpression.Atom expr)
Empty method, as an Atom can't contain an operator

Specified by:
visitAtom in interface org.omwg.logicalexpression.Visitor
See Also:
Visitor.visitAtom(org.omwg.logicalexpression.Atom)

visitNegationAsFailure

public void visitNegationAsFailure(org.omwg.logicalexpression.NegationAsFailure expr)
Checks if the operator of the Unary expression is contained in the array of operators

Specified by:
visitNegationAsFailure in interface org.omwg.logicalexpression.Visitor
See Also:
Visitor.visitNegationAsFailure(NegationAsFailure)

visitNegation

public void visitNegation(org.omwg.logicalexpression.Negation expr)
Checks if the operator of the Unary expression is contained in the array of operators

Specified by:
visitNegation in interface org.omwg.logicalexpression.Visitor
See Also:
Visitor.visitNegation(Negation)

visitConstraint

public void visitConstraint(org.omwg.logicalexpression.Constraint expr)
Checks if the operator of the Unary expression is contained in the array of operators

Specified by:
visitConstraint in interface org.omwg.logicalexpression.Visitor
See Also:
Visitor.visitConstraint(Constraint)

visitConjunction

public void visitConjunction(org.omwg.logicalexpression.Conjunction expr)
Checks if the operator of the Binary expression is contained in the array of operators

Specified by:
visitConjunction in interface org.omwg.logicalexpression.Visitor
See Also:
Visitor.visitConjunction(Conjunction)

visitEquivalence

public void visitEquivalence(org.omwg.logicalexpression.Equivalence expr)
Checks if the operator of the Binary expression is contained in the array of operators

Specified by:
visitEquivalence in interface org.omwg.logicalexpression.Visitor
See Also:
Visitor.visitEquivalence(Equivalence)

visitInverseImplication

public void visitInverseImplication(org.omwg.logicalexpression.InverseImplication expr)
Checks if the operator of the Binary expression is contained in the array of operators

Specified by:
visitInverseImplication in interface org.omwg.logicalexpression.Visitor
See Also:
Visitor.visitInverseImplication(InverseImplication)

visitImplication

public void visitImplication(org.omwg.logicalexpression.Implication expr)
Checks if the operator of the Binary expression is contained in the array of operators

Specified by:
visitImplication in interface org.omwg.logicalexpression.Visitor
See Also:
Visitor.visitImplication(Implication)

visitLogicProgrammingRule

public void visitLogicProgrammingRule(org.omwg.logicalexpression.LogicProgrammingRule expr)
Checks if the operator of the Binary expression is contained in the array of operators

Specified by:
visitLogicProgrammingRule in interface org.omwg.logicalexpression.Visitor
See Also:
Visitor.visitLogicProgrammingRule(LogicProgrammingRule)

visitDisjunction

public void visitDisjunction(org.omwg.logicalexpression.Disjunction expr)
Checks if the operator of the Binary expression is contained in the array of operators

Specified by:
visitDisjunction in interface org.omwg.logicalexpression.Visitor
See Also:
Visitor.visitDisjunction(Disjunction)

visitUniversalQuantification

public void visitUniversalQuantification(org.omwg.logicalexpression.UniversalQuantification expr)
Checks if the operator of the Quantified expression is contained in the array of operators

Specified by:
visitUniversalQuantification in interface org.omwg.logicalexpression.Visitor
See Also:
Visitor.visitUniversalQuantification(UniversalQuantification)

visitExistentialQuantification

public void visitExistentialQuantification(org.omwg.logicalexpression.ExistentialQuantification expr)
Checks if the operator of the Quantified expression is contained in the array of operators

Specified by:
visitExistentialQuantification in interface org.omwg.logicalexpression.Visitor
See Also:
Visitor.visitExistentialQuantification(ExistentialQuantification)

isContained

protected boolean isContained()
Checks if the previous logexp the visitor was applied to, contained the compound expression with the operator passed in constructor. So it checks if this logexp contained a specified operator.

Returns:
true if it is contained

visitAttributeContraintMolecule

public void visitAttributeContraintMolecule(org.omwg.logicalexpression.AttributeConstraintMolecule expr)
Specified by:
visitAttributeContraintMolecule in interface org.omwg.logicalexpression.Visitor

visitAttributeInferenceMolecule

public void visitAttributeInferenceMolecule(org.omwg.logicalexpression.AttributeInferenceMolecule expr)
Specified by:
visitAttributeInferenceMolecule in interface org.omwg.logicalexpression.Visitor

visitAttributeValueMolecule

public void visitAttributeValueMolecule(org.omwg.logicalexpression.AttributeValueMolecule expr)
Specified by:
visitAttributeValueMolecule in interface org.omwg.logicalexpression.Visitor

visitCompoundMolecule

public void visitCompoundMolecule(org.omwg.logicalexpression.CompoundMolecule expr)
Specified by:
visitCompoundMolecule in interface org.omwg.logicalexpression.Visitor

visitMemberShipMolecule

public void visitMemberShipMolecule(org.omwg.logicalexpression.MembershipMolecule expr)
Specified by:
visitMemberShipMolecule in interface org.omwg.logicalexpression.Visitor

visitSubConceptMolecule

public void visitSubConceptMolecule(org.omwg.logicalexpression.SubConceptMolecule expr)
Specified by:
visitSubConceptMolecule in interface org.omwg.logicalexpression.Visitor


Copyright © 2004-2008 Ontotext Lab.. All Rights Reserved.