chromium/components/omnibox/browser/verbatim_match.cc

// Copyright 2015 The Chromium Authors
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.

#include "components/omnibox/browser/verbatim_match.h"

#include "base/containers/fixed_flat_set.h"
#include "components/omnibox/browser/autocomplete_classifier.h"
#include "components/omnibox/browser/autocomplete_input.h"
#include "components/omnibox/browser/autocomplete_match_classification.h"
#include "components/omnibox/browser/autocomplete_provider.h"
#include "components/omnibox/browser/autocomplete_provider_client.h"
#include "components/omnibox/browser/in_memory_url_index_types.h"
#include "components/search_engines/template_url_service.h"
#include "content/public/common/url_constants.h"
#include "third_party/metrics_proto/omnibox_scoring_signals.pb.h"
#include "url/gurl.h"
#include "url/url_constants.h"

namespace {
#if BUILDFLAG(IS_ANDROID)
// Note: explicitly exclude schemes that may be used to execute Javascript code
// snippet in the context of the current page on mobile devices.
constexpr auto kNavigableSchemes = base::MakeFixedFlatSet<std::string_view>(
    {url::kHttpScheme, url::kHttpsScheme, url::kAboutScheme,
     content::kChromeUIScheme});
#endif
}  // namespace

AutocompleteMatch VerbatimMatchForURL(
    AutocompleteProvider* provider,
    AutocompleteProviderClient* client,
    const AutocompleteInput& input,
    const GURL& destination_url,
    const std::u16string& destination_description,
    int verbatim_relevance) {}

AutocompleteMatch VerbatimMatchForInput(AutocompleteProvider* provider,
                                        AutocompleteProviderClient* client,
                                        const AutocompleteInput& input,
                                        const GURL& destination_url,
                                        bool trim_default_scheme) {}