MCPcopy Create free account
hub / github.com/ByConity/ByConity / read

Function read

src/DataTypes/Serializations/SerializationString.cpp:278–297  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

276
277template <typename Reader>
278static inline void read(IColumn & column, Reader && reader)
279{
280 ColumnString & column_string = assert_cast<ColumnString &>(column);
281 ColumnString::Chars & data = column_string.getChars();
282 ColumnString::Offsets & offsets = column_string.getOffsets();
283 size_t old_chars_size = data.size();
284 size_t old_offsets_size = offsets.size();
285 try
286 {
287 reader(data);
288 data.push_back(0);
289 offsets.push_back(data.size());
290 }
291 catch (...)
292 {
293 offsets.resize_assume_reserved(old_offsets_size);
294 data.resize_assume_reserved(old_chars_size);
295 throw;
296 }
297}
298
299
300void SerializationString::deserializeWholeText(IColumn & column, ReadBuffer & istr, const FormatSettings &) const

Callers 5

deserializeWholeTextMethod · 0.70
deserializeTextQuotedMethod · 0.70
deserializeTextJSONMethod · 0.70
deserializeTextCSVMethod · 0.70

Calls 4

getOffsetsMethod · 0.45
sizeMethod · 0.45
push_backMethod · 0.45

Tested by

no test coverage detected