#include "components/sync_bookmarks/synced_bookmark_tracker_entity.h"
#include <utility>
#include "base/base64.h"
#include "base/check.h"
#include "base/hash/hash.h"
#include "base/hash/sha1.h"
#include "base/memory/ptr_util.h"
#include "base/metrics/histogram_macros.h"
#include "base/trace_event/memory_usage_estimator.h"
#include "components/bookmarks/browser/bookmark_node.h"
#include "components/sync/protocol/entity_data.h"
#include "components/sync/protocol/entity_metadata.pb.h"
#include "components/sync/protocol/entity_specifics.pb.h"
#include "components/sync/protocol/proto_memory_estimations.h"
#include "components/sync/protocol/unique_position.pb.h"
namespace sync_bookmarks {
namespace {
void HashSpecifics(const sync_pb::EntitySpecifics& specifics,
std::string* hash) { … }
}
SyncedBookmarkTrackerEntity::SyncedBookmarkTrackerEntity(
const bookmarks::BookmarkNode* bookmark_node,
sync_pb::EntityMetadata metadata)
: … { … }
SyncedBookmarkTrackerEntity::~SyncedBookmarkTrackerEntity() = default;
bool SyncedBookmarkTrackerEntity::IsUnsynced() const { … }
bool SyncedBookmarkTrackerEntity::MatchesData(
const syncer::EntityData& data) const { … }
bool SyncedBookmarkTrackerEntity::MatchesSpecificsHash(
const sync_pb::EntitySpecifics& specifics) const { … }
bool SyncedBookmarkTrackerEntity::MatchesFaviconHash(
const std::string& favicon_png_bytes) const { … }
syncer::ClientTagHash SyncedBookmarkTrackerEntity::GetClientTagHash() const { … }
size_t SyncedBookmarkTrackerEntity::EstimateMemoryUsage() const { … }
}