Class TemplateArgs

Assembly: redb.Route.Templates.dll

Named arguments of a payload step — the analog of WSO2 PayloadFactory <arg>, but by
name instead of position: args.Set("customer", "header.customerId") is read in the template
as {{ args.customer }}. Argument expressions are the route expression language and are
evaluated on the message before rendering, which keeps the template itself an almost
static document a non-programmer can edit.

public sealed class TemplateArgs

Inheritance

Object→TemplateArgs

Properties

Names

Argument names, for diagnostics.

public IEnumerable<string> Names { get; }

Methods

Set(string, IExpression)

Argument computed from an .

public TemplateArgs Set(string name, IExpression expression)

Set(string, string)

Argument computed from a route-language expression ("header.amount * header.qty"); the expression is compiled now, so a typo fails at Start().

public TemplateArgs Set(string name, string expression)

SetValue(string, object?)

Constant argument (XML form <arg name="channel" value="email"/>).

public TemplateArgs SetValue(string name, object? value)