随笔分类 - C# to IL
摘要:How to: Compare Strings (C# Programming Guide)When you compare strings, you are producing a result that says one string is greater than or less than the other, or that the two strings are equal. The rules by which the result is determined are different depending on whether you are performing ordinal
阅读全文
摘要:View Code 自定义属性类 阅读目录 一:属性 二:自定义属性类BookAttribute实例 . 属性是由属性类来实现的,向上篇文章《C#温故而知新学习系列之.NET框架高级特性—.NET框架中自身提供的属性(二)》我们讲的Obsolete一样,我们还可以自定义属性类,属性类是由System.Attribute派生而来的 . 在C#中为了方便起见,使用自定义属性时可以省略属性名后面的Attribute,比如:下面讲到的[BookAttribute("自定义属性类")]可以改写为[Books("自定义属性类")] . 自定义属性类的特点 1:使用A
阅读全文