QueryBuilder.Find<'T,'Q> 方法 (F#)
查詢運算子,會選取目前選取的第一個項目,且此項目滿足指定的條件。
Namespace/Module Path:Microsoft.FSharp.Linq
組件:FSharp.Core (在 FSharp.Core.dll 中)
// Signature:
member this.Find : QuerySource<'T,'Q> * ('T -> bool) -> 'T
// Usage:
queryBuilder.Find (source, predicate)
參數
source
型別: QuerySource<'T,'Q>輸入查詢。
predicate
型別:" T " - > bool測試的每個項目的函式。
例外狀況
例外狀況 |
條件 |
---|---|
擲回例外狀況,當項目不會傳回 true ,當評估由述詞。 |
傳回值
布林函式 predicate 傳回 true的第一個項目。
備註
如需詳細資訊和範例,請參閱 查詢運算式 (F#)。
平台
Windows 8 中, Windows 7, Windows Server 2012 上, Windows Server 2008 R2
版本資訊
F# 核心程式庫版本
支援版本:4.0,可攜式執行檔 (PE)。