Skip to content

v0.9.1

Latest

Choose a tag to compare

@github-actions github-actions released this 08 Nov 21:05
· 5 commits to main since this release
84ae915

NuGet: https://www.nuget.org/packages/TcgDex.CSharpSdk/0.9.1

dotnet add package TcgDex.CSharpSdk --version 0.9.1

Changed

  • net10.0: Microsoft.Extensions.Http, Microsoft.Extensions.Logging.Abstractions and
    Microsoft.Extensions.Options now require 10.0.14, up from 10.0.13. Each target tracks the
    latest patch of its own line, for the security, bug and performance fixes. The net8.0 and
    netstandard2.0 builds are unchanged and still depend on the 8.0.x line, which is at its newest patch.

Fixed

  • Models now compare by value, collections included. Two Cards deserialized from the same JSON were never equal
    (==, Equals and GetHashCode disagreed), because the collections they hold were compared by reference.
    This covers Card, Attack, DetailedVariant, Series, CardSet and TcgPlayerPricing. Order matters for
    a list and not for the printings of a price, whose keys compare ordinally whatever comparer your dictionary used.
    A model's text (ToString) now shows a collection's items instead of its type name. No signature changes.
    Three things you can now observe:
    • A model still does not copy a list you give it, so editing that list afterwards changes the model, and now its
      equality and hash as well. Treat a list as given away. (A price's printings are copied.)
    • Equals, GetHashCode and ToString cost time proportional to the card's contents, so key a cache on
      Card.Id rather than on the whole card.
    • ToString on a set of 300 cards prints all 300.