|
|||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object | +--com.oakgrovesystems.mediation.Conjunction
A compound Condition (a Condition that is a boolean function of the state of one or more other Conditions). Specfically, a Conjunction is a function of a set of other Conditions. If one or more of the other Conditions are false, the Conjunction is false. If all of the other Conditions are true, the Conjunction is true.
Field Summary | |
protected java.util.Set |
conditions
|
Constructor Summary | |
Conjunction(java.util.Set conditions)
Creates a new Conjunction that is a function of the specified Set of other Conditions |
Method Summary | |
java.util.Set |
getConditions()
returns the Set of Conditions of which this Conjunction is a function. |
boolean |
isMadeFalseBy(com.oakgrovesystems.mediation.Change c,
java.lang.Object o)
Returns true if all of the Conditions in the set are currently true, but at least one of them returns true from a call to Condition.isMadeFalseBy() with the same arguments. |
boolean |
isMadeTrueBy(com.oakgrovesystems.mediation.Change c,
java.lang.Object o)
Returns true if at least one of the Conditions in the set is currently false, and all of the Condtions in the Set that are currently false return true from a call to Condition.isMadeTrueBy() with the same arguments. |
boolean |
isTrue()
returns false if one or more of the Conditions in the Set are false, true if all of the Conditions in the Set are true. |
java.lang.String |
toString()
|
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
Field Detail |
protected java.util.Set conditions
Constructor Detail |
public Conjunction(java.util.Set conditions)
conditions
- The set of Conditions that this Conjunction is a function of.Method Detail |
public java.util.Set getConditions()
public boolean isTrue() throws CanNotEvaluateConditionException
isTrue
in interface Condition
CanNotEvaluateConditionException
- if the Set is null or contains an object that does not implement the
Condition interface or if one of the Conditions in the Set can not be
evaluated.public boolean isMadeTrueBy(com.oakgrovesystems.mediation.Change c, java.lang.Object o) throws CanNotEvaluateConditionException
isMadeTrueBy
in interface Condition
c
- The Change the application of which may make this Disjunction false.o
- The Object to which the Change would be applied
CanNotEvaluateConditionException
- if the Set is null or contains an object that does not implement the
Condition interface or a Condition in the Set can not be evaluated.public boolean isMadeFalseBy(com.oakgrovesystems.mediation.Change c, java.lang.Object o) throws CanNotEvaluateConditionException
isMadeFalseBy
in interface Condition
c
- The Change the application of which may make this Disjunction false.o
- The Object to which the Change would be applied
CanNotEvaluateConditionException
- if the Set is null or contains an object that does not implement the
Condition interface or a Condition in the Set can not be evaluated.public java.lang.String toString()
toString
in class java.lang.Object
|
|||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |