decode method

  1. @override
List<T> decode(
  1. Object? json
)
override

Implementation

@override
List<T> decode(Object? json) {
  if (json is! List) throw GqlifyDecodeError('List', json);
  final result = <T>[];
  var i = 0;
  try {
    for (; i < json.length; i++) {
      result.add(inner.decode(json[i]));
    }
  } on GqlifyDecodeError catch (e) {
    throw e._at(i);
  }
  return result;
}