Skip to content

v2.1.0

Latest

Choose a tag to compare

@github-actions github-actions released this 20 Nov 18:48
· 6 commits to main since this release
b1e925f

Added

  • GetValue, GetValueOrDefault and ContainsKey on IReadOnlyPropertyBag; GetValue throws KeyNotFoundException naming the key when the bag holds no value for it (ADR-1011).
  • TryAdd, GetOrAdd and TryRemove on IPropertyBag, each composed from TryGetValue and a write (ADR-1011).
  • ConcurrentPropertyBagDictionary, a bag that is safe from several threads, with atomic TryAdd, GetOrAdd and TryRemove, and enumeration over a snapshot (ADR-1011).
  • LayeredPropertyBag and CreateChild(): a child bag that reads through to its parent, keeps its own writes and removals, and never writes the parent (ADR-1011).
  • ReadOnlyPropertyBag and AsReadOnly(): a read-only view that cannot be cast back to IPropertyBag (ADR-1011).
  • The guides "Layer a child bag over a parent" and "Share a bag across threads" on the documentation site, and sections on the read and write helpers and protected views (ADR-1011).

Changed

  • PropertyBagKey.ToString() and PropertyBagKey<T>.ToString() return the name and the value type, such as UserName (System.String), where they returned the struct's type name, such as NCode.PropertyBag.PropertyBagKey (ADR-1011).
  • Package validation compares each package with the published 2.0.2 package.