chromium/components/browsing_topics/common/semantic_tree.cc

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

#ifdef UNSAFE_BUFFERS_BUILD
// TODO(crbug.com/40285824): Remove this and convert code to safer constructs.
#pragma allow_unsafe_buffers
#endif

#include "components/browsing_topics/common/semantic_tree.h"

#include <map>
#include <set>
#include <variant>

#include "base/check.h"
#include "base/check_op.h"
#include "base/containers/flat_set.h"
#include "base/containers/span.h"
#include "base/memory/raw_span.h"
#include "base/no_destructor.h"
#include "base/notreached.h"
#include "components/strings/grit/components_strings.h"
#include "third_party/blink/public/common/features.h"

namespace browsing_topics {

namespace  // namespace

SemanticTree::SemanticTree() = default;
SemanticTree::~SemanticTree() = default;

Topic SemanticTree::GetRandomTopic(int taxonomy_version,
                                   uint64_t random_topic_index_decision) {}

std::vector<Topic> SemanticTree::GetFirstLevelTopicsInCurrentTaxonomy() {}

std::vector<Topic>
SemanticTree::GetFirstLevelTopicsInCurrentTaxonomyInternal() {}

std::set<int> SemanticTree::GetTopicsInCurrentTaxonomyInternal() {}

std::vector<Topic> SemanticTree::GetAtMostTwoRepresentativesInCurrentTaxonomy(
    const Topic& topic) {}

bool SemanticTree::IsTaxonomySupported(int taxonomy_version) {}

std::vector<Topic> SemanticTree::GetDescendantTopics(const Topic& topic,
                                                     bool only_direct) {}

std::vector<Topic> SemanticTree::GetAncestorTopics(const Topic& topic) {}

std::optional<int> SemanticTree::GetLatestLocalizedNameMessageId(
    const Topic& topic) {}

std::optional<int> SemanticTree::GetLocalizedNameMessageId(
    const Topic& topic,
    int taxonomy_version) {}

}  // namespace browsing_topics