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

Method ToString

cpp/src/parquet/geospatial/statistics.cc:351–391  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

349}
350
351std::string GeoStatistics::ToString() const {
352 if (!is_valid()) {
353 return "<GeoStatistics> invalid";
354 }
355
356 std::stringstream ss;
357 ss << "<GeoStatistics>";
358
359 std::string dim_label("xyzm");
360 auto dim_valid = dimension_valid();
361 auto dim_empty = dimension_empty();
362 auto lower = lower_bound();
363 auto upper = upper_bound();
364
365 for (int i = 0; i < kMaxDimensions; i++) {
366 ss << " " << dim_label[i] << ": ";
367 if (!dim_valid[i]) {
368 ss << "invalid";
369 } else if (dim_empty[i]) {
370 ss << "empty";
371 } else {
372 ss << "[" << lower[i] << ", " << upper[i] << "]";
373 }
374 }
375
376 std::optional<std::vector<int32_t>> maybe_geometry_types = geometry_types();
377 ss << " geometry_types: ";
378 if (maybe_geometry_types.has_value()) {
379 ss << "[";
380 std::string sep("");
381 for (int32_t geometry_type : *maybe_geometry_types) {
382 ss << sep << geometry_type;
383 sep = ", ";
384 }
385 ss << "]";
386 } else {
387 ss << "invalid";
388 }
389
390 return ss.str();
391}
392
393} // namespace parquet::geospatial

Callers 13

TEST_PFunction · 0.45
RotateKeysMethod · 0.45
TEST_FFunction · 0.45
LoadKeyMaterialMapMethod · 0.45
EncryptFileMethod · 0.45
WrapThenUnwrapMethod · 0.45
TESTFunction · 0.45
TESTFunction · 0.45
UpdateMethod · 0.45

Calls 2

strMethod · 0.80
is_validFunction · 0.50

Tested by 9

TEST_PFunction · 0.36
RotateKeysMethod · 0.36
TEST_FFunction · 0.36
EncryptFileMethod · 0.36
WrapThenUnwrapMethod · 0.36
TESTFunction · 0.36
TESTFunction · 0.36