DbExpressionBuilder.Any 方法
定义
重要
一些信息与预发行产品相关,相应产品在发行之前可能会进行重大修改。 对于此处提供的信息,Microsoft 不作任何明示或暗示的担保。
创建一个新 DbExpression 值,用于确定指定的 set 参数是否为非空。
重载
| 名称 | 说明 |
|---|---|
| Any(DbExpression) |
创建一个新 DbExpression 值,用于确定指定的 set 参数是否为非空。 |
| Any(DbExpression, Func<DbExpression,DbExpression>) |
创建一个新 DbQuantifierExpression 值,用于确定给定谓词是否保留输入集的任何元素。 |
| Any(DbExpressionBinding, DbExpression) |
创建一个新 DbQuantifierExpression 值,用于确定给定谓词是否保留输入集的任何元素。 |
Any(DbExpression)
创建一个新 DbExpression 值,用于确定指定的 set 参数是否为非空。
public:
[System::Runtime::CompilerServices::Extension]
static System::Data::Common::CommandTrees::DbExpression ^ Any(System::Data::Common::CommandTrees::DbExpression ^ source);
public static System.Data.Common.CommandTrees.DbExpression Any(this System.Data.Common.CommandTrees.DbExpression source);
static member Any : System.Data.Common.CommandTrees.DbExpression -> System.Data.Common.CommandTrees.DbExpression
<Extension()>
Public Function Any (source As DbExpression) As DbExpression
参数
- source
- DbExpression
一个指定输入集的表达式。
返回
DbNotExpression应用于具有指定参数的新DbIsEmptyExpression的新项。
例外
source 为 null。
source 没有集合结果类型。
适用于
Any(DbExpression, Func<DbExpression,DbExpression>)
创建一个新 DbQuantifierExpression 值,用于确定给定谓词是否保留输入集的任何元素。
public:
[System::Runtime::CompilerServices::Extension]
static System::Data::Common::CommandTrees::DbQuantifierExpression ^ Any(System::Data::Common::CommandTrees::DbExpression ^ source, Func<System::Data::Common::CommandTrees::DbExpression ^, System::Data::Common::CommandTrees::DbExpression ^> ^ predicate);
public static System.Data.Common.CommandTrees.DbQuantifierExpression Any(this System.Data.Common.CommandTrees.DbExpression source, Func<System.Data.Common.CommandTrees.DbExpression,System.Data.Common.CommandTrees.DbExpression> predicate);
static member Any : System.Data.Common.CommandTrees.DbExpression * Func<System.Data.Common.CommandTrees.DbExpression, System.Data.Common.CommandTrees.DbExpression> -> System.Data.Common.CommandTrees.DbQuantifierExpression
<Extension()>
Public Function Any (source As DbExpression, predicate As Func(Of DbExpression, DbExpression)) As DbQuantifierExpression
参数
- source
- DbExpression
一个指定输入集的表达式。
- predicate
- Func<DbExpression,DbExpression>
一个表示要计算输入集每个成员的谓词的方法。 此方法必须生成一个具有布尔结果类型的表达式,该表达式提供谓词逻辑。
返回
一个新的 DbQuantifierExpression,表示 Any 操作。
例外
适用于
Any(DbExpressionBinding, DbExpression)
创建一个新 DbQuantifierExpression 值,用于确定给定谓词是否保留输入集的任何元素。
public:
[System::Runtime::CompilerServices::Extension]
static System::Data::Common::CommandTrees::DbQuantifierExpression ^ Any(System::Data::Common::CommandTrees::DbExpressionBinding ^ input, System::Data::Common::CommandTrees::DbExpression ^ predicate);
public static System.Data.Common.CommandTrees.DbQuantifierExpression Any(this System.Data.Common.CommandTrees.DbExpressionBinding input, System.Data.Common.CommandTrees.DbExpression predicate);
static member Any : System.Data.Common.CommandTrees.DbExpressionBinding * System.Data.Common.CommandTrees.DbExpression -> System.Data.Common.CommandTrees.DbQuantifierExpression
<Extension()>
Public Function Any (input As DbExpressionBinding, predicate As DbExpression) As DbQuantifierExpression
参数
- input
- DbExpressionBinding
一个指定输入集的表达式绑定。
- predicate
- DbExpression
一个表达式,表示要计算输入集的每个成员的谓词。
返回
一个新的 DbQuantifierExpression,表示 Any 操作。
例外
input 或 predicate 为 null。
由其 predicate 生成的表达式没有布尔结果类型。