src/lib/url/url_util.cc
// Returns true if the given scheme identified by |scheme| within |spec| is one
// of the registered "standard" schemes.
Returns true if the given scheme identified by |scheme| within |spec| is one
of the registered "standard" schemes.
Returns true if the given scheme identified by |scheme| within |spec| is one of the registered " standard " schemes .
bool IsStandard(const char* spec, const Component& scheme) {
  if (scheme.is_invalid_or_empty())
    return false;  
  for (const auto& standard_scheme : StandardSchemes()) {
    if (LowerCaseEqualsASCII(std::string_view(&spec[scheme.begin], scheme.len()),
                             std::string_view(standard_scheme)))
      return true;
  }
  return false;
}
bool IsStandard ( const char * spec , const Component & scheme ) { if ( scheme . is_invalid_or_empty ( ) ) return false ; for ( const auto & standard_scheme : StandardSchemes ( ) ) { if ( LowerCaseEqualsASCII ( std :: string_view ( & spec [ scheme . begin ] , scheme . len ( ) ) , std :: string_view ( standard_scheme ) ) ) return true ; } return false ; }
Returns true if the given scheme identified by |scheme| within |spec| is one
of the registered "standard" schemes.
Returns true if the given scheme identified by |scheme| within |spec| is one of the registered " standard " schemes .
// Empty or invalid schemes are non-standard.