17 references to PropertyRef
System.Text.Json (17)
System\Text\Json\Serialization\Metadata\JsonTypeInfo.Cache.cs (7)
71private PropertyRef[] _utf8PropertyCache = []; 86PropertyRef[] utf8PropertyCache = _utf8PropertyCache; // Keep a local copy of the cache in case it changes by another thread. 87ReadOnlySpan<PropertyRef> utf8PropertyCacheSpan = utf8PropertyCache; 88ulong key = PropertyRef.GetKey(propertyName); 92PropertyRef propertyRef; 178PropertyRef[]? currentCache = _utf8PropertyCache; 183PropertyRef[] newCache = cacheBuilder.ToArray();
System\Text\Json\Serialization\Metadata\PropertyRef.cs (3)
15internal readonly struct PropertyRef(ulong key, JsonPropertyInfo? info, byte[] utf8PropertyName) : IEquatable<PropertyRef> 37public bool Equals(PropertyRef other) => Equals(other.Utf8PropertyName, other.Key); 38public override bool Equals(object? obj) => obj is PropertyRef other && Equals(other);
System\Text\Json\Serialization\Metadata\PropertyRefCacheBuilder.cs (7)
10/// Defines builder type for constructing updated <see cref="PropertyRef"/> caches. 12internal sealed class PropertyRefCacheBuilder(PropertyRef[] originalCache) 15private readonly List<PropertyRef> _propertyRefs = []; 16private readonly HashSet<PropertyRef> _added = []; 21public readonly PropertyRef[] OriginalCache = originalCache; 24public PropertyRef[] ToArray() => [.. OriginalCache, .. _propertyRefs]; 26public void TryAdd(PropertyRef propertyRef)