MCPcopy Create free account
hub / github.com/apache/arrow / DecodeLengths

Method DecodeLengths

cpp/src/parquet/decoder.cc:1837–1851  ·  view source on GitHub ↗

Decode all the encoded lengths. The decoder_ will be at the start of the encoded data after that.

Source from the content-addressed store, hash-verified

1835 // Decode all the encoded lengths. The decoder_ will be at the start of the encoded data
1836 // after that.
1837 void DecodeLengths() {
1838 len_decoder_.SetDecoder(num_values_, decoder_);
1839
1840 // get the number of encoded lengths
1841 int num_length = len_decoder_.ValidValuesCount();
1842 PARQUET_THROW_NOT_OK(buffered_length_->Resize(num_length * sizeof(int32_t)));
1843
1844 // call len_decoder_.Decode to decode all the lengths.
1845 // all the lengths are buffered in buffered_length_.
1846 int ret =
1847 len_decoder_.Decode(buffered_length_->mutable_data_as<int32_t>(), num_length);
1848 DCHECK_EQ(ret, num_length);
1849 length_idx_ = 0;
1850 num_valid_values_ = num_length;
1851 }
1852
1853 Status DecodeArrowDense(int num_values, int null_count, const uint8_t* valid_bits,
1854 int64_t valid_bits_offset,

Callers

nothing calls this directly

Calls 4

ValidValuesCountMethod · 0.80
SetDecoderMethod · 0.45
ResizeMethod · 0.45
DecodeMethod · 0.45

Tested by

no test coverage detected