# Module varpool

- Description
- Data Types
- Function Index
- Function Details

### Local Variable Pool

.

Copyright © 2015-2021 Michael Truog

Version: 2.0.1 May 26 2021 19:32:09 ------------------------------------------------------------------------

Authors: Michael Truog (`mjtruog at protonmail dot com`).

## Description

### Local Variable Pool

## Data Types

### group()

`group() = {Group::any(), {M::module(), F::atom(), A::list()}, Options::[{shutdown, pos_integer()} | {count_hash, pos_integer()} | {count_random, pos_integer()} | {hash, {module(), atom()} | fun((any(), pos_integer()) -> non_neg_integer())} | {random, {module(), atom()} | fun((pos_integer()) -> non_neg_integer())}]}`

### options()

`options() = [{max_r, non_neg_integer()} | {max_t, pos_integer()} | {groups, [group(), ...]}, ...]`

## Function Index

destroy/1 |
get/2 |
get/3 |
new/1 |
update/2 |

## Function Details

### destroy/1

`destroy(Varpool::#varpool{owner = pid(), supervisor = pid(), max_r = non_neg_integer(), max_t = pos_integer(), groups = #{any() := #group{count_hash = pos_integer(), count_random = pos_integer(), count_total = pos_integer(), hash = fun((any(), pos_integer()) -> non_neg_integer()), random = fun((pos_integer()) -> non_neg_integer()), processes = array:array(pid())}}, processes = #{pid() := {any(), non_neg_integer()}}, monitors = [reference()]}) -> ok`

### get/2

`get(Group::any(), Varpool::#varpool{owner = pid(), supervisor = pid(), max_r = non_neg_integer(), max_t = pos_integer(), groups = #{any() := #group{count_hash = pos_integer(), count_random = pos_integer(), count_total = pos_integer(), hash = fun((any(), pos_integer()) -> non_neg_integer()), random = fun((pos_integer()) -> non_neg_integer()), processes = array:array(pid())}}, processes = #{pid() := {any(), non_neg_integer()}}, monitors = [reference()]}) -> pid() | undefined`

### get/3

`get(Group::any(), Key::any(), Varpool::#varpool{owner = pid(), supervisor = pid(), max_r = non_neg_integer(), max_t = pos_integer(), groups = #{any() := #group{count_hash = pos_integer(), count_random = pos_integer(), count_total = pos_integer(), hash = fun((any(), pos_integer()) -> non_neg_integer()), random = fun((pos_integer()) -> non_neg_integer()), processes = array:array(pid())}}, processes = #{pid() := {any(), non_neg_integer()}}, monitors = [reference()]}) -> pid() | undefined`

### new/1

`new(Options::options()) -> #varpool{owner = pid(), supervisor = pid(), max_r = non_neg_integer(), max_t = pos_integer(), groups = #{any() := #group{count_hash = pos_integer(), count_random = pos_integer(), count_total = pos_integer(), hash = fun((any(), pos_integer()) -> non_neg_integer()), random = fun((pos_integer()) -> non_neg_integer()), processes = array:array(pid())}}, processes = #{pid() := {any(), non_neg_integer()}}, monitors = [reference()]}`

### update/2

`update(X1::any(), Varpool::#varpool{owner = pid(), supervisor = pid(), max_r = non_neg_integer(), max_t = pos_integer(), groups = #{any() := #group{count_hash = pos_integer(), count_random = pos_integer(), count_total = pos_integer(), hash = fun((any(), pos_integer()) -> non_neg_integer()), random = fun((pos_integer()) -> non_neg_integer()), processes = array:array(pid())}}, processes = #{pid() := {any(), non_neg_integer()}}, monitors = [reference()]}) -> {updated, #varpool{owner = pid(), supervisor = pid(), max_r = non_neg_integer(), max_t = pos_integer(), groups = #{any() := #group{count_hash = pos_integer(), count_random = pos_integer(), count_total = pos_integer(), hash = fun((any(), pos_integer()) -> non_neg_integer()), random = fun((pos_integer()) -> non_neg_integer()), processes = array:array(pid())}}, processes = #{pid() := {any(), non_neg_integer()}}, monitors = [reference()]}} | {ignored, #varpool{owner = pid(), supervisor = pid(), max_r = non_neg_integer(), max_t = pos_integer(), groups = #{any() := #group{count_hash = pos_integer(), count_random = pos_integer(), count_total = pos_integer(), hash = fun((any(), pos_integer()) -> non_neg_integer()), random = fun((pos_integer()) -> non_neg_integer()), processes = array:array(pid())}}, processes = #{pid() := {any(), non_neg_integer()}}, monitors = [reference()]}}`

Generated by EDoc