DbExpressionBuilder.Case Yöntem
Tanım
Önemli
Bazı bilgiler ürünün ön sürümüyle ilgilidir ve sürüm öncesinde önemli değişiklikler yapılmış olabilir. Burada verilen bilgilerle ilgili olarak Microsoft açık veya zımni hiçbir garanti vermez.
Yeni bir DbCaseExpression oluşturur.
public:
static System::Data::Common::CommandTrees::DbCaseExpression ^ Case(System::Collections::Generic::IEnumerable<System::Data::Common::CommandTrees::DbExpression ^> ^ whenExpressions, System::Collections::Generic::IEnumerable<System::Data::Common::CommandTrees::DbExpression ^> ^ thenExpressions, System::Data::Common::CommandTrees::DbExpression ^ elseExpression);
public static System.Data.Common.CommandTrees.DbCaseExpression Case (System.Collections.Generic.IEnumerable<System.Data.Common.CommandTrees.DbExpression> whenExpressions, System.Collections.Generic.IEnumerable<System.Data.Common.CommandTrees.DbExpression> thenExpressions, System.Data.Common.CommandTrees.DbExpression elseExpression);
static member Case : seq<System.Data.Common.CommandTrees.DbExpression> * seq<System.Data.Common.CommandTrees.DbExpression> * System.Data.Common.CommandTrees.DbExpression -> System.Data.Common.CommandTrees.DbCaseExpression
Public Function Case (whenExpressions As IEnumerable(Of DbExpression), thenExpressions As IEnumerable(Of DbExpression), elseExpression As DbExpression) As DbCaseExpression
Parametreler
- whenExpressions
- IEnumerable<DbExpression>
Her bir durumun koşulunu sağlayan ifadelerin listesi.
- thenExpressions
- IEnumerable<DbExpression>
Her bir servis talebinin sonucunu sağlayan ifadelerin listesi.
- elseExpression
- DbExpression
Hiçbir büyük/küçük harf eşleşmediğinde sonucu tanımlayan ifade.
Döndürülenler
Belirtilen durumları ve varsayılan sonucu içeren yeni bir DbCaseExpression.
Özel durumlar
whenExpressions veya thenExpressions null veya null veya null içeriyor ya da elseExpression null.
whenExpressionsveya thenExpressions boş veya whenExpressions Boole olmayan sonuç türüne sahip bir ifade içeriyor veya ve elseExpressioniçindeki thenExpressions tüm ifadeler için ortak sonuç türü yok.