Back to Blog

相关文章

阅读更多 »

C# 智能枚举:优化版

问题:“LINQ 税” 在第 1 部分中,我们用 records 替换了魔法数字。为了查找特定的状态,我们使用了 LINQ:csharp var status = Status.All.SingleOrDe...