execute method

  1. @override
JinjaValue execute(
  1. Context ctx
)
override

Executes the statement within the given ctx and returns the result as a JinjaValue.

Implementation

@override
JinjaValue execute(Context ctx) {
  // Execute body
  final bodyResult = _execCaptured(body, ctx);
  // Apply filter to body result (as string usually)

  final result = FilterExpression(
    pos,
    _ValueExpression(bodyResult),
    filter,
  ).execute(ctx);
  return result;
}