A bag, i.e. a set using a custom comparison function, keeping only minimal values.
Warning: once added, elements in the set should not change -- no comparison and filtering would be done in such a case.
Protected
Readonly
O(n)...
Adds (O(n^2)) an element in the bag, keeping only minimal values.
Element to add in the bag
Wether the element has been added or not, the number of pruned elements
Adds (O(n)) an element in the bag, marking new dominated values but not removing them, see add.
Wether the element has been added or not
adds (O(n^2)) everything from another bag in this bag.
Bag to merge from
Number of added and pruned elements
Removes (O(n^2)) dominated elements
#Removed elements
Updates an element in the bag, removing it if it's being dominated, and removing possible dominated elements
Element to update currently in the bag
New element to put in its place
Number of pruned elements, possibly including the updated element
Updates an element in the bag, marking dominated elements
Wether the updated element is now dominated or not
Static
Create (O(n)) a new bag from another. Does NOT copy elements -- they have the same reference.
A bag, i.e. a set using a custom comparison function, keeping only minimal values.
Warning: once added, elements in the set should not change -- no comparison and filtering would be done in such a case.