View Source ExCycle.StringBuilder behaviour (ex_cycle v0.8.1)

This module is in charge of building a stringified version of an ExCycle.Rule.

Examples

iex> ExCycle.Rule.new(:weekly, days: [:monday], hours: [10], minutes: [30])
...> StringBuilder.traverse_validations(&stringify/2)
...> Enum.join(" ")
"daily at 10:00, 10:30"

NOTE: You MUST implement the stringify function on your side.

Summary

Types

@type any_validation() :: ExCycle.Validations.any_validation()

Callbacks

Link to this callback

string_params(any_validation)

View Source
@callback string_params(any_validation()) :: {atom(), [{String.t(), keyword()}]} | nil

Functions

Link to this function

traverse_validations(rule, msg_fun)

View Source

Stringify an ExCycle.Rule.

Warning: This function is "new" and there is high probability to have breaking changes on next release.