#include "third_party/blink/renderer/core/css/resolver/matched_properties_cache.h"
#include "third_party/blink/renderer/core/css/css_property_value_set.h"
#include "third_party/blink/renderer/core/css/properties/css_property_ref.h"
#include "third_party/blink/renderer/core/css/resolver/style_resolver_state.h"
#include "third_party/blink/renderer/core/style/computed_style.h"
#include "third_party/blink/renderer/platform/heap/visitor.h"
#include "third_party/blink/renderer/platform/wtf/text/string_hasher.h"
namespace blink {
static unsigned ComputeMatchedPropertiesHash(const MatchResult& result) { … }
CachedMatchedProperties::CachedMatchedProperties(
const ComputedStyle* style,
const ComputedStyle* parent_style,
const MatchedPropertiesVector& properties)
: … { … }
void CachedMatchedProperties::Set(const ComputedStyle* style,
const ComputedStyle* parent_style,
const MatchedPropertiesVector& properties) { … }
void CachedMatchedProperties::Clear() { … }
bool CachedMatchedProperties::DependenciesEqual(
const StyleResolverState& state) { … }
MatchedPropertiesCache::MatchedPropertiesCache() = default;
MatchedPropertiesCache::Key::Key(const MatchResult& result)
: … { … }
MatchedPropertiesCache::Key::Key(const MatchResult& result, unsigned hash)
: … { … }
const CachedMatchedProperties* MatchedPropertiesCache::Find(
const Key& key,
const StyleResolverState& style_resolver_state) { … }
bool CachedMatchedProperties::operator==(
const MatchedPropertiesVector& properties) { … }
bool CachedMatchedProperties::operator!=(
const MatchedPropertiesVector& properties) { … }
void MatchedPropertiesCache::Add(const Key& key,
const ComputedStyle* style,
const ComputedStyle* parent_style) { … }
void MatchedPropertiesCache::Clear() { … }
void MatchedPropertiesCache::ClearViewportDependent() { … }
bool MatchedPropertiesCache::IsStyleCacheable(
const ComputedStyleBuilder& builder) { … }
bool MatchedPropertiesCache::IsCacheable(const StyleResolverState& state) { … }
void MatchedPropertiesCache::Trace(Visitor* visitor) const { … }
void MatchedPropertiesCache::RemoveCachedMatchedPropertiesWithDeadEntries(
const LivenessBroker& info) { … }
std::ostream& operator<<(std::ostream& stream,
MatchedPropertiesCache::Key& key) { … }
}