RulEx.Guards (RulEx v1.0.0) View Source

Provide helper guards for use with RulEx.

Link to this section Summary

Functions

Yield true if given expression is a valid comparison expression, false otherwise.

Yield true if given operand is a valid comparison operand, false otherwise.

Yield true if given Elixir values is falsy, i.e. nil or false, false otherwise.

Yield true if given operand is reserved by RulEx, false otherwise.

Yield true if given Elixir values is truthy, i.e. not nil or false, false otherwise.

Yield true if given expression is a valid val expression, false otherwise.

Yield true if given expression is a valid val or var expression, false otherwise.

Yield true if give operand is a reserved operand or a string standing for any custom operands, false otherwise.

Yield true if given expression is a valid var expression, false otherwise.

Link to this section Functions

Link to this macro

is_comparison(expr)

View Source (macro)

Yield true if given expression is a valid comparison expression, false otherwise.

Link to this macro

is_comparison_operand(op)

View Source (macro)

Yield true if given operand is a valid comparison operand, false otherwise.

Link to this macro

is_falsy(value)

View Source (macro)

Yield true if given Elixir values is falsy, i.e. nil or false, false otherwise.

Link to this macro

is_reserved_operand(op)

View Source (macro)

Yield true if given operand is reserved by RulEx, false otherwise.

Link to this macro

is_truthy(value)

View Source (macro)

Yield true if given Elixir values is truthy, i.e. not nil or false, false otherwise.

Yield true if given expression is a valid val expression, false otherwise.

Link to this macro

is_val_or_var(expr)

View Source (macro)

Yield true if given expression is a valid val or var expression, false otherwise.

Link to this macro

is_valid_operand(op)

View Source (macro)

Yield true if give operand is a reserved operand or a string standing for any custom operands, false otherwise.

Yield true if given expression is a valid var expression, false otherwise.