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

Method username

cpp/src/arrow/util/uri.cc:168–175  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

166int32_t Uri::port() const { return impl_->port_; }
167
168std::string Uri::username() const {
169 auto userpass = TextRangeToView(impl_->uri_.userInfo);
170 auto sep_pos = userpass.find_first_of(':');
171 if (sep_pos != std::string_view::npos) {
172 userpass = userpass.substr(0, sep_pos);
173 }
174 return UriUnescape(userpass);
175}
176
177std::string Uri::password() const {
178 auto userpass = TextRangeToView(impl_->uri_.userInfo);

Callers 6

FromProtoFunction · 0.80
FromUriMethod · 0.80
FromUriMethod · 0.80
FromUriMethod · 0.80
TESTFunction · 0.80

Calls 3

TextRangeToViewFunction · 0.85
UriUnescapeFunction · 0.85
substrMethod · 0.80

Tested by 1

TESTFunction · 0.64