语言

DbExpressionBuilder.In 方法

定义

创建一个 DbInExpression 与指定列表中的常量表达式的结果匹配的指定表达式的结果。

public static System.Data.Entity.Core.Common.CommandTrees.DbInExpression In(this System.Data.Entity.Core.Common.CommandTrees.DbExpression expression, System.Collections.Generic.IList<System.Data.Entity.Core.Common.CommandTrees.DbConstantExpression> list);
static member In : System.Data.Entity.Core.Common.CommandTrees.DbExpression * System.Collections.Generic.IList<System.Data.Entity.Core.Common.CommandTrees.DbConstantExpression> -> System.Data.Entity.Core.Common.CommandTrees.DbInExpression
<Extension()>
Public Function In (expression As DbExpression, list As IList(Of DbConstantExpression)) As DbInExpression

参数

expression
DbExpression

要匹配的 DbExpression。

list
IList<DbConstantExpression>

要测试匹配的 DbConstantExpression 的列表。

返回

具有指定参数的新 DbInExpression。

例外

expression 或 list 为 null。

结果类型 expression 与表达式 list的结果类型不同。

适用于