org.callbackparams.combine
Class CombineAllPossible2Combinations
java.lang.Object
org.callbackparams.combine.AbstractCombineStrategy
org.callbackparams.combine.CombineAllPossible2Combinations
- All Implemented Interfaces:
- CombineStrategy
public class CombineAllPossible2Combinations
- extends AbstractCombineStrategy
A strategy that creates a collection of callback-records in which all
possible combinations of two individual callback-parameters will be
represented. The strategy also tries to accomplish this task while keeping
the number of callback-records as low as possible. This works alright but
there is no guarantee that the lowest number of callback-records is always
found but it seems to work flawlessly when the ValuesCollection contains
three arrays and OK when there are four or more arrays.
If there is some combinatory expert available out there than feel free to
provide some optimized algorithms for this. The current algorithms are pretty
hard to understand and to some extent they also rely on chance.
- Author:
- Henrik Kaipe
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
CombineAllPossible2Combinations
public CombineAllPossible2Combinations()
combineInternal
protected Collection combineInternal(ValuesCollection vc)
- Description copied from class:
AbstractCombineStrategy
- This is the method to implement when implementing
CombineStrategy
by subclassing AbstractCombineStrategy
.
The advantage compared to overriding AbstractCombineStrategy.combine(ValuesCollection)
is that maxCount-check and validation of configuration for
AbstractCombineStrategy.setMaxCount(int)
and AbstractCombineStrategy.setRandomSeed(long)
will be taken
care of by the super-class - relieving this method to administer
combining exclusivly.
- Specified by:
combineInternal
in class AbstractCombineStrategy
Copyright © 2010-2013 Henrik Kaipe. All Rights Reserved.