net.openai.util.fsm
Class NotCondition

java.lang.Object
  extended by net.openai.util.fsm.AbstractCondition
      extended by net.openai.util.fsm.NotCondition
All Implemented Interfaces:
java.io.Serializable, Condition

public final class NotCondition
extends AbstractCondition

This condition works as a negation operator to another condition.

See Also:
Serialized Form

Constructor Summary
NotCondition(Condition condition)
          Constructs a new NotCondition for the given condition.
NotCondition(State targetState, Condition condition)
          Constructs a new NotCondition for the given target state and condition.
 
Method Summary
 boolean satisfiedBy(java.lang.Object conditional)
          Called to check if the conditional meets the criteria defined by this condition.
 
Methods inherited from class net.openai.util.fsm.AbstractCondition
getTargetState, setTargetState
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

NotCondition

public NotCondition(Condition condition)
Constructs a new NotCondition for the given condition.

Parameters:
condition - The condition to negate.

NotCondition

public NotCondition(State targetState,
                    Condition condition)
Constructs a new NotCondition for the given target state and condition.

Parameters:
targetState - The target state for the condition.
Method Detail

satisfiedBy

public final boolean satisfiedBy(java.lang.Object conditional)
Called to check if the conditional meets the criteria defined by this condition.

Parameters:
conditional - The object to check.
Returns:
True if the condition passes, false otherwise.