diff --git a/xml/System.Net.Sockets/Socket.xml b/xml/System.Net.Sockets/Socket.xml index fd1cb71dd40..48c74589e24 100644 --- a/xml/System.Net.Sockets/Socket.xml +++ b/xml/System.Net.Sockets/Socket.xml @@ -781,8 +781,6 @@ This method populates the instance with data ga > [!NOTE] > The execution context (the security context, the impersonated user, and the calling context) is cached for the asynchronous methods. After the first use of a particular context (a specific asynchronous method, a specific instance, and a specific callback), subsequent uses of that context will see a performance improvement. - - ## Examples The following code example attempts to receive an incoming connection asynchronously. @@ -801,7 +799,7 @@ This method populates the instance with data ga The accepted socket is bound. is less than 0. - An error occurred when attempting to access the socket. + .NET Framework and .NET 5 and earlier only: An error occurred when attempting to access the socket. @@ -894,8 +892,6 @@ This method populates the instance with data ga > [!NOTE] > The execution context (the security context, the impersonated user, and the calling context) is cached for the asynchronous methods. After the first use of a particular context (a specific asynchronous method, a specific instance, and a specific callback), subsequent uses of that context will see a performance improvement. - - ## Examples The following code example opens a socket and accepts an asynchronous connection. In this example, the socket accepts the initial 10 bytes of data. The number of bytes received and the data are displayed on the console by the callback delegate. See for a description of how the remaining data is received. @@ -913,7 +909,7 @@ This method populates the instance with data ga The accepted socket is bound. is less than 0. - An error occurred when attempting to access the socket. + .NET Framework and .NET 5 and earlier only: An error occurred when attempting to access the socket. @@ -1002,8 +998,6 @@ This method populates the instance with data ga > [!NOTE] > The execution context (the security context, the impersonated user, and the calling context) is cached for the asynchronous methods. After the first use of a particular context (a specific asynchronous method, a specific instance, and a specific callback), subsequent uses of that context will see a performance improvement. - - ## Examples The following code example opens a socket and accepts an asynchronous connection. In this example, the socket accepts the initial 10 bytes of data and the `acceptSocket` parameter is `null`, which forces the method to create the accepted socket. The number of bytes received and the data are displayed on the console by the callback delegate. See for a description of how the remaining data is received. @@ -1021,7 +1015,7 @@ This method populates the instance with data ga The accepted socket is bound. is less than 0. - An error occurred when attempting to access the socket. + .NET Framework and .NET 5 and earlier only: An error occurred when attempting to access the socket. @@ -1122,8 +1116,6 @@ This method populates the instance with data ga > [!NOTE] > The execution context (the security context, the impersonated user, and the calling context) is cached for the asynchronous methods. After the first use of a particular context (a specific asynchronous method, a specific instance, and a specific callback), subsequent uses of that context will see a performance improvement. - - ## Examples The following code example initiates an asynchronous connection attempt. @@ -1135,7 +1127,7 @@ This method populates the instance with data ga is . - An error occurred when attempting to access the socket. + .NET Framework and .NET 5 and earlier only: An error occurred when attempting to access the socket. The has been closed. A caller higher in the call stack does not have permission for the requested operation. The has been placed in a listening state by calling , or an asynchronous operation is already in progress. @@ -1226,8 +1218,6 @@ This method populates the instance with data ga > [!NOTE] > The execution context (the security context, the impersonated user, and the calling context) is cached for the asynchronous methods. After the first use of a particular context (a specific asynchronous method, a specific instance, and a specific callback), subsequent uses of that context will see a performance improvement. - - ## Examples The following code example initiates an asynchronous connection attempt. @@ -1241,7 +1231,7 @@ This method populates the instance with data ga is . - An error occurred when attempting to access the socket. + .NET Framework and .NET 5 and earlier only: An error occurred when attempting to access the socket. The has been closed. The is not in the socket family. The port number is not valid. @@ -1334,8 +1324,6 @@ This method populates the instance with data ga > [!NOTE] > The execution context (the security context, the impersonated user, and the calling context) is cached for the asynchronous methods. After the first use of a particular context (a specific asynchronous method, a specific instance, and a specific callback), subsequent uses of that context will see a performance improvement. - - ## Examples The following code example initiates an asynchronous connection attempt. @@ -1349,7 +1337,7 @@ This method populates the instance with data ga is . - An error occurred when attempting to access the socket. + .NET Framework and .NET 5 and earlier only: An error occurred when attempting to access the socket. The has been closed. This method is valid for sockets that use or . The port number is not valid. @@ -1442,8 +1430,6 @@ This method populates the instance with data ga > [!NOTE] > The execution context (the security context, the impersonated user, and the calling context) is cached for the asynchronous methods. After the first use of a particular context (a specific asynchronous method, a specific instance, and a specific callback), subsequent uses of that context will see a performance improvement. - - ## Examples The following code example initiates an asynchronous connection attempt. @@ -1530,8 +1516,6 @@ This method populates the instance with data ga > [!NOTE] > This member outputs trace information when you enable network tracing in your application. For more information, see [Network Tracing in the .NET Framework](/dotnet/framework/network-programming/network-tracing). - - ## Examples The following code example creates a socket for asynchronous communication and sends some data to a remote host. When the data has been sent, is called to stop the send and receive activity. Then is called to begin a disconnect request. When the request completes, the property is queried to test whether the socket is disconnected. @@ -1541,7 +1525,7 @@ This method populates the instance with data ga ]]> The object has been closed. - An error occurred when attempting to access the socket. + .NET Framework and .NET 5 and earlier only: An error occurred when attempting to access the socket. @@ -1638,7 +1622,7 @@ This method populates the instance with data ga is . - An error occurred when attempting to access the socket. + .NET Framework and .NET 5 and earlier only: An error occurred when attempting to access the socket. has been closed. @@ -1736,7 +1720,7 @@ This method populates the instance with data ga is . - An error occurred when attempting to access the socket. + .NET Framework and .NET 5 and earlier only: An error occurred when attempting to access the socket. has been closed. @@ -1834,8 +1818,6 @@ This method populates the instance with data ga > [!NOTE] > The execution context (the security context, the impersonated user, and the calling context) is cached for the asynchronous methods. After the first use of a particular context (a specific asynchronous method, a specific instance, and a specific callback), subsequent uses of that context will see a performance improvement. - - ## Examples The following code example begins to asynchronously receive data from a connected . @@ -1855,7 +1837,7 @@ This method populates the instance with data ga is . - An error occurred when attempting to access the socket. + .NET Framework and .NET 5 and earlier only: An error occurred when attempting to access the socket. has been closed. @@ -1974,7 +1956,7 @@ This method populates the instance with data ga is . - An error occurred when attempting to access the socket. + .NET Framework and .NET 5 and earlier only: An error occurred when attempting to access the socket. has been closed. @@ -2095,8 +2077,6 @@ This method populates the instance with data ga > [!NOTE] > The execution context (the security context, the impersonated user, and the calling context) is cached for the asynchronous methods. After the first use of a particular context (a specific asynchronous method, a specific instance, and a specific callback), subsequent uses of that context will see a performance improvement. - - ## Examples The following code example asynchronously receives connectionless datagrams from a remote host. @@ -2112,7 +2092,7 @@ This method populates the instance with data ga -or- is . - An error occurred when attempting to access the socket. + .NET Framework and .NET 5 and earlier only: An error occurred when attempting to access the socket. is less than 0. @@ -2227,7 +2207,7 @@ This method populates the instance with data ga -or- is . - An error occurred when attempting to access the socket. + .NET Framework and .NET 5 and earlier only: An error occurred when attempting to access the socket. is less than 0. @@ -2340,7 +2320,7 @@ This method populates the instance with data ga is . is empty. - An error occurred when attempting to access the socket. See remarks section below. + .NET Framework and .NET 5 and earlier only: An error occurred when attempting to access the socket. See remarks section below. The has been closed. @@ -2443,7 +2423,7 @@ This method populates the instance with data ga is . is empty. - An error occurred when attempting to access the socket. See remarks section below. + .NET Framework and .NET 5 and earlier only: An error occurred when attempting to access the socket. See remarks section below. The has been closed. @@ -2542,7 +2522,7 @@ This method populates the instance with data ga is . - An error occurred when attempting to access the socket. See remarks section below. + .NET Framework and .NET 5 and earlier only: An error occurred when attempting to access the socket. See remarks section below. is less than 0. @@ -2657,8 +2637,6 @@ This method populates the instance with data ga > [!NOTE] > The execution context (the security context, the impersonated user, and the calling context) is cached for the asynchronous methods. After the first use of a particular context (a specific asynchronous method, a specific instance, and a specific callback), subsequent uses of that context will see a performance improvement. - - ## Examples The following code example begins asynchronously sending data to a remote host. @@ -2670,7 +2648,7 @@ This method populates the instance with data ga is . - An error occurred when attempting to access the socket. See remarks section below. + .NET Framework and .NET 5 and earlier only: An error occurred when attempting to access the socket. See remarks section below. is less than 0. @@ -2775,8 +2753,6 @@ This method populates the instance with data ga > [!NOTE] > The execution context (the security context, the impersonated user, and the calling context) is cached for the asynchronous methods. After the first use of a particular context (a specific asynchronous method, a specific instance, and a specific callback), subsequent uses of that context will see a performance improvement. - - ## Examples The following code example creates and connects a socket for asynchronous communication. First, the file "text.txt" is sent asynchronously to the remote host. The callback delegate calls to complete the transmission. @@ -2788,7 +2764,7 @@ This method populates the instance with data ga The object has been closed. The socket is not connected to a remote host. The file was not found. - An error occurred when attempting to access the socket. See remarks section below. + .NET Framework and .NET 5 and earlier only: An error occurred when attempting to access the socket. See remarks section below. @@ -2878,7 +2854,7 @@ This method populates the instance with data ga ]]> The object has been closed. - An error occurred when attempting to access the socket. See remarks section below. + .NET Framework and .NET 5 and earlier only: An error occurred when attempting to access the socket. See remarks section below. The operating system is not Windows NT or later. -or- @@ -2977,8 +2953,6 @@ This method populates the instance with data ga > [!NOTE] > The execution context (the security context, the impersonated user, and the calling context) is cached for the asynchronous methods. After the first use of a particular context (a specific asynchronous method, a specific instance, and a specific callback), subsequent uses of that context will see a performance improvement. - - ## Examples The following code example asynchronously sends data to the specified remote host. @@ -2994,7 +2968,7 @@ This method populates the instance with data ga -or- is . - An error occurred when attempting to access the socket. + .NET Framework and .NET 5 and earlier only: An error occurred when attempting to access the socket. is less than 0.