@Override
  public Object next() {
    if (!hasNext()) {
      throw new NoSuchElementException();
    }
    DataType<?> t = types[idx++];
    if (src.getPosition() == src.getLength() && t.isNullable()) {
      return null;
    }
    return t.decode(src);
  }
Construct {@code StructIterator} over the values encoded in {@code src} using the specified
{@code types} definition.
@param src   The buffer from which to read encoded values.
@param types The sequence of types to use as the schema for this {@code Struct}.
hbase-common/src/main/java/org/apache/hadoop/hbase/types/StructIterator.java