Udostępnij za pośrednictwem


ReliableSession Konstruktory

Definicja

Inicjuje nowe wystąpienie klasy ReliableSession.

Przeciążenia

ReliableSession()

Inicjuje nowe wystąpienie klasy ReliableSession.

ReliableSession(ReliableSessionBindingElement)

Inicjuje ReliableSession nowe wystąpienie klasy z elementu powiązania niezawodnej sesji.

ReliableSession()

Inicjuje nowe wystąpienie klasy ReliableSession.

public:
 ReliableSession();
public ReliableSession ();
Public Sub New ()

Dotyczy

ReliableSession(ReliableSessionBindingElement)

Inicjuje ReliableSession nowe wystąpienie klasy z elementu powiązania niezawodnej sesji.

public:
 ReliableSession(System::ServiceModel::Channels::ReliableSessionBindingElement ^ reliableSessionBindingElement);
public:
 ReliableSession(System::ServiceModel::Channels::ReliableSessionBindingElement ^ binding);
public ReliableSession (System.ServiceModel.Channels.ReliableSessionBindingElement reliableSessionBindingElement);
public ReliableSession (System.ServiceModel.Channels.ReliableSessionBindingElement binding);
new System.ServiceModel.ReliableSession : System.ServiceModel.Channels.ReliableSessionBindingElement -> System.ServiceModel.ReliableSession
new System.ServiceModel.ReliableSession : System.ServiceModel.Channels.ReliableSessionBindingElement -> System.ServiceModel.ReliableSession
Public Sub New (reliableSessionBindingElement As ReliableSessionBindingElement)
Public Sub New (binding As ReliableSessionBindingElement)

Parametry

reliableSessionBindingElementbinding
ReliableSessionBindingElement

Których ReliableSessionBindingElement wartości właściwości są używane do inicjowania sesji niezawodnej.

Wyjątki

Element reliableSessionBindingElement to null.

Przykłady

// Create a new reliable session object
ReliableSessionBindingElement bindingElement = new ReliableSessionBindingElement();
ReliableSession reliableSession = new ReliableSession(bindingElement);

// Now you can access property values
Console.WriteLine("Ordered: {0}", reliableSession.Ordered);
Console.WriteLine("InactivityTimeout: {0}", reliableSession.InactivityTimeout);
reliableSession.Ordered = false;
Console.WriteLine("The new value for the Ordered property is: {0}", reliableSession.Ordered);
' Create a new reliable session object
Dim bindingElement As ReliableSessionBindingElement = New ReliableSessionBindingElement()
Dim reliableSession As ReliableSession = New ReliableSession(bindingElement)

' Now you can access property values
Console.WriteLine("Ordered: {0}", reliableSession.Ordered)
Console.WriteLine("InactivityTimeout: {0}", reliableSession.InactivityTimeout)
ReliableSession.Ordered = False
Console.WriteLine("The new value for the Ordered property is: {0}", ReliableSession.Ordered)

Dotyczy