Sco*_*ker 2 .net c# linq iqueryable
我有一个简单的(混淆的)类:
public Thing ()
{
public IList<string> Strings()
{
// returns an IList of whatever,
// using strings as an example
}
}
Run Code Online (Sandbox Code Playgroud)
在我的代码中的其他地方我IQueryable<Thing> things从数据库中检索一个
我的目标是将所有strings从一个things变为一个IQueryable<string> strings,可能是这样的:
var strings = from t in things
select t.Strings()
Run Code Online (Sandbox Code Playgroud)
但那只能让我受益匪浅IQueryable<IList<string>>.如何将所有这些列表整合到一个无所不包的集合中?
| 归档时间: |
|
| 查看次数: |
152 次 |
| 最近记录: |