Skip to content

v2.0.0

Choose a tag to compare

@cds-git cds-git released this 15 Jan 08:49
· 31 commits to main since this release
e4f0cda

Highlights

  • Unified API: Single Result<T> type replaces separate Result and Result<T>
  • 6 new operations for validation, recovery, and collection handling
  • Comprehensive async support across all operations

Breaking Changes

  • Result (void) replaced with Result<NoValue> for operations without return values

New Features

  • Try: wrap exception-throwing code into Results (d50ee86)
  • Ensure: declarative validation guards with predicate chains (de94822)
  • Recover: targeted error recovery by error type or predicate (b1aa87e)
  • Combine: aggregate 2-8 independent Results with optional selector (7524007)
  • Zip: fluent binary Result combination for pipelines (7524007)
  • Sequence: aggregate IEnumerable<Result<T>> into single Result (10362d6)
  • Traverse: transform collection elements and aggregate Results (10362d6)
  • Partition: separate successes from failures without short-circuiting (10362d6)

Migration

// Before
Result DeleteUser(int id) => Result.Success();
// After
Result<NoValue> DeleteUser(int id) => Result.Success();