- 博客(11)
- 收藏
- 关注
原创 判断一个网络问件是否存在,且不为空
if (cosmosWorker.StreamExists(srcFilepath)) { cosmosWorker.DownloadTsv(srcFilepath, @"D:\\SoftDeleteTsv"); } if ...
2018-08-08 10:24:20
173
原创 Entity Framework Code First Migrations
中文参考:https://www.cnblogs.com/panchunting/p/entity-framework-code-first-migrations.htmlthe following Topic:Building an Initial Model & DatabaseBefore we start using migrations we need a pro...
2018-08-05 11:27:08
264
原创 git 操作
1.每次都是在master下面git pull,如果不在master这个branch下面,需要git checkout master.2.在master branch之下,创建新的branch自由test code. git checkout -b dev/alias/xxx;3.git status 查看是否当前的branch在你新建的branch,且完全copy一份master。4...
2018-07-24 10:19:24
143
原创 操作Json 和 SelectTokens with JsonPath
JsonPath expression:$ the root object @ the current object .. recursive descent [] 下标操作符 * 通配符 ?() filter 条件 JToken. SelectToken SelectToken是JToken上的一个方法,它采用字符串路...
2018-07-21 21:49:53
7250
翻译 Web Api 中返回JSON 转成驼峰给前端的机制
在使用Web Api的时候,有时候只想返回JSON最好的方法是使用自定义的只返回Json Result的content negotiation代替Web Api中默认的content negotiation。Conneg通过实现IContentNegotiator的Negotiator方法实现扩展。Negotiator方法返回ContentNegotiationResult(它包装了你选择...
2018-07-20 11:10:06
2583
转载 C# stringEmpty 和string str="" 用哪个好
看.net源代码:String.Empty,NULL和""的区别string.Empty就相当于"" ,一般用于字符串的初始化 string a; Console.WriteLine(a); //这里会报错,因为没有初始化a string.Empty不分配存储空间 ""分配一个长度为空的存储空间 所以一般用string.Empty...
2018-07-19 10:20:18
1662
原创 Owin webApi合作
Web server 服务器主要是指像IIS这样一类的,用于处理request并返回response的工具.一般我们ASP.NET网站开发时所指的web server就是IIS了,但是还有一些开源的像Apache,Lighttpd, Nginx等在php和java领域以及开源社区都有很大的名声,并且Apache才是被使用最多的web server(大概占60%左右的市场)类库介绍H...
2018-07-18 17:27:11
803
原创 enum枚举传参
废话不多说,直接上code.//new enum public enum ViewerType { Viewer = 0, ViewerDiff, ViewerDiffOfTwo }//interface parameter PayLoadTriple GetViewerPayloads(string extern...
2018-07-18 17:22:18
8152
原创 读headfirst c#
异常控制:500page-540引用变量为Null,就是告诉c#,这个引用没有指向任何东西。只要使用,就会抛出NullReferenceException.没有代码是万无一失的,异常就是要帮助你找出并修正代码中未能达到预期的情况。事件与委托:540 需要电子版的私戳我吧。就发消息给我好了。我无法上传因为已经有了 ...
2018-07-12 00:07:34
726
空空如也
空空如也
TA创建的收藏夹 TA关注的收藏夹
TA关注的人