tryDecode<T, U> method
Converts a encoded list of items into a List<T>.
The parse method converts each item from type U into T.
The List has a fixed length if growable is false.
Returns null if items is null.
Implementation
List<T>? tryDecode<T, U>(
final Iterable? items,
final JsonRpcParser<T, U> parse, {
final bool growable = false,
}) {
return items != null ? decode<T, U>(items, parse, growable: growable) : null;
}