TransportContext.GetChannelBinding(ChannelBindingKind) Metoda

Definicja

Pobiera żądane powiązanie kanału.

public:
 abstract System::Security::Authentication::ExtendedProtection::ChannelBinding ^ GetChannelBinding(System::Security::Authentication::ExtendedProtection::ChannelBindingKind kind);
public abstract System.Security.Authentication.ExtendedProtection.ChannelBinding GetChannelBinding (System.Security.Authentication.ExtendedProtection.ChannelBindingKind kind);
public abstract System.Security.Authentication.ExtendedProtection.ChannelBinding? GetChannelBinding (System.Security.Authentication.ExtendedProtection.ChannelBindingKind kind);
abstract member GetChannelBinding : System.Security.Authentication.ExtendedProtection.ChannelBindingKind -> System.Security.Authentication.ExtendedProtection.ChannelBinding
Public MustOverride Function GetChannelBinding (kind As ChannelBindingKind) As ChannelBinding

Parametry

kind
ChannelBindingKind

Typ powiązania kanału do pobrania.

Zwraca

Żądany ChannelBindingelement lub null jeśli powiązanie kanału nie jest obsługiwane przez bieżący transport lub przez system operacyjny.

Wyjątki

kind element musi być Endpoint używany z TransportContext właściwością pobraną z TransportContext właściwości .

Uwagi

Możliwe wartości parametru kind to Endpoint lub Unique.

Jeśli aplikacja podejmie próbę pobrania tokenu powiązania kanału (CBT) z TransportContext właściwości przy użyciu GetChannelBinding metody i ChannelBindingKind parametru nie Endpointma wartości , zostanie HttpListenerRequest zgłoszony błąd NotSupportedException. Metoda HttpListenerRequest zastępuje metodę GetChannelBinding z implementacją wewnętrzną

Dotyczy

Zobacz też