MCPcopy Create free account
hub / github.com/apache/orc / TimestampColumnReader

Method TimestampColumnReader

c++/src/ColumnReader.cc:279–294  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

277 };
278
279 TimestampColumnReader::TimestampColumnReader(const Type& type, StripeStreams& stripe,
280 bool isInstantType)
281 : ColumnReader(type, stripe),
282 writerTimezone_(isInstantType ? &getTimezoneByName("GMT") : &stripe.getWriterTimezone()),
283 readerTimezone_(isInstantType ? &getTimezoneByName("GMT") : &stripe.getReaderTimezone()),
284 epochOffset_(writerTimezone_->getEpoch()),
285 sameTimezone_(writerTimezone_ == readerTimezone_) {
286 RleVersion vers = convertRleVersion(stripe.getEncoding(columnId).kind());
287 std::unique_ptr<SeekableInputStream> stream =
288 stripe.getStream(columnId, proto::Stream_Kind_DATA, true);
289 if (stream == nullptr) throw ParseError("DATA stream not found in Timestamp column");
290 secondsRle_ = createRleDecoder(std::move(stream), true, vers, memoryPool, metrics);
291 stream = stripe.getStream(columnId, proto::Stream_Kind_SECONDARY, true);
292 if (stream == nullptr) throw ParseError("SECONDARY stream not found in Timestamp column");
293 nanoRle_ = createRleDecoder(std::move(stream), false, vers, memoryPool, metrics);
294 }
295
296 TimestampColumnReader::~TimestampColumnReader() {
297 // PASS

Callers

nothing calls this directly

Calls 7

convertRleVersionFunction · 0.85
ParseErrorClass · 0.85
createRleDecoderFunction · 0.85
getWriterTimezoneMethod · 0.65
getEpochMethod · 0.45
getEncodingMethod · 0.45
getStreamMethod · 0.45

Tested by

no test coverage detected