Crate vec_with_positions

Source
Expand description

UNTESTED code.

TODO: docs

Structs§

Position
VecWithOnePosition
VecWithPositionsAllDifferent
Example: Several threads use a pool of network nodes to download from. From the pool we “view” a range of currently used nodes, one by thread. If a note is invalidated, it is removed from the list and the lacking thread is moved to the end of the list receiving a new node. Nodes later than it in the range decrease their positions. Despite of the name, positions can be the same, if shortage of the pool.
VecWithPositionsVector

Traits§

VecWithPositions
A Vec inside together with positions that move together with the elements if the Vec has deletions or insertions.