chash_key() = index() | chash:index()
chashbin() = #chashbin{size = pos_integer(), owners = owners_bin(), nodes = tuple()}
index() = chash:index_as_int()
iterator() = #iterator{pos = non_neg_integer(), start = non_neg_integer(), chbin = chashbin()}
owners_bin() = <<_:_*176>>
pred_fun() = fun(({index(), node()}) -> boolean())
| create/1 | Create a chashbin from the provided chash |
| exact_iterator/2 | |
| index_owner/2 | Return the node that owns the given index. |
| iterator/2 | Return an iterator pointing to the index responsible for the given chash key. |
| itr_next/1 | Advance the iterator by one ring position. |
| itr_next_while/2 | Advance the iterator while Pred({Index, Owner}) returns true |
| itr_pop/2 |
Advance the iterator N times, returning a list of the traversed
{Index, Owner} pairs as well as the new iterator state. |
| itr_value/1 | Return the {Index, Owner} pair pointed to by the iterator. |
| num_partitions/1 | Return the number of partitions in a given chashbin |
| responsible_index/2 | Determine the ring index responsible for a given chash key. |
| responsible_position/2 | Determine the ring position responsible for a given chash key. |
| to_chash/1 | Convert a chashbin back to a chash |
| to_list/1 | Convert a chashbin to a list of {Index, Owner} pairs. |
| to_list_filter/2 |
Convert a chashbin to a list of {Index, Owner} pairs for
which Pred({Index, Owner}) returns true |
create(X1::chash:chash()) -> chashbin()
Create a chashbin from the provided chash
exact_iterator(Idx, CHBin) -> any()
index_owner(Idx::index(), CHBin::chashbin()) -> node()
Return the node that owns the given index
iterator(HashKey::first | chash_key(), CHBin::chashbin()) -> iterator()
Return an iterator pointing to the index responsible for the given chash key
itr_next(Itr::iterator()) -> iterator() | done
Advance the iterator by one ring position
itr_next_while(Pred::pred_fun(), Itr::iterator()) -> iterator()
Advance the iterator while Pred({Index, Owner}) returns true
itr_pop(N::pos_integer(), Itr::iterator()) -> {[{index(), node()}], iterator()}
Advance the iterator N times, returning a list of the traversed
{Index, Owner} pairs as well as the new iterator state
itr_value(Iterator::iterator()) -> {index(), node()}
Return the {Index, Owner} pair pointed to by the iterator
num_partitions(Chashbin::chashbin()) -> pos_integer()
Return the number of partitions in a given chashbin
responsible_index(HashKey::chash_key(), CHBin::chashbin()) -> index()
Determine the ring index responsible for a given chash key
responsible_position(HashKey::chash_key(), CHBin::chashbin()) -> non_neg_integer()
Determine the ring position responsible for a given chash key
to_chash(CHBin::chashbin()) -> chash:chash()
Convert a chashbin back to a chash
to_list(Chashbin::chashbin()) -> [{index(), node()}]
Convert a chashbin to a list of {Index, Owner} pairs
to_list_filter(Pred::pred_fun(), Chashbin::chashbin()) -> [{index(), node()}]
Convert a chashbin to a list of {Index, Owner} pairs for
which Pred({Index, Owner}) returns true
Generated by EDoc