com.ibm.websphere.brb.strategy
Class ReturnFirstCombiningStrategy

java.lang.Object
  |
  +--com.ibm.websphere.brb.strategy.ReturnFirstCombiningStrategy
All Implemented Interfaces:
CombiningStrategy, java.io.Serializable

public class ReturnFirstCombiningStrategy
extends java.lang.Object
implements CombiningStrategy, java.io.Serializable

Returns the first result. If no rules were fired, returns null.

See Also:
Serialized Form

Fields inherited from interface com.ibm.websphere.brb.CombiningStrategy
RETURN_ALL, RETURN_AND, RETURN_FIRST, RETURN_LAST, RETURN_OR, THROW_VIOLATION
 
Constructor Summary
ReturnFirstCombiningStrategy()
           
 
Method Summary
 java.lang.Object combineResults(TriggerPoint tp, java.lang.Object[] results)
          Returns the first result.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

ReturnFirstCombiningStrategy

public ReturnFirstCombiningStrategy()
Method Detail

combineResults

public java.lang.Object combineResults(TriggerPoint tp,
                                       java.lang.Object[] results)
Returns the first result. If no rules were fired, returns null.

Specified by:
combineResults in interface CombiningStrategy
Following copied from interface: com.ibm.websphere.brb.CombiningStrategy
Parameters:
tp - the trigger point which is used to make this call
results - the list of results of firing the rules
Returns:
The combined result of the rules fired on this TriggerPoint call. Any type of object can be returned as the result.
Throws:
BusinessRuleBeansException - if any exceptions occur