Class Set_Std_Swap
- java.lang.Object
-
- org.chocosolver.util.objects.setDataStructures.swapList.Set_Swap
-
- org.chocosolver.util.objects.setDataStructures.swapList.Set_Std_Swap
-
public class Set_Std_Swap extends Set_Swap
Set of integers based on BipartiteSet implementation BEWARE : CANNOT BOTH ADD AND REMOVE ELEMENTS DURING SEARCH (add only or remove only) add : O(1) testPresence: O(1) remove: O(1) iteration : O(m)- Author:
- : Jean-Guillaume Fages
-
-
Constructor Summary
Constructors Constructor Description Set_Std_Swap(IEnvironment e, int offSet)
Creates an empty bipartite set having numbers greater or equal thanoffSet
(possibly < 0)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description protected void
addSize(int delta)
protected void
setSize(int s)
int
size()
-
Methods inherited from class org.chocosolver.util.objects.setDataStructures.swapList.Set_Swap
add, clear, contains, getSetType, iterator, max, min, newIterator, remove, toString
-
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
-
Methods inherited from interface org.chocosolver.util.objects.setDataStructures.ISet
isEmpty, toArray
-
Methods inherited from interface java.lang.Iterable
forEach, spliterator
-
-
-
-
Field Detail
-
size
protected IStateInt size
-
-
Constructor Detail
-
Set_Std_Swap
public Set_Std_Swap(IEnvironment e, int offSet)
Creates an empty bipartite set having numbers greater or equal thanoffSet
(possibly < 0)- Parameters:
e
- backtracking environmentoffSet
- smallest allowed value in this set (possibly < 0)
-
-