decodeValue method

  1. @override
List<T> decodeValue(
  1. Pipe x,
  2. CType t
)
override

Implementation

@override
List<T> decodeValue(Pipe x, CType t) {
  var vec = checkType(t);
  if (vec is! VecClass) {
    throw 'Not a vector type';
  } else {
    var len = lebDecode(x).toInt();
    if (_blobOptimization) {
      return [...x.read(len) as List<T>];
    }
    var rets = <T>[];
    for (var i = 0; i < len; i++) {
      rets.add(_type.decodeValue(x, (vec).type));
    }
    return rets;
  }
}