jetedrow.SnapCall
2026.3.6
dotnet add package jetedrow.SnapCall --version 2026.3.6
NuGet\Install-Package jetedrow.SnapCall -Version 2026.3.6
<PackageReference Include="jetedrow.SnapCall" Version="2026.3.6" />
<PackageVersion Include="jetedrow.SnapCall" Version="2026.3.6" />
<PackageReference Include="jetedrow.SnapCall" />
paket add jetedrow.SnapCall --version 2026.3.6
#r "nuget: jetedrow.SnapCall, 2026.3.6"
#:package jetedrow.SnapCall@2026.3.6
#addin nuget:?package=jetedrow.SnapCall&version=2026.3.6
#tool nuget:?package=jetedrow.SnapCall&version=2026.3.6
SnapCall
SnapCall is a compact poker hand evaluation helper library focused on correctness and flexibility for various card set sizes and configurations.
Overview SnapCall evaluates poker hands for 2–7 card sets. It supports conventional 5-card poker rankings plus Five-of-a-Kind when duplicate cards are allowed (useful for multi-deck scenarios). The library provides both exact 5-card evaluation and best-5 selection for hands with more than five cards. Partial-hand evaluation for fewer than five cards is optional and configurable.
Usage
Create and evaluate hands using the Hand type. Typical usage:
// Parse a hand (uses global EvaluationOptions by default)
var h = Hand.Parse("Ac Ks Qh 9s 7d");
var strength = h.GetStrength();
// Parse with per-call options (override global)
var s = Hand.Parse("9s 9s", new EvaluationOptions(evaluatePartialHands: true, allowDuplicateCards: true));
// Evaluate with per-call options
var strength2 = h.GetStrength(new EvaluationOptions(evaluatePartialHands: false));
// Concatenate hands
var a = Hand.Parse("9s 9d");
var b = Hand.Parse("2c 3h 4d");
var combined = a + b; // combines cards from both hands
Classes and important members
Hand— represents a collection ofCardinstances. Methods:Parse(string, EvaluationOptions?),GetStrength(EvaluationOptions?), andoperator+to concatenate hands.HandStrength— returned byGetStrength(); includesHandRanking,KickersandCardCount(the originating hand size used for tie-breaking).EvaluationOptions— configuration type with a global instance atEvaluationOptions.Globaland optional per-call overrides.
Options
Currently EvaluationOptions exposes two flags:
EvaluatePartialHands(bool, default true) — when true, hands with fewer than five cards will be evaluated for possible rankings (Pair, TwoPair, ThreeOfAKind, FourOfAKind, HighCard). When false,GetStrength()returns null for such hands.AllowDuplicateCards(bool, default false) — when false, creating or combining hands that would contain duplicate cards (same rank and suit) will throwDuplicateCardException. Set to true to allow duplicate cards (multi-deck) and enable Five-of-a-Kind detection.
Exceptions
DuplicateCardException— thrown when attempting to parse or combine hands that contain duplicate cards whileAllowDuplicateCardsis false. UseEvaluationOptionsto allow duplicates if desired.
Testing
Unit tests are organized under the Tests/ folder and cover ranking correctness, partial-hand behavior, duplicate-card handling, five-of-a-kind detection, operator+ behavior, parsing, and other sanity checks. Run the suite with dotnet test.
Dependencies See project files for referenced NuGet packages. The README no longer documents legacy performance tables or evaluator file usage.
| Product | Versions Compatible and additional computed target framework versions. |
|---|---|
| .NET | net5.0 was computed. net5.0-windows was computed. net6.0 was computed. net6.0-android was computed. net6.0-ios was computed. net6.0-maccatalyst was computed. net6.0-macos was computed. net6.0-tvos was computed. net6.0-windows was computed. net7.0 was computed. net7.0-android was computed. net7.0-ios was computed. net7.0-maccatalyst was computed. net7.0-macos was computed. net7.0-tvos was computed. net7.0-windows was computed. net8.0 was computed. net8.0-android was computed. net8.0-browser was computed. net8.0-ios was computed. net8.0-maccatalyst was computed. net8.0-macos was computed. net8.0-tvos was computed. net8.0-windows was computed. net9.0 was computed. net9.0-android was computed. net9.0-browser was computed. net9.0-ios was computed. net9.0-maccatalyst was computed. net9.0-macos was computed. net9.0-tvos was computed. net9.0-windows was computed. net10.0 was computed. net10.0-android was computed. net10.0-browser was computed. net10.0-ios was computed. net10.0-maccatalyst was computed. net10.0-macos was computed. net10.0-tvos was computed. net10.0-windows was computed. |
| .NET Core | netcoreapp2.0 was computed. netcoreapp2.1 was computed. netcoreapp2.2 was computed. netcoreapp3.0 was computed. netcoreapp3.1 was computed. |
| .NET Standard | netstandard2.0 is compatible. netstandard2.1 was computed. |
| .NET Framework | net461 was computed. net462 was computed. net463 was computed. net47 was computed. net471 was computed. net472 was computed. net48 was computed. net481 was computed. |
| MonoAndroid | monoandroid was computed. |
| MonoMac | monomac was computed. |
| MonoTouch | monotouch was computed. |
| Tizen | tizen40 was computed. tizen60 was computed. |
| Xamarin.iOS | xamarinios was computed. |
| Xamarin.Mac | xamarinmac was computed. |
| Xamarin.TVOS | xamarintvos was computed. |
| Xamarin.WatchOS | xamarinwatchos was computed. |
-
.NETStandard 2.0
- Combinatorics (>= 2.0.0)
- Humanizer.Core (>= 2.14.1)
- PcgRandom (>= 1.2.0)
- protobuf-net (>= 3.2.26)
NuGet packages
This package is not used by any NuGet packages.
GitHub repositories
This package is not used by any popular GitHub repositories.
| Version | Downloads | Last Updated |
|---|---|---|
| 2026.3.6 | 120 | 3/7/2026 |