05 2020 档案

摘要:Entity Framework Core配置DbContext的两种方式 ​ 使用Entity Framework 迁移过程 中遇到过一个问题,在这里拿出来晒晒。 Unable to create an object of type 'xxxContext'. For the different 阅读全文
posted @ 2020-05-25 21:20 boydenyol 阅读(4237) 评论(0) 推荐(0) 编辑
摘要:C# 语法糖——持续更新 1. return的switch写法 public string ReturnMethod(int x) { return x switch { 2 => "2", 3 => "3", _ => "default" //_ 代表switch中的default }; } 2. 阅读全文
posted @ 2020-05-24 10:26 boydenyol 阅读(1016) 评论(0) 推荐(2) 编辑
摘要:继续抽丝剥茧 ​ 我们知道在使用 、`xml ini json AddJsonFile json`配置源的时候,有这么两个参数: optional:配置文件可选 reloadOnChange:配置文件修改时进行重新加载 ​ OK,动手操练操练。 test.json文件: 测试代码: ​ 完美通过测试 阅读全文
posted @ 2020-05-23 11:17 boydenyol 阅读(463) 评论(2) 推荐(0) 编辑

点击右上角即可分享
微信分享提示