AngleSharp by AngleSharp

<PackageReference Include="AngleSharp" Version="0.9.9.2" />

.NET API 1,223,680 bytes

 AttachedProperty<TObj, TProp>

sealed class AttachedProperty<TObj, TProp>
using System.Runtime.CompilerServices; namespace AngleSharp.Dom { internal sealed class AttachedProperty<TObj, TProp> where TObj : class where TProp : class { private readonly ConditionalWeakTable<TObj, TProp> _properties = new ConditionalWeakTable<TObj, TProp>(); public TProp Get(TObj item) { TProp value = null; _properties.TryGetValue(item, out value); return value; } public void Set(TObj item, TProp value) { _properties.Add(item, value); } } }