MCPcopy Create free account
hub / github.com/PlotJuggler/PlotJuggler / series

Method series

pj_datastore/src/reader.cpp:238–255  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

236}
237
238Expected<SeriesReader> DataReader::series(TopicId topic_id, std::size_t column_index) const {
239 auto lock = engine_.lockEngine();
240 const TopicStorage* storage = engine_.getTopicStorage(topic_id);
241 if (storage == nullptr) {
242 return PJ::unexpected(fmt::format("Topic {} not found", topic_id));
243 }
244
245 const std::vector<ColumnDescriptor> columns = columnsForTopic(engine_, *storage);
246 if (column_index >= columns.size()) {
247 return PJ::unexpected(fmt::format("Column {} not found in topic {}", column_index, topic_id));
248 }
249
250 if (!isSeriesValueType(columns[column_index].logical_type)) {
251 return PJ::unexpected(fmt::format("Column {} in topic {} is not a numeric series", column_index, topic_id));
252 }
253
254 return SeriesReader(storage->sealedChunks(), column_index, storage->retentionFloor(), std::move(lock));
255}
256
257} // namespace PJ

Callers 10

ensureFilteredMethod · 0.80
boundingRectMethod · 0.80
visibleYRangeMethod · 0.80
sampleFromTimeMethod · 0.80
ensureChunkIndexMethod · 0.80
mergedSampleCountFunction · 0.80
readColumnFunction · 0.80
TESTFunction · 0.80
TESTFunction · 0.80
TEST_FFunction · 0.80

Calls 7

columnsForTopicFunction · 0.85
isSeriesValueTypeFunction · 0.85
SeriesReaderClass · 0.85
lockEngineMethod · 0.80
getTopicStorageMethod · 0.80
retentionFloorMethod · 0.80
sizeMethod · 0.45

Tested by 5

mergedSampleCountFunction · 0.64
readColumnFunction · 0.64
TESTFunction · 0.64
TESTFunction · 0.64
TEST_FFunction · 0.64