BitcrowdEcto.Random (bitcrowd_ecto v0.12.0) View Source

Various random value generators.

Link to this section Summary

Functions

Generates a random token from an alphabet designed to have no ambiguities.

Generates a random token suitable for inclusion in URLs.

Generates a UUID V4.

Link to this section Functions

Link to this function

unambiguous_human_token(length \\ 6)

View Source (since 0.6.0)

Specs

unambiguous_human_token(length :: non_neg_integer()) :: String.t()

Generates a random token from an alphabet designed to have no ambiguities.

Link to this function

url_token(bytes \\ 16)

View Source (since 0.6.0)

Specs

url_token(bytes :: non_neg_integer()) :: String.t()

Generates a random token suitable for inclusion in URLs.

Specs

uuid() :: String.t()

Generates a UUID V4.