摘要: https://docs.microsoft.com/zh-cn/dotnet/csharp/language-reference/language-specification/documentation-comments#an-example 微软官方文档。 我想补充几点。 1.如果想要所有类或者 阅读全文
posted @ 2019-04-12 02:04 程序猿Grady 阅读(1758) 评论(0) 推荐(0) 编辑
摘要: 如题。我单元测试使用的是Xunit。 解决方案:使用管理员模式打开VS2017重新加载这个项目就解决了。 PS:该解决方案亲测有效,但是我觉得我应该没找到最好的解决方案(root cause),如果谁有,欢迎分享,万分感谢。 阅读全文
posted @ 2019-04-12 00:13 程序猿Grady 阅读(440) 评论(0) 推荐(0) 编辑
摘要: 比如现在有一个泛型类: public class Product<TItem> where TItem : Item , new() {} 想要获取它的类型Type需要使用: var type = typeof(Product<>).MakeGenericType(typeof(TItem)); 比 阅读全文
posted @ 2019-04-12 00:01 程序猿Grady 阅读(1829) 评论(0) 推荐(0) 编辑