#include "components/feed/core/v2/stream_model/feature_tree.h"
#include <algorithm>
#include <sstream>
#include "base/check.h"
namespace feed {
namespace stream_model {
namespace {
std::string ToAsciiForTesting(const std::string& s) { … }
}
ContentMap::ContentMap(ContentRevision::Generator* revision_generator)
: … { … }
ContentMap::~ContentMap() = default;
ContentTag ContentMap::GetContentTag(const feedwire::ContentId& id) { … }
const feedstore::Content* ContentMap::FindContent(
ContentRevision content_revision) { … }
ContentRevision ContentMap::LookupContentRevision(
const feedstore::Content& content) { … }
ContentRevision ContentMap::AddContent(feedstore::Content content) { … }
void ContentMap::Clear() { … }
StreamNode::StreamNode() = default;
StreamNode::~StreamNode() = default;
StreamNode::StreamNode(const StreamNode&) = default;
StreamNode& StreamNode::operator=(const StreamNode&) = default;
FeatureTree::FeatureTree(ContentMap* content_map) : … { … }
FeatureTree::FeatureTree(const FeatureTree* base)
: … { … }
FeatureTree::~FeatureTree() = default;
StreamNode* FeatureTree::GetOrMakeNode(ContentTag id) { … }
const StreamNode* FeatureTree::FindNode(ContentTag id) const { … }
StreamNode* FeatureTree::FindNode(ContentTag id) { … }
const feedstore::Content* FeatureTree::FindContent(ContentRevision id) const { … }
void FeatureTree::ApplyStreamStructure(
const feedstore::StreamStructure& structure) { … }
void FeatureTree::ResizeNodesIfNeeded(ContentTag id) { … }
void FeatureTree::AddContent(feedstore::Content content) { … }
void FeatureTree::CopyAndAddContent(const feedstore::Content& content) { … }
void FeatureTree::ResolveRoot() { … }
std::vector<ContentRevision> FeatureTree::GetVisibleContent() { … }
std::string FeatureTree::DumpStateForTesting() { … }
}
}