encodeAs method

TfArg<Object?> encodeAs(
  1. String attribute
)

The argument value: each element's RefTo.encodeAs for a literal list, the value itself otherwise.

Implementation

TfArg<Object?> encodeAs(String attribute) => switch (this) {
  TfArgLiteral(:final value) => TfArg<Object?>.literal([
    for (final ref in value) ref.encodeAs(attribute),
  ]),
  final whole => whole,
};