Share via


WSHttpBinding.CreateBindingElements Metoda

Definice

Vrátí uspořádanou kolekci prvků vazby obsažených v aktuální vazbě.

public:
 override System::ServiceModel::Channels::BindingElementCollection ^ CreateBindingElements();
public override System.ServiceModel.Channels.BindingElementCollection CreateBindingElements ();
override this.CreateBindingElements : unit -> System.ServiceModel.Channels.BindingElementCollection
Public Overrides Function CreateBindingElements () As BindingElementCollection

Návraty

Obsahuje BindingElementCollection seřazený zásobník elementů vazby popsaných vazbou WSHttpBinding .

Výjimky

Sada režimů zabezpečení přenosu nemůže poskytovat spolehlivou relaci, která byla povolena.

Příklady

Následující příklad ukazuje, jak získat BindingElementCollection , který obsahuje seřazený zásobník elementů vazby popsané vazbou WSHttpBinding .

WSHttpBinding wsHttpBinding = new WSHttpBinding();
BindingElementCollection beCollection = wsHttpBinding.CreateBindingElements();
Dim wsHttpBinding As New WSHttpBinding()
Dim beCollection As BindingElementCollection = wsHttpBinding.CreateBindingElements()

Poznámky

Pořadí prvků vazby je důležité. Odráží pořadí, ve kterém jsou protokoly a přenosové kanály vytvořeny a naskládané.

Platí pro