Bookcold

导航

Lambda表达式对List的处理

 

Lambda表达式使得List的过滤和排序更加简洁!

定义一个Employee类:

1: public class Employee 2: { 3: public string FirstName {set; get;} 4: public string LastName {set; get;} 5: public decimal Salary {set; get;} 6: public bool IsManager {set; get;} 7: } .csharpcode, .csharpcode pre { font-size: small; color: black; font-family: consolas, "Courier New", courier, monospace; background-color: #ffffff; /*white-space: pre;*/ [...]

posted on 2010-01-21 00:11  bookcold  阅读(234)  评论(0)    收藏  举报