com.clarkparsia.pellet.rules
Class ObjectVariableBindingHelper

java.lang.Object
  extended by com.clarkparsia.pellet.rules.ObjectVariableBindingHelper
All Implemented Interfaces:
BindingHelper

public class ObjectVariableBindingHelper
extends java.lang.Object
implements BindingHelper

Title: Object Variable Binding Helper

Description: A binding helper that will iterate over all named individuals in the abox.

Copyright: Copyright (c) 2007

Company: Clark & Parsia, LLC.

Author:
Ron Alford

Constructor Summary
ObjectVariableBindingHelper(ABox abox, AtomIVariable var)
           
 
Method Summary
 java.util.Collection<AtomIVariable> getBindableVars(java.util.Collection<AtomVariable> bound)
          Returns a set of variables which this binding helper can bind.
 java.util.Collection<AtomIVariable> getPrerequisiteVars(java.util.Collection<AtomVariable> bound)
          Returns a set of variables which must be bound before this helper can generate bindings.
 void rebind(VariableBinding newBinding)
          Set the incoming binding for this helper.
 boolean selectNextBinding()
          Selects the next binding.
 void setCurrentBinding(VariableBinding currentBinding)
          Set the variables this pattern uses in the given map.
 java.lang.String toString()
           
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Constructor Detail

ObjectVariableBindingHelper

public ObjectVariableBindingHelper(ABox abox,
                                   AtomIVariable var)
Method Detail

getBindableVars

public java.util.Collection<AtomIVariable> getBindableVars(java.util.Collection<AtomVariable> bound)
Description copied from interface: BindingHelper
Returns a set of variables which this binding helper can bind.

Specified by:
getBindableVars in interface BindingHelper

getPrerequisiteVars

public java.util.Collection<AtomIVariable> getPrerequisiteVars(java.util.Collection<AtomVariable> bound)
Description copied from interface: BindingHelper
Returns a set of variables which must be bound before this helper can generate bindings.

Specified by:
getPrerequisiteVars in interface BindingHelper

rebind

public void rebind(VariableBinding newBinding)
Description copied from interface: BindingHelper
Set the incoming binding for this helper. This fixes any variables that are already bound by a preceding Binding Helper.

Specified by:
rebind in interface BindingHelper
Parameters:
newBinding - Binding map. Implementation will copy map if needed.

selectNextBinding

public boolean selectNextBinding()
Description copied from interface: BindingHelper
Selects the next binding.

Specified by:
selectNextBinding in interface BindingHelper
Returns:
True if a binding was available for this pattern given the initial binding. False otherwise. Will return if the binding is not set.

setCurrentBinding

public void setCurrentBinding(VariableBinding currentBinding)
Description copied from interface: BindingHelper
Set the variables this pattern uses in the given map.

Specified by:
setCurrentBinding in interface BindingHelper

toString

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


Copyright © 2004 Evren Sirin. All Rights Reserved.