DbExpressionBuilder.BindAs(DbExpression, String) Metoda

Definice

Vytvoří novou DbExpressionBinding , která použije zadaný název proměnné k vytvoření vazby daného výrazu.

public:
[System::Runtime::CompilerServices::Extension]
 static System::Data::Common::CommandTrees::DbExpressionBinding ^ BindAs(System::Data::Common::CommandTrees::DbExpression ^ input, System::String ^ varName);
public static System.Data.Common.CommandTrees.DbExpressionBinding BindAs(this System.Data.Common.CommandTrees.DbExpression input, string varName);
static member BindAs : System.Data.Common.CommandTrees.DbExpression * string -> System.Data.Common.CommandTrees.DbExpressionBinding
<Extension()>
Public Function BindAs (input As DbExpression, varName As String) As DbExpressionBinding

Parametry

input
DbExpression

Výraz, který se má svázat.

varName
String

Název proměnné, který by se měl použít pro vazbu.

Návraty

Nová vazba výrazu se zadaným výrazem a názvem proměnné.

Výjimky

input nebo varName má hodnotu null.

input nemá výsledek kolekce.

Platí pro