Using .ToDictionary()

后端 未结 7 1963
北荒
北荒 2020-12-25 09:27

I have a method returning a List, let\'s call it GetSomeStrings().

I have an extension method on string class, returning number of characters in the str

相关标签:
7条回答
  • 2020-12-25 10:31
    var users = this.context.ad_user.ToDictionary(v => v.DistinguishedName,
    v => new ad_user
    {
         DistinguishedName = v.DistinguishedName,
         CN = v.CN,
         DisplayName = v.DisplayName,
         Info = v.Info,
         Mail = v.Mail
     });
    
    0 讨论(0)
提交回复
热议问题