chocoteam/choco3 — pull request #137 by JLiangWaterloo (2013-11-16 19:53:06+00:00)
Title: Generalize the set variable selection strategy

A few changes.

1. Previously a set search strategy required two parts, a SetVarSelector and a SetValSelector. SetVarSelector did not inherit from VariableSelector which made it impossible to use strategies that are generalized to work with many types of variables. I've changed it so that set search strategy now requires a VariableSelector and a SetValSelector. This is an improvement because it accepts generalized VariableSelectors as well as specialized set variable selectors.
2. Generalized the InputOrder, Random, and Occurrence selection strategies to work with any type of variables.
3. Removed SetVarSelector.FirstVar since it is a redundant specialized reimplementation of InputOrder. In fact, SetVarSelector.FirstVar was less performant than InputOrder because InputOrder maintains an "IStateInt index" of all the instantiated variables it has already seen, whereas SetVarSelector.FirstVar would re-examine all the instantiated variables again at every selection.