MCPcopy Create free account
hub / github.com/apache/impala / CHexEscape

Function CHexEscape

be/src/gutil/strings/escaping.cc:593–600  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

591}
592
593string CHexEscape(const StringPiece& src) {
594 const int dest_length = src.size() * 4 + 1; // Maximum possible expansion
595 unique_ptr<char[]> dest(new char[dest_length]);
596 const int len = CEscapeInternal(src.data(), src.size(),
597 dest.get(), dest_length, true, false);
598 DCHECK_GE(len, 0);
599 return string(dest.get(), len);
600}
601
602string Utf8SafeCEscape(const StringPiece& src) {
603 const int dest_length = src.size() * 4 + 1; // Maximum possible expansion

Callers

nothing calls this directly

Calls 4

CEscapeInternalFunction · 0.85
getMethod · 0.65
sizeMethod · 0.45
dataMethod · 0.45

Tested by

no test coverage detected