Expression.V2.ContextVars (expression v2.21.0)
A module for keeping track of context variables.
This mostly just behaves like a regular Map with the exception
that when a variable doesn't exist in the context, it returns
a %ContextVars{}
map that keeps track of the path that
was requested.
This is to allow us to keep displaying Hello info@support.com
when support.com
doesn't exist in the context.
The to_string()
behaviour is defined in the String.Chars
protocol
implementation below this module.
Link to this section Summary
Functions
Callback implementation for Access.fetch/2
.
Callback implementation for Access.get_and_update/3
.
Callback implementation for Access.pop/2
.
Link to this section Functions
Link to this function
fetch(ctx_vars, key)
Callback implementation for Access.fetch/2
.
Link to this function
get_and_update(ctx_vars, key, function)
Callback implementation for Access.get_and_update/3
.
Link to this function
new(vars)
Link to this function
pop(ctx_vars, key)
Callback implementation for Access.pop/2
.