org.mindswap.pellet.tableau.blocking
Class BlockingContext

java.lang.Object
  extended by org.mindswap.pellet.tableau.blocking.BlockingContext

public class BlockingContext
extends java.lang.Object

A class to keep track of the current individual being tested for blocking conditions. Current context stores the blocker candidate and caches the incoming edges to the (possibly) blocked individual since multiple blocking conditions need to access that information.

Author:
Evren Sirin

Constructor Summary
BlockingContext(Individual blocked)
           
 
Method Summary
 boolean isInvSuccessor()
          Returns if the role from the parent of blocked candidate has any inverse super properties.
 boolean isRSuccessor(Role r)
          Returns if the blocked node is an r-successor of its parent.
 boolean moveBlockerDown(Node child)
          Sets the blocker to the specified child of the current blocker and returns if the new blocker candidate is allowed to block.
 boolean moveBlockerUp()
          Sets the blocker to the parent of current blocker and checks if if the new blocker candidate is allowed to block.
 java.lang.String toString()
           
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Constructor Detail

BlockingContext

public BlockingContext(Individual blocked)
Method Detail

moveBlockerUp

public boolean moveBlockerUp()
Sets the blocker to the parent of current blocker and checks if if the new blocker candidate is allowed to block. Root nodes are not allowed to block.

Returns:
true if the new blocker candidate is allowed to block

moveBlockerDown

public boolean moveBlockerDown(Node child)
Sets the blocker to the specified child of the current blocker and returns if the new blocker candidate is allowed to block. The child is not allowed to block if it is a literal, or a root, or pruned/merged, or is blocked itself.

Parameters:
child - child of the current blocker
Returns:
true if the new blocker candidate is allowed to block

isRSuccessor

public boolean isRSuccessor(Role r)
Returns if the blocked node is an r-successor of its parent.

Parameters:
r - the property to check for r-successor relation
Returns:
if the blocked node is an r-successor of its parent.

isInvSuccessor

public boolean isInvSuccessor()
Returns if the role from the parent of blocked candidate has any inverse super properties.

Returns:
if the role from the parent of blocked candidate has any inverse super properties

toString

public java.lang.String toString()
Overrides:
toString in class java.lang.Object


Copyright © 2004 Evren Sirin. All Rights Reserved.