StreamSocketListenerConnectionReceivedEventArgs StreamSocketListenerConnectionReceivedEventArgs StreamSocketListenerConnectionReceivedEventArgs StreamSocketListenerConnectionReceivedEventArgs Class

Definition

Provides data for a ConnectionReceived event on a StreamSocketListener object.

public : sealed class StreamSocketListenerConnectionReceivedEventArgs : IStreamSocketListenerConnectionReceivedEventArgs
public sealed class StreamSocketListenerConnectionReceivedEventArgs : IStreamSocketListenerConnectionReceivedEventArgs
Public NotInheritable Class StreamSocketListenerConnectionReceivedEventArgs Implements IStreamSocketListenerConnectionReceivedEventArgs
// This class does not provide a public constructor.
Attributes
Windows 10 requirements
Device family
Windows 10 (introduced v10.0.10240.0)
API contract
Windows.Foundation.UniversalApiContract (introduced v1)
Capabilities
ID_CAP_NETWORKING [Windows Phone]

Remarks

The StreamSocketListenerConnectionReceivedEventArgs is used to receive connection data on a StreamSocketListener object.

The StreamSocketListener.BindServiceNameAsync or StreamSocketListener.BindEndpointAsync method is used to bind a StreamSocketListener to a local service name or TCP port.

A StreamSocketListener.ConnectionReceived event occurs if a StreamSocketListener object has been bound to a local service name or TCP port and a connection is received. A StreamSocketListenerConnectionReceivedEventArgs instance is a parameter specified in the callback.

Properties

Socket Socket Socket Socket

The StreamSocket object created when a connection is received by the StreamSocketListener object.

public : StreamSocket Socket { get; }
public StreamSocket Socket { get; }
Public ReadOnly Property Socket As StreamSocket
var streamSocket = streamSocketListenerConnectionReceivedEventArgs.socket;
Value
StreamSocket StreamSocket StreamSocket StreamSocket

The StreamSocket object created when a connection is received by the StreamSocketListener object.

Additional features and requirements
Device family
Windows 10 (introduced v10.0.10240.0)
API contract
Windows.Foundation.UniversalApiContract (introduced v1)
Capabilities
ID_CAP_NETWORKING [Windows Phone]
See Also

See Also