Udostępnij za pośrednictwem


StreamSocketListener.TransferOwnership Method

Definition

Overloads

TransferOwnership(String)

Transfers ownership of the StreamSocketListener to the socket brokering service, which monitors socket activity and notifies the app through a background task if there is any activity.

TransferOwnership(String, SocketActivityContext)

Transfers ownership of the StreamSocketListener to the socket brokering service, which monitors socket activity and notifies the app through a background task if there is any activity.

TransferOwnership(String)

Transfers ownership of the StreamSocketListener to the socket brokering service, which monitors socket activity and notifies the app through a background task if there is any activity.

public:
 virtual void TransferOwnership(Platform::String ^ socketId) = TransferOwnership;
/// [Windows.Foundation.Metadata.Overload("TransferOwnership")]
void TransferOwnership(winrt::hstring const& socketId);
[Windows.Foundation.Metadata.Overload("TransferOwnership")]
public void TransferOwnership(string socketId);
function transferOwnership(socketId)
Public Sub TransferOwnership (socketId As String)

Parameters

socketId
String

Platform::String

winrt::hstring

A string the app uses to identify the transferred socket. The string should identify this socket uniquely within the app. When activity occurs on this socket, this string will be provided to the app to identify the socket.

Attributes

See also

Applies to

TransferOwnership(String, SocketActivityContext)

Transfers ownership of the StreamSocketListener to the socket brokering service, which monitors socket activity and notifies the app through a background task if there is any activity.

public:
 virtual void TransferOwnership(Platform::String ^ socketId, SocketActivityContext ^ data) = TransferOwnership;
/// [Windows.Foundation.Metadata.Overload("TransferOwnershipWithContext")]
void TransferOwnership(winrt::hstring const& socketId, SocketActivityContext const& data);
[Windows.Foundation.Metadata.Overload("TransferOwnershipWithContext")]
public void TransferOwnership(string socketId, SocketActivityContext data);
function transferOwnership(socketId, data)
Public Sub TransferOwnership (socketId As String, data As SocketActivityContext)

Parameters

socketId
String

Platform::String

winrt::hstring

A string the app uses to identify the transferred socket. The string should identify this socket uniquely within the app. When activity occurs on this socket, this string will be provided to the app to identify the socket.

data
SocketActivityContext

Use the SocketActivityContext to pass context information through the socket broker. When your app is notified by the broker of activity, this SocketActivityContext will be provided to your app to help establish the context in which you should handle the notification.

Attributes

See also

Applies to