com.oakgrovesystems.reactor.processMediation
Class ProcessConditionInversion

java.lang.Object
  |
  +--com.oakgrovesystems.mediation.Inversion
        |
        +--com.oakgrovesystems.reactor.processMediation.ProcessConditionInversion
All Implemented Interfaces:
Condition, ProcessCondition, java.io.Serializable

public class ProcessConditionInversion
extends Inversion
implements ProcessCondition, java.io.Serializable

An inversion of a ProcessCondition

See Also:
Serialized Form

Field Summary
protected  com.oakgrovesystems.reactor.processMediation.ProcessCondition conditionToInvert
           
protected  java.util.Map objectMap
           
 
Constructor Summary
ProcessConditionInversion(com.oakgrovesystems.reactor.processMediation.ProcessCondition conditionToInvert)
          Creates a ProcessConditionInversion that is an Inversion of the specified ProcessCondition
 
Method Summary
 com.oakgrovesystems.reactor.processMediation.ProcessCondition copy()
          Returns a deep copy
 java.util.Map getObjectMap()
          returns the Map used for looking up Process objects for condition evaluation
 com.oakgrovesystems.reactor.processMediation.ProcessCondition getProcessCondition()
          returns the ProcessCondition that this condition inverts
 boolean isMadeFalseBy(com.oakgrovesystems.mediation.Change change, java.lang.Object changee)
          returns a boolean indicating whether or not this Condition is true and would be made false by applying the specified Change to the specified Object.
 boolean isMadeTrueBy(com.oakgrovesystems.mediation.Change change, java.lang.Object changee)
          returns a boolean indicating whether or not this Condition is false and would be made true by applying the specified Change to the specified Object.
 boolean isTrue()
          returns a boolean indicating whether this Condition is true or false.
 boolean sameAs(java.lang.Object o)
          Tests for content equality with another object.
 void setObjectMap(java.util.Map objectMap)
          sets the Map used for looking up Process objects for condition evaluation
 
Methods inherited from class com.oakgrovesystems.mediation.Inversion
getCondition, toString
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Field Detail

objectMap

protected java.util.Map objectMap

conditionToInvert

protected com.oakgrovesystems.reactor.processMediation.ProcessCondition conditionToInvert
Constructor Detail

ProcessConditionInversion

public ProcessConditionInversion(com.oakgrovesystems.reactor.processMediation.ProcessCondition conditionToInvert)
Creates a ProcessConditionInversion that is an Inversion of the specified ProcessCondition

Parameters:
conditionToInvert - the ProcessCondition of which this Conditionis an Inversion.
Method Detail

getProcessCondition

public com.oakgrovesystems.reactor.processMediation.ProcessCondition getProcessCondition()
returns the ProcessCondition that this condition inverts

Returns:
the ProcessCondition that this condition inverts

getObjectMap

public java.util.Map getObjectMap()
returns the Map used for looking up Process objects for condition evaluation

Specified by:
getObjectMap in interface ProcessCondition
Returns:
the Map used for looking up Process objects for condition evaluation

setObjectMap

public void setObjectMap(java.util.Map objectMap)
sets the Map used for looking up Process objects for condition evaluation

Specified by:
setObjectMap in interface ProcessCondition
Parameters:
objectMap - the Map used for looking up Process objects for condition evaluation

isTrue

public boolean isTrue()
               throws CanNotEvaluateConditionException
returns a boolean indicating whether this Condition is true or false.

Specified by:
isTrue in interface Condition
Overrides:
isTrue in class Inversion
Returns:
a boolean indicating whether this Condition is true or false.
Throws:
CanNotEvaluateConditionException - if the Condition can not be evaluated

isMadeTrueBy

public boolean isMadeTrueBy(com.oakgrovesystems.mediation.Change change,
                            java.lang.Object changee)
                     throws CanNotEvaluateConditionException
returns a boolean indicating whether or not this Condition is false and would be made true by applying the specified Change to the specified Object.

Specified by:
isMadeTrueBy in interface Condition
Overrides:
isMadeTrueBy in class Inversion
Parameters:
change - the Change the application of which may make this Condition true
changee - the object to which the specified Change would be applied to make this Condition true.
Returns:
a boolean indicating whether or not this Condition is false and would be made true by applying the specified Change to the specified Object.
Throws:
CanNotEvaluateConditionException - if there is a problem evaluating Condition(s)

isMadeFalseBy

public boolean isMadeFalseBy(com.oakgrovesystems.mediation.Change change,
                             java.lang.Object changee)
                      throws CanNotEvaluateConditionException
returns a boolean indicating whether or not this Condition is true and would be made false by applying the specified Change to the specified Object.

Specified by:
isMadeFalseBy in interface Condition
Overrides:
isMadeFalseBy in class Inversion
Parameters:
change - the Change the application of which may make this Condition false
changee - the object to which the specified Change would be applied to make this Condition false.
Returns:
a boolean indicating whether or not this Condition is true and would be made false by applying the specified Change to the specified Object.
Throws:
CanNotEvaluateConditionException - if there is a problem evaluating Condition(s)

sameAs

public boolean sameAs(java.lang.Object o)
Tests for content equality with another object. Instances of different classes are not equal.

Specified by:
sameAs in interface ProcessCondition
Parameters:
o - the object to compare for equality
Returns:
boolean indicating whether or not the objects are equal

copy

public com.oakgrovesystems.reactor.processMediation.ProcessCondition copy()
Returns a deep copy

Specified by:
copy in interface ProcessCondition
Returns:
a deep copy


Copyright (c) 1999-2004 Oak Grove Systems. All Rights Reserved.