From 11bad29c5caf17d187bce61765590332fc4b4733 Mon Sep 17 00:00:00 2001 From: Genevieve Warren <24882762+gewarren@users.noreply.github.com> Date: Mon, 3 Feb 2025 18:58:19 -0800 Subject: [PATCH] fix paramrefs for System.Net --- xml/System.Net.Http.Headers/HttpHeaders.xml | 42 +- xml/System.Net.Mail/Attachment.xml | 260 ++- xml/System.Net.Mail/SmtpClient.xml | 1474 ++++++++--------- .../GatewayIPAddressInformationCollection.xml | 58 +- ...ulticastIPAddressInformationCollection.xml | 58 +- .../PhysicalAddress.xml | 260 +-- xml/System.Net.NetworkInformation/Ping.xml | 920 +++++----- .../UnicastIPAddressInformationCollection.xml | 56 +- .../PeerContact.xml | 653 ++++---- xml/System.Net.Security/NegotiateStream.xml | 6 +- xml/System.Net.Security/SslStream.xml | 8 +- .../IPv6MulticastOption.xml | 100 +- xml/System.Net.Sockets/MulticastOption.xml | 112 +- xml/System.Net.Sockets/Socket.xml | 34 +- .../SocketTaskExtensions.xml | 50 +- xml/System.Net.Sockets/TcpClient.xml | 6 +- xml/System.Net.Sockets/UdpClient.xml | 6 +- xml/System.Net/CookieContainer.xml | 12 +- xml/System.Net/CredentialCache.xml | 300 ++-- xml/System.Net/HttpListenerRequest.xml | 2 +- xml/System.Net/HttpWebRequest.xml | 12 +- xml/System.Net/IPAddress.xml | 7 +- xml/System.Net/SocketAddress.xml | 96 +- xml/System.Net/WebClient.xml | 4 +- xml/System.Net/WebHeaderCollection.xml | 10 +- 25 files changed, 2252 insertions(+), 2294 deletions(-) diff --git a/xml/System.Net.Http.Headers/HttpHeaders.xml b/xml/System.Net.Http.Headers/HttpHeaders.xml index 6f6806fd170..e010c06a587 100644 --- a/xml/System.Net.Http.Headers/HttpHeaders.xml +++ b/xml/System.Net.Http.Headers/HttpHeaders.xml @@ -144,17 +144,17 @@ A list of header values to add to the collection. Adds the specified header and its values into the collection. - method inserts a new header into the list of header name/value pairs. + + If the specified header is already present, `values` are added to the comma-separated list of values associated with the header. - The header `values` will be parsed and validated. - - If the specified header does not exist, the method inserts a new header into the list of header name/value pairs. - - If the specified header is already present, `values` are added to the comma-separated list of values associated with the header. - ]]> The name cannot be null or empty. @@ -215,17 +215,17 @@ The header value format is invalid for this header name, or the header does not The content of the header. Adds the specified header and its value into the collection. - method inserts a new header into the list of header name/value pairs. + + If the specified header is already present, `value` is added to the comma-separated list of values associated with the header. - The header `values` will be parsed and validated. - - If the specified header does not exist, the method inserts a new header into the list of header name/value pairs. - - If the specified header is already present, `value` is added to the comma-separated list of values associated with the header. - ]]> The name cannot be null or empty. @@ -471,7 +471,7 @@ The header value format is invalid for this header name, or the header does not The name of the header to remove from the collection. Removes the specified header from the collection. - if is successfully removed; otherwise, . This method also returns if was not found in the collection or if is . + if is successfully removed; otherwise, . This method also returns if was not found in the collection or if is . To be added. diff --git a/xml/System.Net.Mail/Attachment.xml b/xml/System.Net.Mail/Attachment.xml index b3fe4dc7d4f..daed9b00834 100644 --- a/xml/System.Net.Mail/Attachment.xml +++ b/xml/System.Net.Mail/Attachment.xml @@ -47,27 +47,27 @@ Represents an attachment to an email. - class is used with the class. All messages include a , which contains the content of the message. In addition to the body, you might want to send additional files. These are sent as attachments and are represented as instances. To add an attachment to a mail message, add it to the collection. - - Attachment content can be a , , or file name. You can specify the content in an attachment by using any of the constructors. - - The MIME Content-Type header information for the attachment is represented by the property. The Content-Type header specifies the media type and subtype and any associated parameters. Use to get the instance associated with an attachment. - - The MIME Content-Disposition header is represented by the property. The Content-Disposition header specifies the presentation and file time stamps for an attachment. A Content-Disposition header is sent only if the attachment is a file. Use the property to get the instance associated with an attachment. - - The MIME Content-Transfer-Encoding header is represented by the property. - - - -## Examples - The following code example demonstrates attaching a file to an email message. - + class is used with the class. All messages include a , which contains the content of the message. In addition to the body, you might want to send additional files. These are sent as attachments and are represented as instances. To add an attachment to a mail message, add it to the collection. + + Attachment content can be a , , or file name. You can specify the content in an attachment by using any of the constructors. + + The MIME Content-Type header information for the attachment is represented by the property. The Content-Type header specifies the media type and subtype and any associated parameters. Use to get the instance associated with an attachment. + + The MIME Content-Disposition header is represented by the property. The Content-Disposition header specifies the presentation and file time stamps for an attachment. A Content-Disposition header is sent only if the attachment is a file. Use the property to get the instance associated with an attachment. + + The MIME Content-Transfer-Encoding header is represented by the property. + + + +## Examples + The following code example demonstrates attaching a file to an email message. + :::code language="cpp" source="~/snippets/cpp/VS_Snippets_Remoting/NCLMailSync/CPP/NclMailSync.cpp" id="Snippet6"::: - :::code language="csharp" source="~/snippets/csharp/System.Net.Mail/Attachment/Overview/mail.cs" id="Snippet6"::: - + :::code language="csharp" source="~/snippets/csharp/System.Net.Mail/Attachment/Overview/mail.cs" id="Snippet6"::: + ]]> @@ -119,24 +119,24 @@ A that contains a file path to use to create this attachment. Initializes a new instance of the class with the specified content string. - |.| -||.| - - - -## Examples - The following code example demonstrates how to call this constructor. - + |.| +||.| + + + +## Examples + The following code example demonstrates how to call this constructor. + :::code language="cpp" source="~/snippets/cpp/VS_Snippets_Remoting/NCLMailSync/CPP/NclMailSync.cpp" id="Snippet13"::: - :::code language="csharp" source="~/snippets/csharp/System.Net.Mail/Attachment/Overview/mail.cs" id="Snippet13"::: - + :::code language="csharp" source="~/snippets/csharp/System.Net.Mail/Attachment/Overview/mail.cs" id="Snippet13"::: + ]]> @@ -184,28 +184,28 @@ A that describes the data in . Initializes a new instance of the class with the specified stream and content type. - property is set to . - - If the stream's property is `false`, the attachment and the that contains it are not reusable. You must supply a stream that can be searched to reuse an attachment. - - - -## Examples - The following code example demonstrates how to call this constructor. - + property is set to . + + If the stream's property is `false`, the attachment and the that contains it are not reusable. You must supply a stream that can be searched to reuse an attachment. + + + +## Examples + The following code example demonstrates how to call this constructor. + :::code language="cpp" source="~/snippets/cpp/VS_Snippets_Remoting/NCLMailSync/CPP/NclMailSync.cpp" id="Snippet14"::: - :::code language="csharp" source="~/snippets/csharp/System.Net.Mail/Attachment/Overview/mail.cs" id="Snippet14"::: - + :::code language="csharp" source="~/snippets/csharp/System.Net.Mail/Attachment/Overview/mail.cs" id="Snippet14"::: + ]]> - is . - - -or- - + is . + + -or- + is . @@ -256,21 +256,21 @@ A that contains the value for the property of the associated with this attachment. This value can be . Initializes a new instance of the class with the specified stream and name. - (""), the for this attachment is constructed with the property set to `name`. The property is set to . - - If the stream's property is `false`, the attachment and the that contains it are not reusable. You must supply a stream that can be searched in order to reuse an attachment. - - - -## Examples - The following code example demonstrates how to call this constructor. - + (""), the for this attachment is constructed with the property set to `name`. The property is set to . + + If the stream's property is `false`, the attachment and the that contains it are not reusable. You must supply a stream that can be searched in order to reuse an attachment. + + + +## Examples + The following code example demonstrates how to call this constructor. + :::code language="cpp" source="~/snippets/cpp/VS_Snippets_Remoting/NCLMailSync/CPP/NclMailSync.cpp" id="Snippet15"::: - :::code language="csharp" source="~/snippets/csharp/System.Net.Mail/Attachment/Overview/mail.cs" id="Snippet15"::: - + :::code language="csharp" source="~/snippets/csharp/System.Net.Mail/Attachment/Overview/mail.cs" id="Snippet15"::: + ]]> @@ -319,7 +319,7 @@ is . - is not in the correct format. + is not in the correct format. @@ -369,19 +369,19 @@ A that contains the MIME Content-Header information for this attachment. This value can be . Initializes a new instance of the class with the specified content string and MIME type information. - (""), the property for this attachment is set to . If `mediaType` is not `null` and is not a zero-length string, it is used to construct the associated with this attachment. - - - -## Examples - The following code example demonstrates how to call this constructor. - + (""), the property for this attachment is set to . If `mediaType` is not `null` and is not a zero-length string, it is used to construct the associated with this attachment. + + + +## Examples + The following code example demonstrates how to call this constructor. + :::code language="cpp" source="~/snippets/cpp/VS_Snippets_Remoting/NCLMailSync/CPP/NclMailSync.cpp" id="Snippet12"::: - :::code language="csharp" source="~/snippets/csharp/System.Net.Mail/Attachment/Overview/mail.cs" id="Snippet12"::: - + :::code language="csharp" source="~/snippets/csharp/System.Net.Mail/Attachment/Overview/mail.cs" id="Snippet12"::: + ]]> @@ -439,27 +439,25 @@ A that contains the MIME Content-Header information for this attachment. This value can be . Initializes a new instance of the class with the specified stream, name, and MIME type information. - (""), it is used to construct the class associated with this attachment. - - If `mediaType` and `name` both contain information, the value specified in `name` is used. The property is set to . - - If the stream's property is `false`, the attachment and the that contains it are not reusable. You must supply a stream that can be searched in order to reuse an attachment. - - - -## Examples - The following code example demonstrates how to call this constructor. - + (""), it is used to construct the class associated with this attachment. + + If `mediaType` and `name` both contain information, the value specified in `name` is used. The property is set to . + + If the stream's property is `false`, the attachment and the that contains it are not reusable. You must supply a stream that can be searched in order to reuse an attachment. + +## Examples + The following code example demonstrates how to call this constructor. + :::code language="cpp" source="~/snippets/cpp/VS_Snippets_Remoting/NCLMailSync/CPP/NclMailSync.cpp" id="Snippet16"::: - :::code language="csharp" source="~/snippets/csharp/System.Net.Mail/Attachment/Overview/mail.cs" id="Snippet16"::: - + :::code language="csharp" source="~/snippets/csharp/System.Net.Mail/Attachment/Overview/mail.cs" id="Snippet16"::: + ]]> - is . + is . is not in the correct format. @@ -502,19 +500,19 @@ Gets the MIME content disposition for this attachment. A that provides the presentation information for this attachment. - class represents the MIME Content-Disposition header. This header is described in RFC 2183, available at [https://www.ietf.org/](https://www.ietf.org/). - - - -## Examples - The following code example gets the for an attachment and displays its properties. - + class represents the MIME Content-Disposition header. This header is described in RFC 2183, available at [https://www.ietf.org/](https://www.ietf.org/). + + + +## Examples + The following code example gets the for an attachment and displays its properties. + :::code language="cpp" source="~/snippets/cpp/VS_Snippets_Remoting/NCLMailSync/CPP/NclMailSync.cpp" id="Snippet11"::: - :::code language="csharp" source="~/snippets/csharp/System.Net.Mail/Attachment/Overview/mail.cs" id="Snippet11"::: - + :::code language="csharp" source="~/snippets/csharp/System.Net.Mail/Attachment/Overview/mail.cs" id="Snippet11"::: + ]]> @@ -625,13 +623,13 @@ Creates a mail attachment using the content from the specified string, and the specified MIME content type name. An object of type . - @@ -735,21 +733,21 @@ Gets or sets the MIME content type name value in the content type associated with this attachment. - A that contains the value for the content type represented by the property. + A that contains the value for the content type name represented by the property. - property is used in the Content-Type header generated for this attachment. The is displayed as the attachment's name when the email with the attachment is received. A grammar that details the syntax of the Content-Type header is described in RFC 2045 Section 5.1. RFC 2046 provides detailed information about MIME media types and their parameters. These RFCs are available at [https://www.ietf.org/](https://www.ietf.org/). - - - -## Examples - The following code example demonstrates how to display information about an attachment. - + property is used in the Content-Type header generated for this attachment. The is displayed as the attachment's name when the email with the attachment is received. A grammar that details the syntax of the Content-Type header is described in RFC 2045 Section 5.1. RFC 2046 provides detailed information about MIME media types and their parameters. These RFCs are available at [https://www.ietf.org/](https://www.ietf.org/). + + + +## Examples + The following code example demonstrates how to display information about an attachment. + :::code language="cpp" source="~/snippets/cpp/VS_Snippets_Remoting/NCLMailSync/CPP/NclMailSync.cpp" id="Snippet19"::: - :::code language="csharp" source="~/snippets/csharp/System.Net.Mail/Attachment/Overview/mail.cs" id="Snippet19"::: - + :::code language="csharp" source="~/snippets/csharp/System.Net.Mail/Attachment/Overview/mail.cs" id="Snippet19"::: + ]]> The value specified for a set operation is . diff --git a/xml/System.Net.Mail/SmtpClient.xml b/xml/System.Net.Mail/SmtpClient.xml index 02b5d854808..11a34fd54a3 100644 --- a/xml/System.Net.Mail/SmtpClient.xml +++ b/xml/System.Net.Mail/SmtpClient.xml @@ -62,7 +62,7 @@ [!IMPORTANT] > We don't recommend that you use the `SmtpClient` class for new development because `SmtpClient` doesn't support many modern protocols. Use [MailKit](https://github.com/jstedfast/MailKit) or other libraries instead. For more information, see [SmtpClient shouldn't be used](https://github.com/dotnet/platform-compat/blob/master/docs/DE0005.md). @@ -73,49 +73,49 @@ The `SmtpClient` class is: - Present and can be used in .NET Framework 4 through .NET Framework 4.8. - Usable in .NET (Core), but its use isn't recommended. -The classes shown in the following table are used to construct email messages that can be sent using . - +The classes shown in the following table are used to construct email messages that can be sent using . + | Class | Description | |------------------------------------|------------------------------------------------------------| | | Represents file attachments. This class allows you to attach files, streams, or text to an email message. | | | Represents the email address of the sender and recipients. | -| | Represents an email message. | - - To construct and send an email message by using , you must specify the following information: - -- The SMTP host server that you use to send email. See the and properties. -- Credentials for authentication, if required by the SMTP server. See the property. -- The email address of the sender. See the and methods that take a `from` parameter. Also see the property. -- The email address or addresses of the recipients. See the and methods that take a `recipient` parameter. Also see the property. +| | Represents an email message. | + + To construct and send an email message by using , you must specify the following information: + +- The SMTP host server that you use to send email. See the and properties. +- Credentials for authentication, if required by the SMTP server. See the property. +- The email address of the sender. See the and methods that take a `from` parameter. Also see the property. +- The email address or addresses of the recipients. See the and methods that take a `recipient` parameter. Also see the property. - The message content. See the and methods that take a `body` parameter. Also see the property. -To include an attachment with an email message, first create the attachment by using the class, and then add it to the message by using the property. Depending on the email reader used by the recipients and the file type of the attachment, some recipients might not be able to read the attachment. For clients that cannot display the attachment in its original form, you can specify alternate views by using the property. - - In .NET Framework, you can use the application or machine configuration files to specify default host, port, and credentials values for all objects. For more information, see [<mailSettings> Element (Network Settings)](/dotnet/framework/configure-apps/file-schema/network/mailsettings-element-network-settings). .NET Core does not support setting defaults. As a workaround, you must set the relevant properties on directly. - - To send the email message and block while waiting for the email to be transmitted to the SMTP server, use one of the synchronous methods. To allow your program's main thread to continue executing while the email is transmitted, use one of the asynchronous methods. The event is raised when a operation completes. To receive this event, you must add a delegate to . The delegate must reference a callback method that handles notification of events. To cancel an asynchronous email transmission, use the method. - +To include an attachment with an email message, first create the attachment by using the class, and then add it to the message by using the property. Depending on the email reader used by the recipients and the file type of the attachment, some recipients might not be able to read the attachment. For clients that cannot display the attachment in its original form, you can specify alternate views by using the property. + + In .NET Framework, you can use the application or machine configuration files to specify default host, port, and credentials values for all objects. For more information, see [<mailSettings> Element (Network Settings)](/dotnet/framework/configure-apps/file-schema/network/mailsettings-element-network-settings). .NET Core does not support setting defaults. As a workaround, you must set the relevant properties on directly. + + To send the email message and block while waiting for the email to be transmitted to the SMTP server, use one of the synchronous methods. To allow your program's main thread to continue executing while the email is transmitted, use one of the asynchronous methods. The event is raised when a operation completes. To receive this event, you must add a delegate to . The delegate must reference a callback method that handles notification of events. To cancel an asynchronous email transmission, use the method. + > [!NOTE] -> If there is an email transmission in progress and you call or again, you will receive an . - - The connection established by the current instance of the class to the SMTP server may be re-used if an application wishes to send multiple messages to the same SMTP server. This is particularly useful when authentication or encryption are used establish a connection to the SMTP server. The process of authenticating and establishing a TLS session can be expensive operations. A requirement to re-establish a connection for each message when sending a large quantity of email to the same SMTP server could have a significant impact on performance. There are a number of high-volume email applications that send email status updates, newsletter distributions, or email alerts. Also many email client applications support an off-line mode where users can compose many email messages that are sent later when a connection to the SMTP server is established. It is typical for an email client to send all SMTP messages to a specific SMTP server (provided by the Internet service provider) that then forwards this email to other SMTP servers. - - The class implementation pools SMTP connections so that it can avoid the overhead of re-establishing a connection for every message to the same server. An application may re-use the same object to send many different emails to the same SMTP server and to many different SMTP servers. As a result, there is no way to determine when an application is finished using the object and it should be cleaned up. - - When an SMTP session is finished and the client wishes to terminate the connection, it must send a QUIT message to the server to indicate that it has no more messages to send. This allows the server to free up resources associated with the connection from the client and process the messages which were sent by the client. - - The class has no `Finalize` method, so an application must call to explicitly free up resources. The method iterates through all established connections to the SMTP server specified in the property and sends a QUIT message followed by gracefully ending the TCP connection. The method also releases the unmanaged resources used by the and optionally disposes of the managed resources. - +> If there is an email transmission in progress and you call or again, you will receive an . + + The connection established by the current instance of the class to the SMTP server may be re-used if an application wishes to send multiple messages to the same SMTP server. This is particularly useful when authentication or encryption are used establish a connection to the SMTP server. The process of authenticating and establishing a TLS session can be expensive operations. A requirement to re-establish a connection for each message when sending a large quantity of email to the same SMTP server could have a significant impact on performance. There are a number of high-volume email applications that send email status updates, newsletter distributions, or email alerts. Also many email client applications support an off-line mode where users can compose many email messages that are sent later when a connection to the SMTP server is established. It is typical for an email client to send all SMTP messages to a specific SMTP server (provided by the Internet service provider) that then forwards this email to other SMTP servers. + + The class implementation pools SMTP connections so that it can avoid the overhead of re-establishing a connection for every message to the same server. An application may re-use the same object to send many different emails to the same SMTP server and to many different SMTP servers. As a result, there is no way to determine when an application is finished using the object and it should be cleaned up. + + When an SMTP session is finished and the client wishes to terminate the connection, it must send a QUIT message to the server to indicate that it has no more messages to send. This allows the server to free up resources associated with the connection from the client and process the messages which were sent by the client. + + The class has no `Finalize` method, so an application must call to explicitly free up resources. The method iterates through all established connections to the SMTP server specified in the property and sends a QUIT message followed by gracefully ending the TCP connection. The method also releases the unmanaged resources used by the and optionally disposes of the managed resources. + Call when you are finished using the . The method leaves the in an unusable state. After calling , you must release all references to the so the garbage collector can reclaim the memory that the was occupying. -## Examples +## Examples + +The following code example demonstrates sending an email message asynchronously. -The following code example demonstrates sending an email message asynchronously. - :::code language="cpp" source="~/snippets/cpp/VS_Snippets_Remoting/NclMailASync/cpp/mailasync.cpp" id="Snippet1"::: :::code language="csharp" source="~/snippets/csharp/System.Net.Mail/MailAddress/.ctor/mailasync.cs" id="Snippet1"::: - :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_Remoting/NclMailASync/vb/mailasync.vb" id="Snippet1"::: - + :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_Remoting/NclMailASync/vb/mailasync.vb" id="Snippet1"::: + ]]> @@ -168,21 +168,21 @@ The following code example demonstrates sending an email message asynchronously. Initializes a new instance of the class by using configuration file settings. - , , and properties for the new by using the settings in the application or machine configuration files. For more information, see [<mailSettings> Element (Network Settings)](/dotnet/framework/configure-apps/file-schema/network/mailsettings-element-network-settings). - - - -## Examples - The following code example demonstrates sending an email message. - + , , and properties for the new by using the settings in the application or machine configuration files. For more information, see [<mailSettings> Element (Network Settings)](/dotnet/framework/configure-apps/file-schema/network/mailsettings-element-network-settings). + + + +## Examples + The following code example demonstrates sending an email message. + :::code language="cpp" source="~/snippets/cpp/VS_Snippets_Remoting/NCLMailSync/CPP/NclMailSync.cpp" id="Snippet4"::: - :::code language="csharp" source="~/snippets/csharp/System.Net.Mail/Attachment/Overview/mail.cs" id="Snippet4"::: - - For an example of the \ node in the application or machine configuration file, see [<mailSettings> Element (Network Settings)](/dotnet/framework/configure-apps/file-schema/network/mailsettings-element-network-settings). - + :::code language="csharp" source="~/snippets/csharp/System.Net.Mail/Attachment/Overview/mail.cs" id="Snippet4"::: + + For an example of the \ node in the application or machine configuration file, see [<mailSettings> Element (Network Settings)](/dotnet/framework/configure-apps/file-schema/network/mailsettings-element-network-settings). + ]]> @@ -225,21 +225,21 @@ The following code example demonstrates sending an email message asynchronously. A that contains the name or IP address of the host computer used for SMTP transactions. Initializes a new instance of the class that sends email by using the specified SMTP server. - property. The and properties are initialized by using the settings in the application or machine configuration files. If `host` is `null` or equal to , is initialized using the settings in the application or machine configuration files. - - For more information about using the application and machine configuration files, see [<mailSettings> Element (Network Settings)](/dotnet/framework/configure-apps/file-schema/network/mailsettings-element-network-settings). If information is specified using constructors or properties, this information overrides the configuration file settings. - - - -## Examples - The following code example demonstrates calling this constructor. - + property. The and properties are initialized by using the settings in the application or machine configuration files. If `host` is `null` or equal to , is initialized using the settings in the application or machine configuration files. + + For more information about using the application and machine configuration files, see [<mailSettings> Element (Network Settings)](/dotnet/framework/configure-apps/file-schema/network/mailsettings-element-network-settings). If information is specified using constructors or properties, this information overrides the configuration file settings. + + + +## Examples + The following code example demonstrates calling this constructor. + :::code language="cpp" source="~/snippets/cpp/VS_Snippets_Remoting/NCLMailSync/CPP/NclMailSync.cpp" id="Snippet3"::: - :::code language="csharp" source="~/snippets/csharp/System.Net.Mail/Attachment/Overview/mail.cs" id="Snippet3"::: - + :::code language="csharp" source="~/snippets/csharp/System.Net.Mail/Attachment/Overview/mail.cs" id="Snippet3"::: + ]]> @@ -284,21 +284,21 @@ The following code example demonstrates sending an email message asynchronously. An greater than zero that contains the port to be used on . Initializes a new instance of the class that sends email by using the specified SMTP server and port. - and properties, respectively. If `host` is `null` or equal to , is initialized using the settings in the application or machine configuration files. If `port` is zero, is initialized using the settings in the application or machine configuration files. The property is initialized using the settings in the application or machine configuration files. - - For more information about using the application and machine configuration files, see [<mailSettings> Element (Network Settings)](/dotnet/framework/configure-apps/file-schema/network/mailsettings-element-network-settings). If information is specified using constructors or properties, this information overrides the configuration file settings. - - - -## Examples - The following code example demonstrates calling this constructor. - + and properties, respectively. If `host` is `null` or equal to , is initialized using the settings in the application or machine configuration files. If `port` is zero, is initialized using the settings in the application or machine configuration files. The property is initialized using the settings in the application or machine configuration files. + + For more information about using the application and machine configuration files, see [<mailSettings> Element (Network Settings)](/dotnet/framework/configure-apps/file-schema/network/mailsettings-element-network-settings). If information is specified using constructors or properties, this information overrides the configuration file settings. + + + +## Examples + The following code example demonstrates calling this constructor. + :::code language="cpp" source="~/snippets/cpp/VS_Snippets_Remoting/NCLMailSync/CPP/NclMailSync.cpp" id="Snippet1"::: - :::code language="csharp" source="~/snippets/csharp/System.Net.Mail/Attachment/Overview/mail.cs" id="Snippet1"::: - + :::code language="csharp" source="~/snippets/csharp/System.Net.Mail/Attachment/Overview/mail.cs" id="Snippet1"::: + ]]> @@ -348,21 +348,21 @@ The following code example demonstrates sending an email message asynchronously. Specify which certificates should be used to establish the Secure Sockets Layer (SSL) connection. An , holding one or more client certificates. The default value is derived from the mail configuration attributes in a configuration file. - [!NOTE] -> The Framework caches SSL sessions as they are created and attempts to reuse a cached session for a new request, if possible. When attempting to reuse an SSL session, the Framework uses the first element of (if there is one), or tries to reuse an anonymous sessions if is empty. - - - -## Examples - The following code example establishes an SSL connection with the SMTP server and uses the connection to send an email. - - :::code language="csharp" source="~/snippets/csharp/System.Net.Mail/SmtpClient/ClientCertificates/mail.cs" id="Snippet1"::: - +> The Framework caches SSL sessions as they are created and attempts to reuse a cached session for a new request, if possible. When attempting to reuse an SSL session, the Framework uses the first element of (if there is one), or tries to reuse an anonymous sessions if is empty. + + + +## Examples + The following code example establishes an SSL connection with the SMTP server and uses the connection to send an email. + + :::code language="csharp" source="~/snippets/csharp/System.Net.Mail/SmtpClient/ClientCertificates/mail.cs" id="Snippet1"::: + ]]> MailSettings Element (Network Settings) @@ -406,24 +406,24 @@ The following code example demonstrates sending an email message asynchronously. Gets or sets the credentials used to authenticate the sender. An that represents the credentials to use for authentication; or if no credentials have been specified. - to `true` instead of setting this property. If the property is set to `false,` then the value set in the property will be used for the credentials when connecting to the server. If the property is set to `false` and the property has not been set, then mail is sent to the server anonymously. - - Credentials information can also be specified using the application and machine configuration files. For more information, see [<mailSettings> Element (Network Settings)](/dotnet/framework/configure-apps/file-schema/network/mailsettings-element-network-settings). If information is specified using the property, this information overrides the configuration file settings. - + to `true` instead of setting this property. If the property is set to `false,` then the value set in the property will be used for the credentials when connecting to the server. If the property is set to `false` and the property has not been set, then mail is sent to the server anonymously. + + Credentials information can also be specified using the application and machine configuration files. For more information, see [<mailSettings> Element (Network Settings)](/dotnet/framework/configure-apps/file-schema/network/mailsettings-element-network-settings). If information is specified using the property, this information overrides the configuration file settings. + > [!CAUTION] -> If you provide credentials for basic authentication, they are sent to the server in clear text. This can present a security issue because your credentials can be seen, and then used by others. - - - -## Examples - The following code example demonstrates setting the credentials used to send an email. - +> If you provide credentials for basic authentication, they are sent to the server in clear text. This can present a security issue because your credentials can be seen, and then used by others. + + + +## Examples + The following code example demonstrates setting the credentials used to send an email. + :::code language="cpp" source="~/snippets/cpp/VS_Snippets_Remoting/NCLMailSync/CPP/NclMailSync.cpp" id="Snippet1"::: - :::code language="csharp" source="~/snippets/csharp/System.Net.Mail/Attachment/Overview/mail.cs" id="Snippet1"::: - + :::code language="csharp" source="~/snippets/csharp/System.Net.Mail/Attachment/Overview/mail.cs" id="Snippet1"::: + ]]> You cannot change the value of this property when an email is being sent. @@ -514,19 +514,19 @@ The following code example demonstrates sending an email message asynchronously. Specifies how outgoing email messages will be handled. An that indicates how email messages are delivered. - for later delivery by another application. - - The default value for this property can also be set in a machine or application configuration file. Any changes made to the property override the configuration file settings. - + for later delivery by another application. + + The default value for this property can also be set in a machine or application configuration file. Any changes made to the property override the configuration file settings. + ]]> @@ -544,17 +544,17 @@ The following code example demonstrates sending an email message asynchronously. Sends a QUIT message to the SMTP server, gracefully ends the TCP connection, and releases all resources used by the current instance of the class. - class to the SMTP server may be re-used if an application wishes to send multiple messages to the same SMTP server. This is particularly useful when authentication or encryption are used establish a connection to the SMTP server. The process of authenticating and establishing a TLS session can be expensive operations. A requirement to re-establish a connection for each message when sending a large quantity of email to the same SMTP server could have a significant impact on performance. There are a number of high-volume email applications that send email status updates, newsletter distributions, or email alerts. Also many email client applications support an off-line mode where users can compose many email messages that are sent later when a connection to the SMTP server is established. It is typical for an email client to send all SMTP messages to a specific SMTP server (provided by the Internet service provider) that then forwards this email to other SMTP servers. - - The class implementation pools SMTP connections so that it can avoid the overhead of re-establishing a connection for every message to the same server. An application may re-use the same object to send many different emails to the same SMTP server and to many different SMTP servers. As a result, there is no way to determine when an application is finished using the object and it should be cleaned up. - - When an SMTP session is finished and the client wishes to terminate the connection, it must send a QUIT message to the server to indicate that it has no more messages to send. This allows the server to free up resources associated with the connection from the client and process the messages which were sent by the client. - - The methods iterates through all established connections and send a QUIT message to each SMTP server, followed by gracefully ending the TCP connection. These methods also release the unmanaged resources used by the and optionally dispose of the managed resources. - + class to the SMTP server may be re-used if an application wishes to send multiple messages to the same SMTP server. This is particularly useful when authentication or encryption are used establish a connection to the SMTP server. The process of authenticating and establishing a TLS session can be expensive operations. A requirement to re-establish a connection for each message when sending a large quantity of email to the same SMTP server could have a significant impact on performance. There are a number of high-volume email applications that send email status updates, newsletter distributions, or email alerts. Also many email client applications support an off-line mode where users can compose many email messages that are sent later when a connection to the SMTP server is established. It is typical for an email client to send all SMTP messages to a specific SMTP server (provided by the Internet service provider) that then forwards this email to other SMTP servers. + + The class implementation pools SMTP connections so that it can avoid the overhead of re-establishing a connection for every message to the same server. An application may re-use the same object to send many different emails to the same SMTP server and to many different SMTP servers. As a result, there is no way to determine when an application is finished using the object and it should be cleaned up. + + When an SMTP session is finished and the client wishes to terminate the connection, it must send a QUIT message to the server to indicate that it has no more messages to send. This allows the server to free up resources associated with the connection from the client and process the messages which were sent by the client. + + The methods iterates through all established connections and send a QUIT message to each SMTP server, followed by gracefully ending the TCP connection. These methods also release the unmanaged resources used by the and optionally dispose of the managed resources. + ]]> @@ -598,28 +598,28 @@ The following code example demonstrates sending an email message asynchronously. Sends a QUIT message to the SMTP server, gracefully ends the TCP connection, and releases all resources used by the current instance of the class. - class to the SMTP server may be re-used if an application wishes to send multiple messages to the same SMTP server. This is particularly useful when authentication or encryption are used establish a connection to the SMTP server. The process of authenticating and establishing a TLS session can be expensive operations. A requirement to re-establish a connection for each message when sending a large quantity of email to the same SMTP server could have a significant impact on performance. There are a number of high-volume email applications that send email status updates, newsletter distributions, or email alerts. Also many email client applications support an off-line mode where users can compose many email messages that are sent later when a connection to the SMTP server is established. It is typical for an email client to send all SMTP messages to a specific SMTP server (provided by the Internet service provider) that then forwards this email to other SMTP servers. - - The class implementation pools SMTP connections so that it can avoid the overhead of re-establishing a connection for every message to the same server. An application may re-use the same object to send many different emails to the same SMTP server and to many different SMTP servers. As a result, there is no way to determine when an application is finished using the object and it should be cleaned up. - - When an SMTP session is finished and the client wishes to terminate the connection, it must send a QUIT message to the server to indicate that it has no more messages to send. This allows the server to free up resources associated with the connection from the client and process the messages which were sent by the client. - - Calling the method on a object that is executing an asynchronous operation will cancel the send operation as though the method had been called. - - The class has no `Finalize` method. So an application must call to explicitly free up resources. - - The method iterates through all established connections to the SMTP server specified in the property and sends a QUIT message followed by gracefully ending the TCP connection. The method also releases the unmanaged resources used by the underlying . - - Call when you are finished using the . The method leaves the in an unusable state. After calling , you must release all references to the so the garbage collector can reclaim the memory that the was occupying. - - For more information, see [Cleaning Up Unmanaged Resources](/dotnet/standard/garbage-collection/unmanaged) and [Implementing a Dispose Method](/dotnet/standard/garbage-collection/implementing-dispose). - + class to the SMTP server may be re-used if an application wishes to send multiple messages to the same SMTP server. This is particularly useful when authentication or encryption are used establish a connection to the SMTP server. The process of authenticating and establishing a TLS session can be expensive operations. A requirement to re-establish a connection for each message when sending a large quantity of email to the same SMTP server could have a significant impact on performance. There are a number of high-volume email applications that send email status updates, newsletter distributions, or email alerts. Also many email client applications support an off-line mode where users can compose many email messages that are sent later when a connection to the SMTP server is established. It is typical for an email client to send all SMTP messages to a specific SMTP server (provided by the Internet service provider) that then forwards this email to other SMTP servers. + + The class implementation pools SMTP connections so that it can avoid the overhead of re-establishing a connection for every message to the same server. An application may re-use the same object to send many different emails to the same SMTP server and to many different SMTP servers. As a result, there is no way to determine when an application is finished using the object and it should be cleaned up. + + When an SMTP session is finished and the client wishes to terminate the connection, it must send a QUIT message to the server to indicate that it has no more messages to send. This allows the server to free up resources associated with the connection from the client and process the messages which were sent by the client. + + Calling the method on a object that is executing an asynchronous operation will cancel the send operation as though the method had been called. + + The class has no `Finalize` method. So an application must call to explicitly free up resources. + + The method iterates through all established connections to the SMTP server specified in the property and sends a QUIT message followed by gracefully ending the TCP connection. The method also releases the unmanaged resources used by the underlying . + + Call when you are finished using the . The method leaves the in an unusable state. After calling , you must release all references to the so the garbage collector can reclaim the memory that the was occupying. + + For more information, see [Cleaning Up Unmanaged Resources](/dotnet/standard/garbage-collection/unmanaged) and [Implementing a Dispose Method](/dotnet/standard/garbage-collection/implementing-dispose). + > [!NOTE] -> Always call before you release your last reference to the . Otherwise, the resources it is using will not be freed so the garbage collector can reclaim the memory. - +> Always call before you release your last reference to the . Otherwise, the resources it is using will not be freed so the garbage collector can reclaim the memory. + ]]> @@ -664,28 +664,28 @@ The following code example demonstrates sending an email message asynchronously. to release both managed and unmanaged resources; to releases only unmanaged resources. Sends a QUIT message to the SMTP server, gracefully ends the TCP connection, releases all resources used by the current instance of the class, and optionally disposes of the managed resources. - class to the SMTP server may be re-used if an application wishes to send multiple messages to the same SMTP server. This is particularly useful when authentication or encryption are used establish a connection to the SMTP server. The process of authenticating and establishing a TLS session can be expensive operations. A requirement to re-establish a connection for each message when sending a large quantity of email to the same SMTP server could have a significant impact on performance. There are a number of high-volume email applications that send email status updates, newsletter distributions, or email alerts. Also many email client applications support an off-line mode where users can compose many email messages that are sent later when a connection to the SMTP server is established. It is typical for an email client to send all SMTP messages to a specific SMTP server (provided by the Internet service provider) that then forwards this email to other SMTP servers. - - The class implementation pools SMTP connections so that it can avoid the overhead of re-establishing a connection for every message to the same server. An application may re-use the same object to send many different emails to the same SMTP server and to many different SMTP servers. As a result, there is no way to determine when an application is finished using the object and it should be cleaned up. - - When an SMTP session is finished and the client wishes to terminate the connection, it must send a QUIT message to the server to indicate that it has no more messages to send. This allows the server to free up resources associated with the connection from the client and process the messages which were sent by the client. - - Calling the method on a object that is executing an asynchronous operation will cancel the send operation as though the method had been called. - - The class has no `Finalize` method. So an application must call to explicitly free up resources. - - The method iterates through all established connections to the SMTP server specified in the property and sends a QUIT message followed by gracefully ending the TCP connection. The method also releases the unmanaged resources used by the and optionally disposes of the managed resources. - - Call when you are finished using the . The method leaves the in an unusable state. After calling , you must release all references to the so the garbage collector can reclaim the memory that the was occupying. - - For more information, see [Cleaning Up Unmanaged Resources](/dotnet/standard/garbage-collection/unmanaged) and [Implementing a Dispose Method](/dotnet/standard/garbage-collection/implementing-dispose). - + class to the SMTP server may be re-used if an application wishes to send multiple messages to the same SMTP server. This is particularly useful when authentication or encryption are used establish a connection to the SMTP server. The process of authenticating and establishing a TLS session can be expensive operations. A requirement to re-establish a connection for each message when sending a large quantity of email to the same SMTP server could have a significant impact on performance. There are a number of high-volume email applications that send email status updates, newsletter distributions, or email alerts. Also many email client applications support an off-line mode where users can compose many email messages that are sent later when a connection to the SMTP server is established. It is typical for an email client to send all SMTP messages to a specific SMTP server (provided by the Internet service provider) that then forwards this email to other SMTP servers. + + The class implementation pools SMTP connections so that it can avoid the overhead of re-establishing a connection for every message to the same server. An application may re-use the same object to send many different emails to the same SMTP server and to many different SMTP servers. As a result, there is no way to determine when an application is finished using the object and it should be cleaned up. + + When an SMTP session is finished and the client wishes to terminate the connection, it must send a QUIT message to the server to indicate that it has no more messages to send. This allows the server to free up resources associated with the connection from the client and process the messages which were sent by the client. + + Calling the method on a object that is executing an asynchronous operation will cancel the send operation as though the method had been called. + + The class has no `Finalize` method. So an application must call to explicitly free up resources. + + The method iterates through all established connections to the SMTP server specified in the property and sends a QUIT message followed by gracefully ending the TCP connection. The method also releases the unmanaged resources used by the and optionally disposes of the managed resources. + + Call when you are finished using the . The method leaves the in an unusable state. After calling , you must release all references to the so the garbage collector can reclaim the memory that the was occupying. + + For more information, see [Cleaning Up Unmanaged Resources](/dotnet/standard/garbage-collection/unmanaged) and [Implementing a Dispose Method](/dotnet/standard/garbage-collection/implementing-dispose). + > [!NOTE] -> Always call before you release your last reference to the . Otherwise, the resources it is using will not be freed so the garbage collector can reclaim the memory. - +> Always call before you release your last reference to the . Otherwise, the resources it is using will not be freed so the garbage collector can reclaim the memory. + ]]> @@ -728,29 +728,29 @@ The following code example demonstrates sending an email message asynchronously. if the uses SSL; otherwise, . The default is . - property specifies whether SSL is used to access the specified SMTP mail server. - - The default value for this property can also be set in a machine or application configuration file. Any changes made to the property override the configuration file settings. - - The class only supports the SMTP Service Extension for Secure SMTP over Transport Layer Security as defined in RFC 3207. In this mode, the SMTP session begins on an unencrypted channel, then a STARTTLS command is issued by the client to the server to switch to secure communication using SSL. See RFC 3207 published by the Internet Engineering Task Force (IETF) for more information. - - An alternate connection method is where an SSL session is established up front before any protocol commands are sent. This connection method is sometimes called SMTP/SSL, SMTP over SSL, or SMTPS and by default uses port 465. This alternate connection method using SSL is not currently supported. - - You can use to specify which client certificates should be used to establish the SSL connection. The allows you to reject the certificate provided by the SMTP server. The property allows you to specify the version of the SSL protocol to use. - + property specifies whether SSL is used to access the specified SMTP mail server. + + The default value for this property can also be set in a machine or application configuration file. Any changes made to the property override the configuration file settings. + + The class only supports the SMTP Service Extension for Secure SMTP over Transport Layer Security as defined in RFC 3207. In this mode, the SMTP session begins on an unencrypted channel, then a STARTTLS command is issued by the client to the server to switch to secure communication using SSL. See RFC 3207 published by the Internet Engineering Task Force (IETF) for more information. + + An alternate connection method is where an SSL session is established up front before any protocol commands are sent. This connection method is sometimes called SMTP/SSL, SMTP over SSL, or SMTPS and by default uses port 465. This alternate connection method using SSL is not currently supported. + + You can use to specify which client certificates should be used to establish the SSL connection. The allows you to reject the certificate provided by the SMTP server. The property allows you to specify the version of the SSL protocol to use. + > [!NOTE] -> If the property is set to `true`, and the SMTP mail server does not advertise STARTTLS in the response to the EHLO command, then a call to the or methods will throw an . - - - -## Examples - The following code example establishes an SSL connection with the SMTP server and uses the connection to send an email. - - :::code language="csharp" source="~/snippets/csharp/System.Net.Mail/SmtpClient/ClientCertificates/mail.cs" id="Snippet1"::: - +> If the property is set to `true`, and the SMTP mail server does not advertise STARTTLS in the response to the EHLO command, then a call to the or methods will throw an . + + + +## Examples + The following code example establishes an SSL connection with the SMTP server and uses the connection to send an email. + + :::code language="csharp" source="~/snippets/csharp/System.Net.Mail/SmtpClient/ClientCertificates/mail.cs" id="Snippet1"::: + ]]> @@ -805,21 +805,21 @@ The following code example demonstrates sending an email message asynchronously. Gets or sets the name or IP address of the host used for SMTP transactions. A that contains the name or IP address of the computer to use for SMTP transactions. - property can also be set using constructors or the application or machine configuration file. For more information, see [<mailSettings> Element (Network Settings)](/dotnet/framework/configure-apps/file-schema/network/mailsettings-element-network-settings). - - If information is specified using this property, this information overrides the configuration file settings. - - - -## Examples - The following code example demonstrates sending an email message by using the host and port specified in an application configuration file. - + property can also be set using constructors or the application or machine configuration file. For more information, see [<mailSettings> Element (Network Settings)](/dotnet/framework/configure-apps/file-schema/network/mailsettings-element-network-settings). + + If information is specified using this property, this information overrides the configuration file settings. + + + +## Examples + The following code example demonstrates sending an email message by using the host and port specified in an application configuration file. + :::code language="cpp" source="~/snippets/cpp/VS_Snippets_Remoting/NCLMailSync/CPP/NclMailSync.cpp" id="Snippet7"::: - :::code language="csharp" source="~/snippets/csharp/System.Net.Mail/Attachment/Overview/mail.cs" id="Snippet7"::: - + :::code language="csharp" source="~/snippets/csharp/System.Net.Mail/Attachment/Overview/mail.cs" id="Snippet7"::: + ]]> The value specified for a set operation is . @@ -874,13 +874,13 @@ The following code example demonstrates sending an email message asynchronously. An that contains event data. Raises the event. - class can override the method to perform additional tasks when the event occurs. - - also allows derived classes to handle without attaching a delegate. This is the preferred technique for handling in a derived class. - + class can override the method to perform additional tasks when the event occurs. + + also allows derived classes to handle without attaching a delegate. This is the preferred technique for handling in a derived class. + ]]> @@ -936,13 +936,13 @@ The following code example demonstrates sending an email message asynchronously. Gets or sets the folder where applications save mail messages to be processed by the local SMTP server. A that specifies the pickup directory for mail messages. - property override the configuration file settings. - + property override the configuration file settings. + ]]> @@ -994,19 +994,19 @@ The following code example demonstrates sending an email message asynchronously. Gets or sets the port used for SMTP transactions. An that contains the port number on the SMTP host. The default value is 25. - property can also be set using constructors or the application or machine configuration file. For more information about using configuration files, see [<mailSettings> Element (Network Settings)](/dotnet/framework/configure-apps/file-schema/network/mailsettings-element-network-settings). If information is specified using this property, this information overrides the configuration file settings. - - - -## Examples - The following code example demonstrates sending an email message by using the host and port specified in an application configuration file. - + property can also be set using constructors or the application or machine configuration file. For more information about using configuration files, see [<mailSettings> Element (Network Settings)](/dotnet/framework/configure-apps/file-schema/network/mailsettings-element-network-settings). If information is specified using this property, this information overrides the configuration file settings. + + + +## Examples + The following code example demonstrates sending an email message by using the host and port specified in an application configuration file. + :::code language="cpp" source="~/snippets/cpp/VS_Snippets_Remoting/NCLMailSync/CPP/NclMailSync.cpp" id="Snippet7"::: - :::code language="csharp" source="~/snippets/csharp/System.Net.Mail/Attachment/Overview/mail.cs" id="Snippet7"::: - + :::code language="csharp" source="~/snippets/csharp/System.Net.Mail/Attachment/Overview/mail.cs" id="Snippet7"::: + ]]> The value specified for a set operation is less than or equal to zero. @@ -1070,74 +1070,72 @@ The following code example demonstrates sending an email message asynchronously. A that contains the message to send. Sends the specified message to an SMTP server for delivery. - property to ensure that the method returns after a specified amount of time elapses. - - Before calling this method, the and properties must be set either through the configuration files by setting the relevant properties, or by passing this information into the constructor. - - You cannot call this method if there is a message being sent asynchronously. - - If the SMTP host requires credentials, you must set them before calling this method. To specify credentials, use the or properties. - - If you receive an exception, check the property to find the reason the operation failed. The can also contain an inner exception that indicates the reason the operation failed. - + property to ensure that the method returns after a specified amount of time elapses. + + Before calling this method, the and properties must be set either through the configuration files by setting the relevant properties, or by passing this information into the constructor. + + You cannot call this method if there is a message being sent asynchronously. + + If the SMTP host requires credentials, you must set them before calling this method. To specify credentials, use the or properties. + + If you receive an exception, check the property to find the reason the operation failed. The can also contain an inner exception that indicates the reason the operation failed. + When sending email using to multiple recipients and the SMTP server accepts some recipients as valid and rejects others, sends email to the accepted recipients and then a is thrown (or a if only one recipient is rejected). A contains a list of the recipients that were rejected. - + > [!NOTE] -> If the property is set to `true`, and the SMTP mail server does not advertise STARTTLS in the response to the EHLO command, then a call to the or methods will throw an . - - - -## Examples - The following code example demonstrates using this method. - +> If the property is set to `true`, and the SMTP mail server does not advertise STARTTLS in the response to the EHLO command, then a call to the or methods will throw an . + +## Examples + The following code example demonstrates using this method. + :::code language="cpp" source="~/snippets/cpp/VS_Snippets_Remoting/NCLMailSync/CPP/NclMailSync.cpp" id="Snippet2"::: - :::code language="csharp" source="~/snippets/csharp/System.Net.Mail/Attachment/Overview/mail.cs" id="Snippet2"::: - + :::code language="csharp" source="~/snippets/csharp/System.Net.Mail/Attachment/Overview/mail.cs" id="Snippet2"::: + ]]> is . - This has another send operation already in progress. - - -or- - - is . - - -or- - - There are no recipients specified in , , and properties. - - -or- - - property is set to and is . - - -or- - - property is set to and is equal to the empty string (""). - - -or- - + This has another send operation already in progress. + + -or- + + is . + + -or- + + There are no recipients specified in , , and properties. + + -or- + + property is set to and is . + + -or- + + property is set to and is equal to the empty string (""). + + -or- + property is set to and is zero, a negative number, or greater than 65,535. This object has been disposed. - The connection to the SMTP server failed. - - -or- - - Authentication failed. - - -or- - - The operation timed out. - - -or- - - is set to but the property is set to or . - - -or- - + The connection to the SMTP server failed. + + -or- + + Authentication failed. + + -or- + + The operation timed out. + + -or- + + is set to but the property is set to or . + + -or- + is set to but the SMTP mail server did not advertise STARTTLS in the response to the EHLO command. The could not be delivered to one of the recipients in , , or . The could not be delivered to two or more of the recipients in , , or . @@ -1204,71 +1202,71 @@ The following code example demonstrates sending an email message asynchronously. A that contains the message body. Sends the specified email message to an SMTP server for delivery. The message sender, recipients, subject, and message body are specified using objects. - property to ensure that the method returns after a specified amount of time elapses. - - Before calling this method, the and properties must be set either through the configuration files by setting the relevant properties, or by passing this information into the constructor. - - You cannot call this method if there is a message being sent asynchronously. - - If the SMTP host requires credentials, you must set them before calling this method. To specify credentials, use the or properties. - - If you receive an exception, check the property to find the reason the operation failed. The can also contain an inner exception that indicates the reason the operation failed. + property to ensure that the method returns after a specified amount of time elapses. + + Before calling this method, the and properties must be set either through the configuration files by setting the relevant properties, or by passing this information into the constructor. + + You cannot call this method if there is a message being sent asynchronously. + + If the SMTP host requires credentials, you must set them before calling this method. To specify credentials, use the or properties. + + If you receive an exception, check the property to find the reason the operation failed. The can also contain an inner exception that indicates the reason the operation failed. When sending email using to multiple recipients and the SMTP server accepts some recipients as valid and rejects others, sends email to the accepted recipients and then a is thrown (or a if only one recipient is rejected). A contains a list of the recipients that were rejected. - + > [!NOTE] -> If the property is set to `true`, and the SMTP mail server does not advertise STARTTLS in the response to the EHLO command, then a call to the or methods will throw an . - +> If the property is set to `true`, and the SMTP mail server does not advertise STARTTLS in the response to the EHLO command, then a call to the or methods will throw an . + ]]> - is . - - -or- - + is . + + -or- + is . - is . - - -or- - + is . + + -or- + is . - This has another send operation already in progress. - - -or- - - property is set to and is . - - -or- - - property is set to and is equal to the empty string (""). - - -or- - + This has another send operation already in progress. + + -or- + + property is set to and is . + + -or- + + property is set to and is equal to the empty string (""). + + -or- + property is set to and is zero, a negative number, or greater than 65,535. This object has been disposed. - The connection to the SMTP server failed. - - -or- - - Authentication failed. - - -or- - - The operation timed out. - - -or- - - is set to but the property is set to or . - - -or- - + The connection to the SMTP server failed. + + -or- + + Authentication failed. + + -or- + + The operation timed out. + + -or- + + is set to but the property is set to or . + + -or- + is set to but the SMTP mail server did not advertise STARTTLS in the response to the EHLO command. - The could not be delivered to one of the recipients in , , or . - The could not be delivered to two or more of the recipients in , , or . + The message could not be delivered to one of the recipients in , , or . + The message could not be delivered to two or more of the recipients in , , or . @@ -1331,85 +1329,83 @@ The following code example demonstrates sending an email message asynchronously. A user-defined object that is passed to the method invoked when the asynchronous operation completes. Sends the specified email message to an SMTP server for delivery. This method does not block the calling thread and allows the caller to pass an object to the method that is invoked when the operation completes. - event. You can cancel a operation by calling the method. - - After calling , you must wait for the email transmission to complete before attempting to send another email message using or . - - Before calling this method, the and must be set through the configuration files by setting the relevant properties, or by passing this information into the constructor. - - If the SMTP host requires credentials, you must set them before calling this method. To specify credentials, use the or properties. - - If you receive an exception, check the property to find the reason the operation failed. The can also contain an inner exception that indicates the reason the operation failed. - - When sending email using to multiple recipients, if the SMTP server accepts some recipients as valid and rejects others, a is thrown with a for the inner exception. If this occurs, fails to send email to any of the recipients. - - Your application can detect a server certificate validation error by examining the property passed into the delegate. - - The property does not have any effect on a call. - - To send mail and block while it is transmitted to the SMTP server, use one of the methods. - + event. You can cancel a operation by calling the method. + + After calling , you must wait for the email transmission to complete before attempting to send another email message using or . + + Before calling this method, the and must be set through the configuration files by setting the relevant properties, or by passing this information into the constructor. + + If the SMTP host requires credentials, you must set them before calling this method. To specify credentials, use the or properties. + + If you receive an exception, check the property to find the reason the operation failed. The can also contain an inner exception that indicates the reason the operation failed. + + When sending email using to multiple recipients, if the SMTP server accepts some recipients as valid and rejects others, a is thrown with a for the inner exception. If this occurs, fails to send email to any of the recipients. + + Your application can detect a server certificate validation error by examining the property passed into the delegate. + + The property does not have any effect on a call. + + To send mail and block while it is transmitted to the SMTP server, use one of the methods. + > [!NOTE] -> If the property is set to `true`, and the SMTP mail server does not advertise STARTTLS in the response to the EHLO command, then a call to the or methods will throw an . - - - -## Examples - The following code example demonstrates calling this method. - +> If the property is set to `true`, and the SMTP mail server does not advertise STARTTLS in the response to the EHLO command, then a call to the or methods will throw an . + +## Examples + The following code example demonstrates calling this method. + :::code language="cpp" source="~/snippets/cpp/VS_Snippets_Remoting/NclMailASync/cpp/mailasync.cpp" id="Snippet1"::: :::code language="csharp" source="~/snippets/csharp/System.Net.Mail/MailAddress/.ctor/mailasync.cs" id="Snippet1"::: - :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_Remoting/NclMailASync/vb/mailasync.vb" id="Snippet1"::: - + :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_Remoting/NclMailASync/vb/mailasync.vb" id="Snippet1"::: + ]]> - is . - - -or- - + is . + + -or- + is . - This has another send operation already in progress. - - -or- - - There are no recipients specified in , , and properties. - - -or- - - property is set to and is . - - -or- - - property is set to and is equal to the empty string (""). - - -or- - + This has another send operation already in progress. + + -or- + + There are no recipients specified in , , and properties. + + -or- + + property is set to and is . + + -or- + + property is set to and is equal to the empty string (""). + + -or- + property is set to and is zero, a negative number, or greater than 65,535. This object has been disposed. - The connection to the SMTP server failed. - - -or- - - Authentication failed. - - -or- - - The operation timed out. - - -or- - - is set to but the property is set to or . - - -or- - - is set to but the SMTP mail server did not advertise STARTTLS in the response to the EHLO command. - - -or- - + The connection to the SMTP server failed. + + -or- + + Authentication failed. + + -or- + + The operation timed out. + + -or- + + is set to but the property is set to or . + + -or- + + is set to but the SMTP mail server did not advertise STARTTLS in the response to the EHLO command. + + -or- + The could not be delivered to one or more of the recipients in , , or . The could not be delivered to one of the recipients in , , or . The could not be delivered to two or more of the recipients in , , or . @@ -1478,81 +1474,81 @@ The following code example demonstrates sending an email message asynchronously. A user-defined object that is passed to the method invoked when the asynchronous operation completes. Sends an email message to an SMTP server for delivery. The message sender, recipients, subject, and message body are specified using objects. This method does not block the calling thread and allows the caller to pass an object to the method that is invoked when the operation completes. - event. You can cancel a operation by calling the method. - - After calling , you must wait for the email transmission to complete before attempting to send another email message using or . - - Before calling this method, the and properties must be set either through the configuration files or by setting the properties or passing this information into the constructor. - - If the SMTP host requires credentials, you must set them before calling this method. To specify credentials, use the or property. - - If you receive an exception, check the property to find the reason the operation failed. The can also contain an inner exception that indicates the reason the operation failed. - - When sending email using to multiple recipients, if the SMTP server accepts some recipients as valid and rejects others, a is thrown with a for the inner exception. If this occurs, fails to send email to any of the recipients. - - Your application can detect a server certificate validation error by examining the property passed into the delegate. - - The property does not have any effect on a call. - - To send mail and block while it is transmitted to the SMTP server, use one of the methods. - + event. You can cancel a operation by calling the method. + + After calling , you must wait for the email transmission to complete before attempting to send another email message using or . + + Before calling this method, the and properties must be set either through the configuration files or by setting the properties or passing this information into the constructor. + + If the SMTP host requires credentials, you must set them before calling this method. To specify credentials, use the or property. + + If you receive an exception, check the property to find the reason the operation failed. The can also contain an inner exception that indicates the reason the operation failed. + + When sending email using to multiple recipients, if the SMTP server accepts some recipients as valid and rejects others, a is thrown with a for the inner exception. If this occurs, fails to send email to any of the recipients. + + Your application can detect a server certificate validation error by examining the property passed into the delegate. + + The property does not have any effect on a call. + + To send mail and block while it is transmitted to the SMTP server, use one of the methods. + > [!NOTE] -> If the property is set to `true`, and the SMTP mail server does not advertise STARTTLS in the response to the EHLO command, then a call to the or methods will throw an . - +> If the property is set to `true`, and the SMTP mail server does not advertise STARTTLS in the response to the EHLO command, then a call to the or methods will throw an . + ]]> - is . - - -or- - - is . + is . + + -or- + + is . - is . - - -or- - - is . - This has a call in progress. - - -or- - - property is set to and is . - - -or- - - property is set to and is equal to the empty string (""). - - -or- - + is . + + -or- + + is . + This has a call in progress. + + -or- + + property is set to and is . + + -or- + + property is set to and is equal to the empty string (""). + + -or- + property is set to and is zero, a negative number, or greater than 65,535. This object has been disposed. - The connection to the SMTP server failed. - - -or- - - Authentication failed. - - -or- - - The operation timed out. - - -or- - - is set to but the property is set to or . - - -or- - - is set to but the SMTP mail server did not advertise STARTTLS in the response to the EHLO command. - - -or- - + The connection to the SMTP server failed. + + -or- + + Authentication failed. + + -or- + + The operation timed out. + + -or- + + is set to but the property is set to or . + + -or- + + is set to but the SMTP mail server did not advertise STARTTLS in the response to the EHLO command. + + -or- + The message could not be delivered to one or more of the recipients in . - The could not be delivered to one of the recipients in , , or . - The could not be delivered to two or more of the recipients in , , or . + The message could not be delivered to one of the recipients in , , or . + The message could not be delivered to two or more of the recipients in , , or . @@ -1592,20 +1588,20 @@ The following code example demonstrates sending an email message asynchronously. Cancels an asynchronous operation to send an email message. - method to cancel a pending operation. If there is mail waiting to be sent, this method releases resources used to store the mail. If there is no mail waiting to be sent, this method does nothing. - - - -## Examples - The following code example demonstrates sending an email message asynchronously. The user has the option to cancel the mail if it has not been sent. - + method to cancel a pending operation. If there is mail waiting to be sent, this method releases resources used to store the mail. If there is no mail waiting to be sent, this method does nothing. + + + +## Examples + The following code example demonstrates sending an email message asynchronously. The user has the option to cancel the mail if it has not been sent. + :::code language="cpp" source="~/snippets/cpp/VS_Snippets_Remoting/NclMailASync/cpp/mailasync.cpp" id="Snippet1"::: :::code language="csharp" source="~/snippets/csharp/System.Net.Mail/MailAddress/.ctor/mailasync.cs" id="Snippet1"::: - :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_Remoting/NclMailASync/vb/mailasync.vb" id="Snippet1"::: - + :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_Remoting/NclMailASync/vb/mailasync.vb" id="Snippet1"::: + ]]> This object has been disposed. @@ -1649,22 +1645,22 @@ The following code example demonstrates sending an email message asynchronously. Occurs when an asynchronous email send operation completes. - event is raised each time an email message is sent asynchronously when the send operation completes. To send an email message asynchronously, use the methods. - - is the delegate for . The class provides the event handler with event data. - - - -## Examples - The following code example demonstrates sending an email message asynchronously. - + event is raised each time an email message is sent asynchronously when the send operation completes. To send an email message asynchronously, use the methods. + + is the delegate for . The class provides the event handler with event data. + + + +## Examples + The following code example demonstrates sending an email message asynchronously. + :::code language="cpp" source="~/snippets/cpp/VS_Snippets_Remoting/NclMailASync/cpp/mailasync.cpp" id="Snippet1"::: :::code language="csharp" source="~/snippets/csharp/System.Net.Mail/MailAddress/.ctor/mailasync.cs" id="Snippet1"::: - :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_Remoting/NclMailASync/vb/mailasync.vb" id="Snippet1"::: - + :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_Remoting/NclMailASync/vb/mailasync.vb" id="Snippet1"::: + ]]> @@ -1719,53 +1715,53 @@ The following code example demonstrates sending an email message asynchronously. Sends the specified message to an SMTP server for delivery as an asynchronous operation. The task object representing the asynchronous operation. - object will complete once the message has been sent. ]]> is . - This has another send operation already in progress. - - -or- - - There are no recipients specified in , , and properties. - - -or- - - property is set to and is . - - -or- - - property is set to and is equal to the empty string (""). - - -or- - + This has another send operation already in progress. + + -or- + + There are no recipients specified in , , and properties. + + -or- + + property is set to and is . + + -or- + + property is set to and is equal to the empty string (""). + + -or- + property is set to and is zero, a negative number, or greater than 65,535. This object has been disposed. - The connection to the SMTP server failed. - - -or- - - Authentication failed. - - -or- - - The operation timed out. - - -or- - - is set to but the property is set to or . - - -or- - - is set to but the SMTP mail server did not advertise STARTTLS in the response to the EHLO command. - - -or- - + The connection to the SMTP server failed. + + -or- + + Authentication failed. + + -or- + + The operation timed out. + + -or- + + is set to but the property is set to or . + + -or- + + is set to but the SMTP mail server did not advertise STARTTLS in the response to the EHLO command. + + -or- + The could not be delivered to one or more of the recipients in , , or . The could not be delivered to one of the recipients in , , or . The could not be delivered to two or more of the recipients in , , or . @@ -1803,57 +1799,57 @@ The following code example demonstrates sending an email message asynchronously. Sends the specified message to an SMTP server for delivery as an asynchronous operation. The task object representing the asynchronous operation. - object will complete once the message has been sent. - + object will complete once the message has been sent. + ]]> is . - This has another send operation already in progress. - - -or- - - is . - - -or- - - There are no recipients specified in , , and properties. - - -or- - - property is set to and is . - - -or- - - property is set to and is equal to the empty string (""). - - -or- - + This has another send operation already in progress. + + -or- + + is . + + -or- + + There are no recipients specified in , , and properties. + + -or- + + property is set to and is . + + -or- + + property is set to and is equal to the empty string (""). + + -or- + property is set to and is zero, a negative number, or greater than 65,535. This object has been disposed. - The connection to the SMTP server failed. - - -or- - - Authentication failed. - - -or- - - The operation timed out. - - -or- - - is set to but the property is set to or . - - -or- - - is set to but the SMTP mail server did not advertise STARTTLS in the response to the EHLO command. - - -or- - + The connection to the SMTP server failed. + + -or- + + Authentication failed. + + -or- + + The operation timed out. + + -or- + + is set to but the property is set to or . + + -or- + + is set to but the SMTP mail server did not advertise STARTTLS in the response to the EHLO command. + + -or- + The could not be delivered to one or more of the recipients in , , or . The could not be delivered to one of the recipients in , , or . The could not be delivered to two or more of the recipients in , , or . @@ -1921,66 +1917,66 @@ The following code example demonstrates sending an email message asynchronously. Sends the specified message to an SMTP server for delivery as an asynchronous operation. The message sender, recipients, subject, and message body are specified using objects. The task object representing the asynchronous operation. - object will complete once the message has been sent. - + object will complete once the message has been sent. + ]]> - is . - - -or- - + is . + + -or- + is . - is . - - -or- - + is . + + -or- + is . - This has another send operation already in progress. - - -or- - - is . - - -or- - - property is set to and is . - - -or- - - property is set to and is equal to the empty string (""). - - -or- - + This has another send operation already in progress. + + -or- + + is . + + -or- + + property is set to and is . + + -or- + + property is set to and is equal to the empty string (""). + + -or- + property is set to and is zero, a negative number, or greater than 65,535. This object has been disposed. - The connection to the SMTP server failed. - - -or- - - Authentication failed. - - -or- - - The operation timed out. - - -or- - - is set to but the property is set to or . - - -or- - - is set to but the SMTP mail server did not advertise STARTTLS in the response to the EHLO command. - - -or- - - The could not be delivered to one or more of the recipients in , , or . - The could not be delivered to one of the recipients in , , or . - The could not be delivered to two or more of the recipients in , , or . + The connection to the SMTP server failed. + + -or- + + Authentication failed. + + -or- + + The operation timed out. + + -or- + + is set to but the property is set to or . + + -or- + + is set to but the SMTP mail server did not advertise STARTTLS in the response to the EHLO command. + + -or- + + The message could not be delivered to one or more of the recipients in , , or . + The message could not be delivered to one of the recipients in , , or . + The message could not be delivered to two or more of the recipients in , , or . @@ -2035,62 +2031,62 @@ The following code example demonstrates sending an email message asynchronously. Sends the specified message to an SMTP server for delivery as an asynchronous operation, using the specified sender, recipients, subject, and body strings. The task object representing the asynchronous operation. - object will complete once the message has been sent. - + object will complete once the message has been sent. + ]]> - is . - - -or- - + is . + + -or- + is . - is . - - -or- - + is . + + -or- + is . - This has another send operation already in progress. - - -or- - - property is set to and is . - - -or- - - property is set to and is equal to the empty string (""). - - -or- - + This has another send operation already in progress. + + -or- + + property is set to and is . + + -or- + + property is set to and is equal to the empty string (""). + + -or- + property is set to and is zero, a negative number, or greater than 65,535. This object has been disposed. - The connection to the SMTP server failed. - - -or- - - Authentication failed. - - -or- - - The operation timed out. - - -or- - - is set to but the property is set to or . - - -or- - - is set to but the SMTP mail server did not advertise STARTTLS in the response to the EHLO command. - - -or- - - The could not be delivered to one or more of the recipients in , , or . - The could not be delivered to one of the recipients in , , or . - The could not be delivered to two or more of the recipients in , , or . + The connection to the SMTP server failed. + + -or- + + Authentication failed. + + -or- + + The operation timed out. + + -or- + + is set to but the property is set to or . + + -or- + + is set to but the SMTP mail server did not advertise STARTTLS in the response to the EHLO command. + + -or- + + The message could not be delivered to one or more of the recipients in , , or . + The message could not be delivered to one of the recipients in , , or . + The message could not be delivered to two or more of the recipients in , , or . The cancellation token was canceled. This exception is stored into the returned task. @@ -2137,18 +2133,18 @@ The following code example demonstrates sending an email message asynchronously. Gets the network connection used to transmit the email message. A that connects to the property used for SMTP. - property are created using defaults specified in the application or machine configuration files and the class. - + property are created using defaults specified in the application or machine configuration files and the class. + ]]> - is or the empty string (""). - - -or- - + is or the empty string (""). + + -or- + is zero. connectionManagement Element (Network Settings) Managing Connections @@ -2202,13 +2198,13 @@ The following code example demonstrates sending an email message asynchronously. Gets or sets the Service Provider Name (SPN) to use for authentication when using extended protection. A that specifies the SPN to use for extended protection. The default value for this SPN is of the form "SMTPSVC/<host>" where <host> is the hostname of the SMTP mail server. - property is used with integrated Windows authentication when an application is using extended protection. The can then provide extended protection to ensure that credential challenge responses contain service specific information (a SPN) and, if necessary, channel specific information (a channel binding token or CBT). With this information in the credential exchanges, services are able to better protect against malicious use of credential challenge responses that might have been improperly obtained. - - The default value for this property can also be set in a machine or application configuration file. Any changes made to the property override the configuration file settings. - + property is used with integrated Windows authentication when an application is using extended protection. The can then provide extended protection to ensure that credential challenge responses contain service specific information (a SPN) and, if necessary, channel specific information (a channel binding token or CBT). With this information in the credential exchanges, services are able to better protect against malicious use of credential challenge responses that might have been improperly obtained. + + The default value for this property can also be set in a machine or application configuration file. Any changes made to the property override the configuration file settings. + ]]> @@ -2257,21 +2253,21 @@ The following code example demonstrates sending an email message asynchronously. Gets or sets a value that specifies the amount of time after which a synchronous call times out. An that specifies the time-out value in milliseconds. The default value is 100,000 (100 seconds). - method block until the operation completes. If you set the property to a positive value, and a operation cannot complete in the allotted time, the class throws an exception. - - To send a message and continue executing in the application thread, use the method. - - - -## Examples - The following code example demonstrates getting and setting the time-out value. - + method block until the operation completes. If you set the property to a positive value, and a operation cannot complete in the allotted time, the class throws an exception. + + To send a message and continue executing in the application thread, use the method. + + + +## Examples + The following code example demonstrates getting and setting the time-out value. + :::code language="cpp" source="~/snippets/cpp/VS_Snippets_Remoting/NCLMailSync/CPP/NclMailSync.cpp" id="Snippet3"::: - :::code language="csharp" source="~/snippets/csharp/System.Net.Mail/Attachment/Overview/mail.cs" id="Snippet3"::: - + :::code language="csharp" source="~/snippets/csharp/System.Net.Mail/Attachment/Overview/mail.cs" id="Snippet3"::: + ]]> The value specified for a set operation was less than zero. @@ -2316,26 +2312,26 @@ The following code example demonstrates sending an email message asynchronously. if the default credentials are used; otherwise . The default value is . - object should, if requested by the server, authenticate using the default credentials of the currently logged on user. For client applications, this is the desired behavior in most scenarios. - - Credentials information can also be specified using the application and machine configuration files. For more information, see [<mailSettings> Element (Network Settings)](/dotnet/framework/configure-apps/file-schema/network/mailsettings-element-network-settings). - - If the property is set to `false,` then the value set in the property will be used for the credentials when connecting to the server. If the property is set to `false` and the property has not been set, then mail is sent to the server anonymously. - + object should, if requested by the server, authenticate using the default credentials of the currently logged on user. For client applications, this is the desired behavior in most scenarios. + + Credentials information can also be specified using the application and machine configuration files. For more information, see [<mailSettings> Element (Network Settings)](/dotnet/framework/configure-apps/file-schema/network/mailsettings-element-network-settings). + + If the property is set to `false,` then the value set in the property will be used for the credentials when connecting to the server. If the property is set to `false` and the property has not been set, then mail is sent to the server anonymously. + > [!CAUTION] -> If you provide credentials for basic authentication, they are sent to the server in clear text. This can present a security issue because your credentials can be seen, and then used by others. - - - -## Examples - The following code example demonstrates using this property. - +> If you provide credentials for basic authentication, they are sent to the server in clear text. This can present a security issue because your credentials can be seen, and then used by others. + + + +## Examples + The following code example demonstrates using this property. + :::code language="cpp" source="~/snippets/cpp/VS_Snippets_Remoting/NCLMailSync/CPP/NclMailSync.cpp" id="Snippet2"::: - :::code language="csharp" source="~/snippets/csharp/System.Net.Mail/Attachment/Overview/mail.cs" id="Snippet2"::: - + :::code language="csharp" source="~/snippets/csharp/System.Net.Mail/Attachment/Overview/mail.cs" id="Snippet2"::: + ]]> You cannot change the value of this property when an email is being sent. diff --git a/xml/System.Net.NetworkInformation/GatewayIPAddressInformationCollection.xml b/xml/System.Net.NetworkInformation/GatewayIPAddressInformationCollection.xml index af1509d53be..2ea469837fc 100644 --- a/xml/System.Net.NetworkInformation/GatewayIPAddressInformationCollection.xml +++ b/xml/System.Net.NetworkInformation/GatewayIPAddressInformationCollection.xml @@ -282,23 +282,23 @@ The zero-based index in at which the copy begins. Copies the elements in this collection to a one-dimensional array of type . - is . - is less than zero. + is less than zero. - is multidimensional. - - -or- - - The number of elements in this is greater than the available space from to the end of the destination . + is multidimensional. + + -or- + + The number of elements in this is greater than the available space from to the end of the destination . The elements in this cannot be cast automatically to the type of the destination . @@ -387,15 +387,15 @@ Returns an object that can be used to iterate through this collection. An object that implements the interface and provides access to the types in this collection. - method before you can access the first element. To access the element at the current position, call the property. - - Do not modify the collection while using the enumerator. If the collection is modified while an enumerator is in use, an attempt to set the position by calling or causes an . - - For a detailed description of enumerators, see the documentation for the class and the method. - + method before you can access the first element. To access the element at the current position, call the property. + + Do not modify the collection while using the enumerator. If the collection is modified while an enumerator is in use, an attempt to set the position by calling or causes an . + + For a detailed description of enumerators, see the documentation for the class and the method. + ]]> @@ -583,15 +583,15 @@ Returns an object that can be used to iterate through this collection. An object that implements the interface and provides access to the types in this collection. - method before you can access the first element. To access the element at the current position, call the property. - - Do not modify the collection while using the enumerator. If the collection is modified while an enumerator is in use, an attempt to set the position by calling or causes an . - - For a detailed description of enumerators, see the documentation for the class and the method. - + method before you can access the first element. To access the element at the current position, call the property. + + Do not modify the collection while using the enumerator. If the collection is modified while an enumerator is in use, an attempt to set the position by calling or causes an . + + For a detailed description of enumerators, see the documentation for the class and the method. + ]]> diff --git a/xml/System.Net.NetworkInformation/MulticastIPAddressInformationCollection.xml b/xml/System.Net.NetworkInformation/MulticastIPAddressInformationCollection.xml index 04a1c2a3c96..27d01870d69 100644 --- a/xml/System.Net.NetworkInformation/MulticastIPAddressInformationCollection.xml +++ b/xml/System.Net.NetworkInformation/MulticastIPAddressInformationCollection.xml @@ -282,23 +282,23 @@ The zero-based index in at which the copy begins. Copies the elements in this collection to a one-dimensional array of type . - is . - is less than zero. + is less than zero. - is multidimensional. - - -or- - - The number of elements in this is greater than the available space from to the end of the destination . + is multidimensional. + + -or- + + The number of elements in this is greater than the available space from to the end of the destination . The elements in this cannot be cast automatically to the type of the destination . @@ -387,15 +387,15 @@ Returns an object that can be used to iterate through this collection. An object that implements the interface and provides access to the types in this collection. - method before you can access the first element. To access the element at the current position, call the property. - - Do not modify the collection while using the enumerator. If the collection is modified while an enumerator is in use, an attempt to set the position by calling or causes an . - - For a detailed description of enumerators, see the documentation for the class and the method. - + method before you can access the first element. To access the element at the current position, call the property. + + Do not modify the collection while using the enumerator. If the collection is modified while an enumerator is in use, an attempt to set the position by calling or causes an . + + For a detailed description of enumerators, see the documentation for the class and the method. + ]]> @@ -583,15 +583,15 @@ Returns an object that can be used to iterate through this collection. An object that implements the interface and provides access to the types in this collection. - method before you can access the first element. To access the element at the current position, call the property. - - Do not modify the collection while using the enumerator. If the collection is modified while an enumerator is in use, an attempt to set the position by calling or causes an . - - For a detailed description of enumerators, see the documentation for the class and the method. - + method before you can access the first element. To access the element at the current position, call the property. + + Do not modify the collection while using the enumerator. If the collection is modified while an enumerator is in use, an attempt to set the position by calling or causes an . + + For a detailed description of enumerators, see the documentation for the class and the method. + ]]> diff --git a/xml/System.Net.NetworkInformation/PhysicalAddress.xml b/xml/System.Net.NetworkInformation/PhysicalAddress.xml index 3c42e16c718..bae32f05325 100644 --- a/xml/System.Net.NetworkInformation/PhysicalAddress.xml +++ b/xml/System.Net.NetworkInformation/PhysicalAddress.xml @@ -48,21 +48,21 @@ Provides the Media Access Control (MAC) address for a network interface (adapter). - method. - - - -## Examples - The following code example displays the physical addresses of all interfaces on the local computer. - + method. + + + +## Examples + The following code example displays the physical addresses of all interfaces on the local computer. + :::code language="cpp" source="~/snippets/cpp/VS_Snippets_Remoting/NCLPhysicalAddress/CPP/NCLPhysicalAddress.cpp" id="Snippet2"::: - :::code language="csharp" source="~/snippets/csharp/System.Net.NetworkInformation/PhysicalAddress/Overview/physaddresstester.cs" id="Snippet2"::: - + :::code language="csharp" source="~/snippets/csharp/System.Net.NetworkInformation/PhysicalAddress/Overview/physaddresstester.cs" id="Snippet2"::: + ]]> @@ -105,21 +105,21 @@ A array containing the address. Initializes a new instance of the class. - method. - - Note that you can also use the method to create a new instance of . - - - -## Examples - The following code example creates a new object. - + method. + + Note that you can also use the method to create a new instance of . + + + +## Examples + The following code example creates a new object. + :::code language="cpp" source="~/snippets/cpp/VS_Snippets_Remoting/NCLPhysicalAddress/CPP/NCLPhysicalAddress.cpp" id="Snippet4"::: - :::code language="csharp" source="~/snippets/csharp/System.Net.NetworkInformation/PhysicalAddress/Overview/physaddresstester.cs" id="Snippet4"::: - + :::code language="csharp" source="~/snippets/csharp/System.Net.NetworkInformation/PhysicalAddress/Overview/physaddresstester.cs" id="Snippet4"::: + ]]> @@ -175,14 +175,14 @@ if this instance and the specified instance contain the same address; otherwise . - instances. - + instances. + :::code language="cpp" source="~/snippets/cpp/VS_Snippets_Remoting/NCLPhysicalAddress/CPP/NCLPhysicalAddress.cpp" id="Snippet3"::: - :::code language="csharp" source="~/snippets/csharp/System.Net.NetworkInformation/PhysicalAddress/Overview/physaddresstester.cs" id="Snippet3"::: - + :::code language="csharp" source="~/snippets/csharp/System.Net.NetworkInformation/PhysicalAddress/Overview/physaddresstester.cs" id="Snippet3"::: + ]]> @@ -226,14 +226,14 @@ Returns the address of the current instance. A array containing the address. - and formats the address for display. - + and formats the address for display. + :::code language="cpp" source="~/snippets/cpp/VS_Snippets_Remoting/NCLPhysicalAddress/CPP/NCLPhysicalAddress.cpp" id="Snippet2"::: - :::code language="csharp" source="~/snippets/csharp/System.Net.NetworkInformation/PhysicalAddress/Overview/physaddresstester.cs" id="Snippet2"::: - + :::code language="csharp" source="~/snippets/csharp/System.Net.NetworkInformation/PhysicalAddress/Overview/physaddresstester.cs" id="Snippet2"::: + ]]> @@ -316,19 +316,19 @@ Returns a new instance with a zero length address. This field is read-only. - method returns if you specify `null` address. - - - -## Examples - The following code example demonstrates using this field to test the result of parsing an address. - + method returns if you specify `null` address. + + + +## Examples + The following code example demonstrates using this field to test the result of parsing an address. + :::code language="cpp" source="~/snippets/cpp/VS_Snippets_Remoting/NCLPhysicalAddress/CPP/NCLPhysicalAddress.cpp" id="Snippet5"::: - :::code language="csharp" source="~/snippets/csharp/System.Net.NetworkInformation/PhysicalAddress/Overview/physaddresstester.cs" id="Snippet5"::: - + :::code language="csharp" source="~/snippets/csharp/System.Net.NetworkInformation/PhysicalAddress/Overview/physaddresstester.cs" id="Snippet5"::: + ]]> @@ -363,32 +363,32 @@ Parses the specified span and stores its contents as the address bytes of the returned by this method. A instance with the specified address. - method to retrieve the address from an existing instance. - - - -## Examples - The following code example creates a instance by calling the method. - - :::code language="csharp" source="~/snippets/csharp/System.Net.NetworkInformation/PhysicalAddress/Overview/physaddresstester.cs" id="Snippet6"::: - + Use the method to retrieve the address from an existing instance. + + + +## Examples + The following code example creates a instance by calling the method. + + :::code language="csharp" source="~/snippets/csharp/System.Net.NetworkInformation/PhysicalAddress/Overview/physaddresstester.cs" id="Snippet6"::: + ]]> @@ -445,36 +445,36 @@ Parses the specified and stores its contents as the address bytes of the returned by this method. A instance with the specified address. - method to retrieve the address from an existing instance. - - - -## Examples - The following code example creates a instance by calling the method. - + +In .NET Framework and .NET Core 3.1 and earlier, an address that contains `f0-e1-d2-c3-b4-a5` will fail to parse and throw an exception. + + Use the method to retrieve the address from an existing instance. + + + +## Examples + The following code example creates a instance by calling the method. + :::code language="cpp" source="~/snippets/cpp/VS_Snippets_Remoting/NCLPhysicalAddress/CPP/NCLPhysicalAddress.cpp" id="Snippet5"::: - :::code language="csharp" source="~/snippets/csharp/System.Net.NetworkInformation/PhysicalAddress/Overview/physaddresstester.cs" id="Snippet5"::: - + :::code language="csharp" source="~/snippets/csharp/System.Net.NetworkInformation/PhysicalAddress/Overview/physaddresstester.cs" id="Snippet5"::: + ]]> @@ -520,14 +520,14 @@ In .NET Framework and .NET Core 3.1 and earlier, an address that contains `f0-e1 Returns the representation of the address of this instance. A containing the address contained in this instance. - instance. - + instance. + :::code language="cpp" source="~/snippets/cpp/VS_Snippets_Remoting/NCLPhysicalAddress/CPP/NCLPhysicalAddress.cpp" id="Snippet3"::: - :::code language="csharp" source="~/snippets/csharp/System.Net.NetworkInformation/PhysicalAddress/Overview/physaddresstester.cs" id="Snippet3"::: - + :::code language="csharp" source="~/snippets/csharp/System.Net.NetworkInformation/PhysicalAddress/Overview/physaddresstester.cs" id="Snippet3"::: + ]]> @@ -571,30 +571,30 @@ In .NET Framework and .NET Core 3.1 and earlier, an address that contains `f0-e1 A span containing the address that will be used to initialize the instance returned by this method. - When this method returns, contains the instance equivalent of the address contained in , if the conversion succeeded, or if the conversion failed. This parameter is passed uninitialized; any value originally supplied in will be overwritten. + When this method returns, contains the instance equivalent of the address contained in , if the conversion succeeded, or if the conversion failed. This parameter is passed uninitialized; any value originally supplied in will be overwritten. Tries to convert the span representation of a hardware address to a instance. A return value indicates whether the conversion succeeded. if was converted successfully; otherwise, . - method to retrieve the address from an existing instance. - + + Use the method to retrieve the address from an existing instance. + ]]> @@ -634,30 +634,30 @@ In .NET Framework and .NET Core 3.1 and earlier, an address that contains `f0-e1 A string containing the address that will be used to initialize the instance returned by this method. - When this method returns, contains the instance equivalent of the address contained in , if the conversion succeeded, or if the conversion failed. If the is it contains . This parameter is passed uninitialized; any value originally supplied in will be overwritten. + When this method returns, contains the instance equivalent of the address contained in , if the conversion succeeded, or if the conversion failed. If the is it contains . This parameter is passed uninitialized; any value originally supplied in will be overwritten. Tries to convert the string representation of a hardware address to a instance. A return value indicates whether the conversion succeeded. if was converted successfully; otherwise, . - method to retrieve the address from an existing instance. - + + Use the method to retrieve the address from an existing instance. + ]]> diff --git a/xml/System.Net.NetworkInformation/Ping.xml b/xml/System.Net.NetworkInformation/Ping.xml index 1af399fefcf..874d86c996f 100644 --- a/xml/System.Net.NetworkInformation/Ping.xml +++ b/xml/System.Net.NetworkInformation/Ping.xml @@ -63,58 +63,58 @@ Allows an application to determine whether a remote computer is accessible over the network. - class to detect whether a remote computer is reachable. - - Network topology can determine whether can successfully contact a remote host. The presence and configuration of proxies, network address translation (NAT) equipment, or firewalls can prevent from succeeding. A successful indicates only that the remote host can be reached on the network; the presence of higher level services (such as a Web server) on the remote host is not guaranteed. - - This class provides functionality similar to the Ping.exe command line tool. The and methods send an Internet Control Message Protocol (ICMP) echo request message to a remote computer and wait for an ICMP echo reply message from that computer. For a detailed description of ICMP messages, see RFC 792, available at [https://www.ietf.org](https://www.ietf.org/). - - The following types are used with the class and are described in detail below. - -|**Type name**|**Description**| -|-------------------|---------------------| -||Defines status codes that describe the outcome of an ICMP echo request message.| -||Allows you to configure or retrieve the settings that control how many times the request packet can be forwarded (), and whether it can be fragmented ( ).| -||Contains the results of an ICMP echo request.| -||Thrown if an unrecoverable error occurs.| -||Contains the data associated with events, which are raised when a call completes or is canceled.| -||The delegate that provides the callback method invoked when a call completes or is canceled.| - - The and methods return the reply in a object. The property returns an value to indicate the outcome of the request. - - When sending the request, you must specify the remote computer. You can do this by providing a host name string, an IP address in string format, or an object. - - You can also specify any of the following types of information: - -- Data to accompany the request. Specifying `buffer` allows you to learn the amount of time required for a packet of a particular size to travel to and from the remote host and the maximum transmission unit of the network path. (See the or overloads that take a `buffer` parameter.) - -- Whether the ICMP Echo packet can be fragmented in transit. (See the property and the or overloads that take an `options` parameter.) - -- How many times routing nodes, such as routers or gateways, can forward the packet before it either reaches the destination computer or is discarded. (See and the or overloads that take an `options` parameter.) - -- The time limit within which the reply must be received. (See the or overloads that take a `timeout` parameter. - - The class offers both synchronous and asynchronous methods for sending the request. If your application should block while waiting for a reply, use the methods; these methods are synchronous. If your application should not block, use the asynchronous methods. A call to executes in its own thread that is automatically allocated from the thread pool. When the asynchronous operation completes, it raises the event. Applications use a delegate to specify the method that is called for events. You must add a delegate to the event before calling . The delegate's method receives a object that contains a object that describes the result of the call. - - You cannot use the same instance of the class to generate multiple simultaneous ICMP Echo requests. Calling while a call is in progress or calling multiple times before all previous calls have completed causes an . - - - -## Examples - The following code example demonstrates using the class synchronously. - + class to detect whether a remote computer is reachable. + + Network topology can determine whether can successfully contact a remote host. The presence and configuration of proxies, network address translation (NAT) equipment, or firewalls can prevent from succeeding. A successful indicates only that the remote host can be reached on the network; the presence of higher level services (such as a Web server) on the remote host is not guaranteed. + + This class provides functionality similar to the Ping.exe command line tool. The and methods send an Internet Control Message Protocol (ICMP) echo request message to a remote computer and wait for an ICMP echo reply message from that computer. For a detailed description of ICMP messages, see RFC 792, available at [https://www.ietf.org](https://www.ietf.org/). + + The following types are used with the class and are described in detail below. + +|**Type name**|**Description**| +|-------------------|---------------------| +||Defines status codes that describe the outcome of an ICMP echo request message.| +||Allows you to configure or retrieve the settings that control how many times the request packet can be forwarded (), and whether it can be fragmented ( ).| +||Contains the results of an ICMP echo request.| +||Thrown if an unrecoverable error occurs.| +||Contains the data associated with events, which are raised when a call completes or is canceled.| +||The delegate that provides the callback method invoked when a call completes or is canceled.| + + The and methods return the reply in a object. The property returns an value to indicate the outcome of the request. + + When sending the request, you must specify the remote computer. You can do this by providing a host name string, an IP address in string format, or an object. + + You can also specify any of the following types of information: + +- Data to accompany the request. Specifying `buffer` allows you to learn the amount of time required for a packet of a particular size to travel to and from the remote host and the maximum transmission unit of the network path. (See the or overloads that take a `buffer` parameter.) + +- Whether the ICMP Echo packet can be fragmented in transit. (See the property and the or overloads that take an `options` parameter.) + +- How many times routing nodes, such as routers or gateways, can forward the packet before it either reaches the destination computer or is discarded. (See and the or overloads that take an `options` parameter.) + +- The time limit within which the reply must be received. (See the or overloads that take a `timeout` parameter. + + The class offers both synchronous and asynchronous methods for sending the request. If your application should block while waiting for a reply, use the methods; these methods are synchronous. If your application should not block, use the asynchronous methods. A call to executes in its own thread that is automatically allocated from the thread pool. When the asynchronous operation completes, it raises the event. Applications use a delegate to specify the method that is called for events. You must add a delegate to the event before calling . The delegate's method receives a object that contains a object that describes the result of the call. + + You cannot use the same instance of the class to generate multiple simultaneous ICMP Echo requests. Calling while a call is in progress or calling multiple times before all previous calls have completed causes an . + + + +## Examples + The following code example demonstrates using the class synchronously. + :::code language="cpp" source="~/snippets/cpp/VS_Snippets_Remoting/NclPingSync/CPP/syncping.cpp" id="Snippet1"::: - :::code language="csharp" source="~/snippets/csharp/System.Net.NetworkInformation/IPStatus/Overview/syncping.cs" id="Snippet1"::: - :::code language="fsharp" source="~/snippets/fsharp/System.Net.NetworkInformation/IPStatus/Overview/syncping.fs" id="Snippet1"::: - - The following code example demonstrates using the class asynchronously. - + :::code language="csharp" source="~/snippets/csharp/System.Net.NetworkInformation/IPStatus/Overview/syncping.cs" id="Snippet1"::: + :::code language="fsharp" source="~/snippets/fsharp/System.Net.NetworkInformation/IPStatus/Overview/syncping.fs" id="Snippet1"::: + + The following code example demonstrates using the class asynchronously. + :::code language="cpp" source="~/snippets/cpp/VS_Snippets_Remoting/NclPingAsync/CPP/asyncping.cpp" id="Snippet1"::: - :::code language="csharp" source="~/snippets/csharp/System.Net.NetworkInformation/Ping/Overview/asyncping.cs" id="Snippet1"::: - + :::code language="csharp" source="~/snippets/csharp/System.Net.NetworkInformation/Ping/Overview/asyncping.cs" id="Snippet1"::: + ]]> How to: Ping a Host @@ -157,14 +157,14 @@ Initializes a new instance of the class. - instance. The complete example is available in the class overview. - + instance. The complete example is available in the class overview. + :::code language="cpp" source="~/snippets/cpp/VS_Snippets_Remoting/NclPingAsync/CPP/asyncping.cpp" id="Snippet2"::: - :::code language="csharp" source="~/snippets/csharp/System.Net.NetworkInformation/Ping/Overview/asyncping.cs" id="Snippet2"::: - + :::code language="csharp" source="~/snippets/csharp/System.Net.NetworkInformation/Ping/Overview/asyncping.cs" id="Snippet2"::: + ]]> @@ -244,13 +244,13 @@ to release both managed and unmanaged resources; to releases only unmanaged resources. Releases the unmanaged resources used by the object, and optionally disposes of the managed resources. - method. The public `Dispose()` method invokes the protected method with the `disposing` parameter set to `true`. invokes `Dispose` with `disposing` set to `false`. - - When the `disposing` parameter is `true`, this method releases all resources held by any managed objects that this object references. This method invokes the `Dispose()` method of each referenced object. - + method. The public `Dispose()` method invokes the protected method with the `disposing` parameter set to `true`. invokes `Dispose` with `disposing` set to `false`. + + When the `disposing` parameter is `true`, this method releases all resources held by any managed objects that this object references. This method invokes the `Dispose()` method of each referenced object. + ]]> @@ -295,15 +295,15 @@ A object that contains event data. Raises the event. - class can override this method to perform additional tasks, such as logging the data contained in the `e` parameter. - - Raising an event invokes the event handler through a delegate. For more information, see [Handling and Raising Events](/dotnet/standard/events/). - - The method also allows derived classes to handle the event without attaching a delegate. This is the preferred technique for handling the event in a derived class. - + class can override this method to perform additional tasks, such as logging the data contained in the `e` parameter. + + Raising an event invokes the event handler through a delegate. For more information, see [Handling and Raising Events](/dotnet/standard/events/). + + The method also allows derived classes to handle the event without attaching a delegate. This is the preferred technique for handling the event in a derived class. + ]]> @@ -355,19 +355,19 @@ Occurs when an asynchronous operation to send an Internet Control Message Protocol (ICMP) echo message and receive the corresponding ICMP echo reply message completes or is canceled. - event to get information about the completion status and data collected by a call to one of the methods. The delegate provides the call back method invoked when raises this event. - - - -## Examples - The following code example demonstrates specifying a callback method for the event. The complete example is available in the class overview. - + event to get information about the completion status and data collected by a call to one of the methods. The delegate provides the call back method invoked when raises this event. + + + +## Examples + The following code example demonstrates specifying a callback method for the event. The complete example is available in the class overview. + :::code language="cpp" source="~/snippets/cpp/VS_Snippets_Remoting/NclPingAsync/CPP/asyncping.cpp" id="Snippet2"::: - :::code language="csharp" source="~/snippets/csharp/System.Net.NetworkInformation/Ping/Overview/asyncping.cs" id="Snippet2"::: - + :::code language="csharp" source="~/snippets/csharp/System.Net.NetworkInformation/Ping/Overview/asyncping.cs" id="Snippet2"::: + ]]> @@ -381,11 +381,11 @@ Attempts to send an Internet Control Message Protocol (ICMP) echo message to a remote computer and receive a corresponding ICMP echo reply message from the remote computer. - overloads can originate from a malicious remote computer. Do not connect to the remote computer using this. Use DNS to determine the IP address of the machine to which you want to connect. - + overloads can originate from a malicious remote computer. Do not connect to the remote computer using this. Use DNS to determine the IP address of the machine to which you want to connect. + ]]> @@ -431,21 +431,21 @@ Attempts to send an Internet Control Message Protocol (ICMP) echo message to the computer that has the specified , and receive a corresponding ICMP echo reply message from that computer. A object that provides information about the ICMP echo reply message, if one was received, or describes the reason for the failure if no message was received. - data buffer with the ICMP echo message. The method waits five seconds for an ICMP echo reply message. If it does not receive a reply in that time, the method returns and the property is set to . - - This overload uses default settings for packet fragmentation and packet forwarding. The packet that contains the ICMP echo message can be fragmented in transit if the total packet size exceeds the maximum packet size that can be transmitted by one of the routing nodes between the local and remote computers. To prevent fragmentation, use one of the methods that takes an `options` parameter, and set the property to `true`. When is `true` and the total packet size exceeds the maximum packet size that can be transmitted by one of the routing nodes between the local and remote computers, the ICMP echo request fails. When this happens, the is set to . The packet or packet fragments (if fragmented) can be forwarded by routing nodes 128 times before being discarded. To change this setting, use a overload that takes an `options` parameter, and set the property to the desired value. If the packet does not reach its destination after being forwarded the specified number of times, the packet is discarded and the ICMP echo request fails. When this happens, the is set to . - - - -## Examples - The following code example demonstrates calling this method. - + data buffer with the ICMP echo message. The method waits five seconds for an ICMP echo reply message. If it does not receive a reply in that time, the method returns and the property is set to . + + This overload uses default settings for packet fragmentation and packet forwarding. The packet that contains the ICMP echo message can be fragmented in transit if the total packet size exceeds the maximum packet size that can be transmitted by one of the routing nodes between the local and remote computers. To prevent fragmentation, use one of the methods that takes an `options` parameter, and set the property to `true`. When is `true` and the total packet size exceeds the maximum packet size that can be transmitted by one of the routing nodes between the local and remote computers, the ICMP echo request fails. When this happens, the is set to . The packet or packet fragments (if fragmented) can be forwarded by routing nodes 128 times before being discarded. To change this setting, use a overload that takes an `options` parameter, and set the property to the desired value. If the packet does not reach its destination after being forwarded the specified number of times, the packet is discarded and the ICMP echo request fails. When this happens, the is set to . + + + +## Examples + The following code example demonstrates calling this method. + :::code language="cpp" source="~/snippets/cpp/VS_Snippets_Remoting/NCLPingSampler/CPP/pingtest.cpp" id="Snippet3"::: - :::code language="csharp" source="~/snippets/csharp/System.Net.NetworkInformation/Ping/Send/pingtest.cs" id="Snippet3"::: - + :::code language="csharp" source="~/snippets/csharp/System.Net.NetworkInformation/Ping/Send/pingtest.cs" id="Snippet3"::: + ]]> @@ -496,21 +496,21 @@ Attempts to send an Internet Control Message Protocol (ICMP) echo message to the specified computer, and receive a corresponding ICMP echo reply message from that computer. A object that provides information about the ICMP echo reply message, if one was received, or provides the reason for the failure, if no message was received. - data buffer with the ICMP echo message. The method waits five seconds for an ICMP echo reply message. If it does not receive a reply in that time, the method returns and the property is set to . - - This overload uses default settings for packet fragmentation and packet forwarding. The packet that contains the ICMP echo message can be fragmented in transit if the total packet size exceeds the maximum packet size that can be transmitted by one of the routing nodes between the local and remote computers. To prevent fragmentation, use one of the methods that takes an `options` parameter, and set the property to `true`. When is `true` and the total packet size exceeds the maximum packet size that can be transmitted by one of the routing nodes between the local and remote computers, the ICMP echo request fails. When this happens, the is set to . The packet or packet fragments (if fragmented) can be forwarded by routing nodes 128 times before being discarded. To change this setting, use a overload that takes an `options` parameter, and set the property to the desired value. If the packet does not reach its destination after being forwarded the specified number of times, the packet is discarded and the ICMP echo request fails. When this happens, the is set to . - - - -## Examples - The following code example demonstrates calling this method. - + data buffer with the ICMP echo message. The method waits five seconds for an ICMP echo reply message. If it does not receive a reply in that time, the method returns and the property is set to . + + This overload uses default settings for packet fragmentation and packet forwarding. The packet that contains the ICMP echo message can be fragmented in transit if the total packet size exceeds the maximum packet size that can be transmitted by one of the routing nodes between the local and remote computers. To prevent fragmentation, use one of the methods that takes an `options` parameter, and set the property to `true`. When is `true` and the total packet size exceeds the maximum packet size that can be transmitted by one of the routing nodes between the local and remote computers, the ICMP echo request fails. When this happens, the is set to . The packet or packet fragments (if fragmented) can be forwarded by routing nodes 128 times before being discarded. To change this setting, use a overload that takes an `options` parameter, and set the property to the desired value. If the packet does not reach its destination after being forwarded the specified number of times, the packet is discarded and the ICMP echo request fails. When this happens, the is set to . + + + +## Examples + The following code example demonstrates calling this method. + :::code language="cpp" source="~/snippets/cpp/VS_Snippets_Remoting/NCLPingSampler/CPP/pingtest.cpp" id="Snippet2"::: - :::code language="csharp" source="~/snippets/csharp/System.Net.NetworkInformation/Ping/Send/pingtest.cs" id="Snippet2"::: - + :::code language="csharp" source="~/snippets/csharp/System.Net.NetworkInformation/Ping/Send/pingtest.cs" id="Snippet2"::: + ]]> @@ -563,23 +563,23 @@ Attempts to send an Internet Control Message Protocol (ICMP) echo message with the specified data buffer to the computer that has the specified , and receive a corresponding ICMP echo reply message from that computer. This method allows you to specify a time-out value for the operation. A object that provides information about the ICMP echo reply message if one was received, or provides the reason for the failure if no message was received. - property is set to . - + property is set to . + > [!NOTE] -> When specifying very small numbers for `timeout`, the Ping reply can be received even if `timeout` milliseconds have elapsed. - - This overload uses default settings for packet fragmentation and packet forwarding. The packet that contains the ICMP echo message can be fragmented in transit if the total packet size exceeds the maximum packet size that can be transmitted by one of the routing nodes between the local and remote computers. To prevent fragmentation, use one of the methods that takes an `options` parameter, and set the property to `true`. When is `true` and the total packet size exceeds the maximum packet size that can be transmitted by one of the routing nodes between the local and remote computers, the ICMP echo request fails. When this happens, the is set to . - - The packet or packet fragments can be forwarded by routing nodes 128 times before being discarded. To change this setting, use a overload that takes an `options` parameter, and set the property to the desired value. If the packet does not reach its destination after being forwarded the specified number of times, the packet is discarded and the ICMP echo request fails. When this happens, the is set to . - - - -## Examples - For an example that demonstrates calling a method, see the class overview. - +> When specifying very small numbers for `timeout`, the Ping reply can be received even if `timeout` milliseconds have elapsed. + + This overload uses default settings for packet fragmentation and packet forwarding. The packet that contains the ICMP echo message can be fragmented in transit if the total packet size exceeds the maximum packet size that can be transmitted by one of the routing nodes between the local and remote computers. To prevent fragmentation, use one of the methods that takes an `options` parameter, and set the property to `true`. When is `true` and the total packet size exceeds the maximum packet size that can be transmitted by one of the routing nodes between the local and remote computers, the ICMP echo request fails. When this happens, the is set to . + + The packet or packet fragments can be forwarded by routing nodes 128 times before being discarded. To change this setting, use a overload that takes an `options` parameter, and set the property to the desired value. If the packet does not reach its destination after being forwarded the specified number of times, the packet is discarded and the ICMP echo request fails. When this happens, the is set to . + + + +## Examples + For an example that demonstrates calling a method, see the class overview. + ]]> @@ -634,21 +634,21 @@ Attempts to send an Internet Control Message Protocol (ICMP) echo message to the specified computer, and receive a corresponding ICMP echo reply message from that computer. This method allows you to specify a time-out value for the operation. A object that provides information about the ICMP echo reply message if one was received, or provides the reason for the failure if no message was received. - property is set to . - + property is set to . + > [!NOTE] -> When specifying very small numbers for `timeout`, the Ping reply can be received even if `timeout` milliseconds have elapsed. - - This overload uses default settings for packet fragmentation and packet forwarding. The packet that contains the ICMP echo message can be fragmented in transit if the total packet size exceeds the maximum packet size that can be transmitted by one of the routing nodes between the local and remote computers. To prevent fragmentation, use one of the methods that takes an `options` parameter, and set the property to `true`. When is `true` and the total packet size exceeds the maximum packet size that can be transmitted by one of the routing nodes between the local and remote computers, the ICMP echo request fails. When this happens, the is set to . The packet or packet fragments (if fragmented) can be forwarded by routing nodes 128 times before being discarded. To change this setting, use a overload that takes an `options` parameter, and set the property to the desired value. If the packet does not reach its destination after being forwarded the specified number of times, the packet is discarded and the ICMP echo request fails. When this happens, the is set to . - - - -## Examples - For an example that demonstrates calling a method, see the class overview. - +> When specifying very small numbers for `timeout`, the Ping reply can be received even if `timeout` milliseconds have elapsed. + + This overload uses default settings for packet fragmentation and packet forwarding. The packet that contains the ICMP echo message can be fragmented in transit if the total packet size exceeds the maximum packet size that can be transmitted by one of the routing nodes between the local and remote computers. To prevent fragmentation, use one of the methods that takes an `options` parameter, and set the property to `true`. When is `true` and the total packet size exceeds the maximum packet size that can be transmitted by one of the routing nodes between the local and remote computers, the ICMP echo request fails. When this happens, the is set to . The packet or packet fragments (if fragmented) can be forwarded by routing nodes 128 times before being discarded. To change this setting, use a overload that takes an `options` parameter, and set the property to the desired value. If the packet does not reach its destination after being forwarded the specified number of times, the packet is discarded and the ICMP echo request fails. When this happens, the is set to . + + + +## Examples + For an example that demonstrates calling a method, see the class overview. + ]]> @@ -711,26 +711,26 @@ Attempts to send an Internet Control Message Protocol (ICMP) echo message with the specified data buffer to the computer that has the specified , and receive a corresponding ICMP echo reply message from that computer. This overload allows you to specify a time-out value for the operation. A object that provides information about the ICMP echo reply message, if one was received, or provides the reason for the failure, if no message was received. The method will return if the packet exceeds the Maximum Transmission Unit (MTU). - property is set to . - + property is set to . + > [!NOTE] -> When specifying very small numbers for `timeout`, the Ping reply can be received even if `timeout` milliseconds have elapsed. - - This overload uses default settings for packet fragmentation and packet forwarding. The packet that contains the ICMP echo message can be fragmented in transit if the total packet size exceeds the maximum packet size that can be transmitted by one of the routing nodes between the local and remote computers. To prevent fragmentation, use one of the methods that takes an `options` parameter, and set the property to `true`. When is `true` and the total packet size exceeds the maximum packet size that can be transmitted by one of the routing nodes between the local and remote computers, the ICMP echo request fails. When this happens, the is set to . - - The packet or packet fragments can be forwarded by routing nodes 128 times before being discarded. To change this setting, use a overload that takes an `options` parameter, and set the property to the desired value. If the packet does not reach its destination after being forwarded the specified number of times, the packet is discarded and the ICMP echo request fails. When this happens, the is set to . - - - -## Examples - The following code example demonstrates how to call this method. - +> When specifying very small numbers for `timeout`, the Ping reply can be received even if `timeout` milliseconds have elapsed. + + This overload uses default settings for packet fragmentation and packet forwarding. The packet that contains the ICMP echo message can be fragmented in transit if the total packet size exceeds the maximum packet size that can be transmitted by one of the routing nodes between the local and remote computers. To prevent fragmentation, use one of the methods that takes an `options` parameter, and set the property to `true`. When is `true` and the total packet size exceeds the maximum packet size that can be transmitted by one of the routing nodes between the local and remote computers, the ICMP echo request fails. When this happens, the is set to . + + The packet or packet fragments can be forwarded by routing nodes 128 times before being discarded. To change this setting, use a overload that takes an `options` parameter, and set the property to the desired value. If the packet does not reach its destination after being forwarded the specified number of times, the packet is discarded and the ICMP echo request fails. When this happens, the is set to . + + + +## Examples + The following code example demonstrates how to call this method. + :::code language="cpp" source="~/snippets/cpp/VS_Snippets_Remoting/NCLPingSampler/CPP/pingtest.cpp" id="Snippet6"::: - :::code language="csharp" source="~/snippets/csharp/System.Net.NetworkInformation/Ping/Send/pingtest.cs" id="Snippet6"::: - + :::code language="csharp" source="~/snippets/csharp/System.Net.NetworkInformation/Ping/Send/pingtest.cs" id="Snippet6"::: + ]]> The size of exceeds 65500 bytes. @@ -795,31 +795,31 @@ Attempts to send an Internet Control Message Protocol (ICMP) echo message with the specified data buffer to the specified computer, and receive a corresponding ICMP echo reply message from that computer. This overload allows you to specify a time-out value for the operation. A object that provides information about the ICMP echo reply message if one was received, or provides the reason for the failure if no message was received. - property is set to . - + property is set to . + > [!NOTE] -> When specifying very small numbers for `timeout`, the Ping reply can be received even if `timeout` milliseconds have elapsed. - - This overload uses default settings for packet fragmentation and packet forwarding. The packet that contains the ICMP echo message can be fragmented in transit if the total packet size exceeds the maximum packet size that can be transmitted by one of the routing nodes between the local and remote computers. To prevent fragmentation, use one of the methods that takes an `options` parameter, and set the property to `true`. When is `true` and the total packet size exceeds the maximum packet size that can be transmitted by one of the routing nodes between the local and remote computers, the ICMP echo request fails. When this happens, the is set to . - - The packet or packet fragments can be forwarded by routing nodes 128 times before being discarded. To change this setting, use a overload that takes an `options` parameter, and set the property to the desired value. If the packet does not reach its destination after being forwarded the specified number of times, the packet is discarded and the ICMP echo request fails. When this happens, the is set to . - - - -## Examples - For an example that demonstrates how to call a overload, see the class overview. - +> When specifying very small numbers for `timeout`, the Ping reply can be received even if `timeout` milliseconds have elapsed. + + This overload uses default settings for packet fragmentation and packet forwarding. The packet that contains the ICMP echo message can be fragmented in transit if the total packet size exceeds the maximum packet size that can be transmitted by one of the routing nodes between the local and remote computers. To prevent fragmentation, use one of the methods that takes an `options` parameter, and set the property to `true`. When is `true` and the total packet size exceeds the maximum packet size that can be transmitted by one of the routing nodes between the local and remote computers, the ICMP echo request fails. When this happens, the is set to . + + The packet or packet fragments can be forwarded by routing nodes 128 times before being discarded. To change this setting, use a overload that takes an `options` parameter, and set the property to the desired value. If the packet does not reach its destination after being forwarded the specified number of times, the packet is discarded and the ICMP echo request fails. When this happens, the is set to . + + + +## Examples + For an example that demonstrates how to call a overload, see the class overview. + ]]> The size of exceeds 65500 bytes. - is or is an empty string (""). - - -or- - + is or is an empty string (""). + + -or- + is . is less than zero. @@ -884,26 +884,26 @@ Attempts to send an Internet Control Message Protocol (ICMP) echo message with the specified data buffer to the computer that has the specified and receive a corresponding ICMP echo reply message from that computer. This overload allows you to specify a time-out value for the operation and control fragmentation and Time-to-Live values for the ICMP echo message packet. A object that provides information about the ICMP echo reply message, if one was received, or provides the reason for the failure, if no message was received. The method will return if the packet exceeds the Maximum Transmission Unit (MTU). - property is set to . - + property is set to . + > [!NOTE] -> When specifying very small numbers for `timeout`, the Ping reply can be received even if `timeout` milliseconds have elapsed. - - If the property is `true` and the total packet size exceeds the maximum packet size that can be transmitted by one of the routing nodes between the local and remote computers, the ICMP echo request fails. When this happens, the is set to . - - Use the property to specify the maximum number of times the ICMP echo message can be forwarded before reaching its destination. If the packet does not reach its destination after being forwarded the specified number of times, the packet is discarded and the ICMP echo request fails. When this happens, the is set to . - - - -## Examples - The following code example demonstrates how to call this method. - +> When specifying very small numbers for `timeout`, the Ping reply can be received even if `timeout` milliseconds have elapsed. + + If the property is `true` and the total packet size exceeds the maximum packet size that can be transmitted by one of the routing nodes between the local and remote computers, the ICMP echo request fails. When this happens, the is set to . + + Use the property to specify the maximum number of times the ICMP echo message can be forwarded before reaching its destination. If the packet does not reach its destination after being forwarded the specified number of times, the packet is discarded and the ICMP echo request fails. When this happens, the is set to . + + + +## Examples + The following code example demonstrates how to call this method. + :::code language="cpp" source="~/snippets/cpp/VS_Snippets_Remoting/NCLPingSampler/CPP/pingtest.cpp" id="Snippet5"::: - :::code language="csharp" source="~/snippets/csharp/System.Net.NetworkInformation/Ping/Send/pingtest.cs" id="Snippet5"::: - + :::code language="csharp" source="~/snippets/csharp/System.Net.NetworkInformation/Ping/Send/pingtest.cs" id="Snippet5"::: + ]]> The size of exceeds 65500 bytes. @@ -1031,34 +1031,34 @@ Attempts to send an Internet Control Message Protocol (ICMP) echo message with the specified data buffer to the specified computer, and receive a corresponding ICMP echo reply message from that computer. This overload allows you to specify a time-out value for the operation and control fragmentation and Time-to-Live values for the ICMP packet. A object that provides information about the ICMP echo reply message if one was received, or provides the reason for the failure if no message was received. - property is set to . - + property is set to . + > [!NOTE] -> When specifying very small numbers for `timeout`, the Ping reply can be received even if `timeout` milliseconds have elapsed. - - If the property is `true` and the total packet size exceeds the maximum packet size that can be transmitted by one of the routing nodes between the local and remote computers, the ICMP echo request fails. When this happens, the is set to . - - Use the property to specify the maximum number of times the ICMP echo message can be forwarded before reaching its destination. If the packet does not reach its destination after being forwarded the specified number of times, the packet is discarded and the ICMP echo request fails. When this happens, the is set to . - - - -## Examples - The following code example demonstrates how to call this method. - +> When specifying very small numbers for `timeout`, the Ping reply can be received even if `timeout` milliseconds have elapsed. + + If the property is `true` and the total packet size exceeds the maximum packet size that can be transmitted by one of the routing nodes between the local and remote computers, the ICMP echo request fails. When this happens, the is set to . + + Use the property to specify the maximum number of times the ICMP echo message can be forwarded before reaching its destination. If the packet does not reach its destination after being forwarded the specified number of times, the packet is discarded and the ICMP echo request fails. When this happens, the is set to . + + + +## Examples + The following code example demonstrates how to call this method. + :::code language="cpp" source="~/snippets/cpp/VS_Snippets_Remoting/NCLPingSampler/CPP/pingtest.cpp" id="Snippet4"::: - :::code language="csharp" source="~/snippets/csharp/System.Net.NetworkInformation/Ping/Send/pingtest.cs" id="Snippet4"::: - + :::code language="csharp" source="~/snippets/csharp/System.Net.NetworkInformation/Ping/Send/pingtest.cs" id="Snippet4"::: + ]]> The size of exceeds 65500 bytes. - is or is a zero-length string. - - -or- - + is or is a zero-length string. + + -or- + is . is less than zero. @@ -1137,14 +1137,14 @@ Asynchronously attempts to send an Internet Control Message Protocol (ICMP) echo message to a computer, and receive a corresponding ICMP echo reply message from that computer. - methods. - + methods. + > [!NOTE] -> The IP address returned by any of the methods can originate from a malicious remote computer. Do not connect to the remote computer using this. Use DNS to determine the IP address of the machine to which you want to connect. - +> The IP address returned by any of the methods can originate from a malicious remote computer. Do not connect to the remote computer using this. Use DNS to determine the IP address of the machine to which you want to connect. + ]]> @@ -1199,25 +1199,25 @@ An object that is passed to the method invoked when the asynchronous operation completes. Asynchronously attempts to send an Internet Control Message Protocol (ICMP) echo message to the computer that has the specified , and receive a corresponding ICMP echo reply message from that computer. - method sends the echo message asynchronously and, when the operation completes (successfully or unsuccessfully), returns the status to your application. Call the method when your application should not block. Each call to this method executes in a separate thread that is automatically allocated from the thread pool. When the asynchronous operation completes, it raises the event. To specify the method that is called when raises the event, you must add a delegate to the event before calling . The delegate's method receives a object that contains a object that describes the result of the call. The object inherits the property. This property contains the `userToken` object passed into the call. - + method sends the echo message asynchronously and, when the operation completes (successfully or unsuccessfully), returns the status to your application. Call the method when your application should not block. Each call to this method executes in a separate thread that is automatically allocated from the thread pool. When the asynchronous operation completes, it raises the event. To specify the method that is called when raises the event, you must add a delegate to the event before calling . The delegate's method receives a object that contains a object that describes the result of the call. The object inherits the property. This property contains the `userToken` object passed into the call. + > [!NOTE] -> If your application should block while waiting for a reply, use one of the methods; these methods are synchronous. - - This method sends a 32 data buffer with the ICMP echo message. The method waits five seconds for an ICMP echo reply message. If it does not receive a reply in that time, the method returns and the property is set to . - - This overload uses default settings for packet fragmentation and packet forwarding. The packet that contains the ICMP echo message can be fragmented in transit if the total packet size exceeds the maximum packet size that can be transmitted by one of the routing nodes between the local and remote computers. To prevent fragmentation, use one of the methods that takes an `options` parameter, and set the property to `true`. When is `true` and the total packet size exceeds the maximum packet size that can be transmitted by one of the routing nodes between the local and remote computers, the ICMP echo request fails. When this happens, the is set to . - - The packet or packet fragments can be forwarded by routing nodes 128 times before being discarded. To change this setting, use a overload that takes an `options` parameter, and set the property to the desired value. If the packet does not reach its destination after being forwarded the specified number of times, the packet is discarded and the ICMP echo request fails. When this happens, the is set to . - - - -## Examples - For a code example that demonstrates calling a method, see the class overview. - +> If your application should block while waiting for a reply, use one of the methods; these methods are synchronous. + + This method sends a 32 data buffer with the ICMP echo message. The method waits five seconds for an ICMP echo reply message. If it does not receive a reply in that time, the method returns and the property is set to . + + This overload uses default settings for packet fragmentation and packet forwarding. The packet that contains the ICMP echo message can be fragmented in transit if the total packet size exceeds the maximum packet size that can be transmitted by one of the routing nodes between the local and remote computers. To prevent fragmentation, use one of the methods that takes an `options` parameter, and set the property to `true`. When is `true` and the total packet size exceeds the maximum packet size that can be transmitted by one of the routing nodes between the local and remote computers, the ICMP echo request fails. When this happens, the is set to . + + The packet or packet fragments can be forwarded by routing nodes 128 times before being discarded. To change this setting, use a overload that takes an `options` parameter, and set the property to the desired value. If the packet does not reach its destination after being forwarded the specified number of times, the packet is discarded and the ICMP echo request fails. When this happens, the is set to . + + + +## Examples + For a code example that demonstrates calling a method, see the class overview. + ]]> @@ -1279,25 +1279,25 @@ An object that is passed to the method invoked when the asynchronous operation completes. Asynchronously attempts to send an Internet Control Message Protocol (ICMP) echo message to the specified computer, and receive a corresponding ICMP echo reply message from that computer. - method sends the echo message asynchronously and, when the operation completes (successfully or unsuccessfully), returns the status to your application. Call the method when your application should not block. Each call to this method executes in a separate thread that is automatically allocated from the thread pool. When the asynchronous operation completes, it raises the event. To specify the method that is called when raises the event, you must add a delegate to the event before calling . The delegate's method receives a object that contains a object that describes the result of the call. The object inherits the property. This property contains the `userToken` object passed into the call. - + method sends the echo message asynchronously and, when the operation completes (successfully or unsuccessfully), returns the status to your application. Call the method when your application should not block. Each call to this method executes in a separate thread that is automatically allocated from the thread pool. When the asynchronous operation completes, it raises the event. To specify the method that is called when raises the event, you must add a delegate to the event before calling . The delegate's method receives a object that contains a object that describes the result of the call. The object inherits the property. This property contains the `userToken` object passed into the call. + > [!NOTE] -> If your application should block while waiting for a reply, use the methods; these methods are synchronous. - - This method sends a 32 data buffer with the ICMP echo message. The method waits five seconds for an ICMP echo reply message. If it does not receive a reply in that time the method returns and the property is set to . - - This overload uses default settings for packet fragmentation and packet forwarding. The packet that contains the ICMP echo message can be fragmented in transit if the total packet size exceeds the maximum packet size that can be transmitted by one of the routing nodes between the local and remote computers. To prevent fragmentation, use one of the methods that takes an `options` parameter, and set the property to `true`. When is `true` and the total packet size exceeds the maximum packet size that can be transmitted by one of the routing nodes between the local and remote computers, the ICMP echo request fails. When this happens, the is set to . - - The packet or packet fragments can be forwarded by routing nodes 128 times before being discarded. To change this setting, use a overload that takes an `options` parameter, and set the property to the desired value. If the packet does not reach its destination after being forwarded the specified number of times, the packet is discarded and the ICMP echo request fails. When this happens, the is set to . - - - -## Examples - For a code example that demonstrates calling the method, see the class overview. - +> If your application should block while waiting for a reply, use the methods; these methods are synchronous. + + This method sends a 32 data buffer with the ICMP echo message. The method waits five seconds for an ICMP echo reply message. If it does not receive a reply in that time the method returns and the property is set to . + + This overload uses default settings for packet fragmentation and packet forwarding. The packet that contains the ICMP echo message can be fragmented in transit if the total packet size exceeds the maximum packet size that can be transmitted by one of the routing nodes between the local and remote computers. To prevent fragmentation, use one of the methods that takes an `options` parameter, and set the property to `true`. When is `true` and the total packet size exceeds the maximum packet size that can be transmitted by one of the routing nodes between the local and remote computers, the ICMP echo request fails. When this happens, the is set to . + + The packet or packet fragments can be forwarded by routing nodes 128 times before being discarded. To change this setting, use a overload that takes an `options` parameter, and set the property to the desired value. If the packet does not reach its destination after being forwarded the specified number of times, the packet is discarded and the ICMP echo request fails. When this happens, the is set to . + + + +## Examples + For a code example that demonstrates calling the method, see the class overview. + ]]> @@ -1361,25 +1361,25 @@ An object that is passed to the method invoked when the asynchronous operation completes. Asynchronously attempts to send an Internet Control Message Protocol (ICMP) echo message to the computer that has the specified , and receive a corresponding ICMP echo reply message from that computer. This overload allows you to specify a time-out value for the operation. - method sends the Echo message asynchronously and, when the operation completes (successfully or unsuccessfully), returns the status to your application. Call the method when your application should not block. Each call executes in a separate thread that is automatically allocated from the thread pool. When the asynchronous operation completes, it raises the event. Applications use a delegate to specify the method that is called when raises the event. You must add a delegate to the event before calling . The delegate's method receives a object that contains a object that describes the result of the call. The object inherits the property. This property contains the `userToken` object passed into the call. - - If your application should block while waiting for a reply, use the methods; these methods are synchronous. - - If the ICMP echo reply message is not received within the time specified by the `timeout` parameter, the ICMP echo fails, and the property is set to . - + method sends the Echo message asynchronously and, when the operation completes (successfully or unsuccessfully), returns the status to your application. Call the method when your application should not block. Each call executes in a separate thread that is automatically allocated from the thread pool. When the asynchronous operation completes, it raises the event. Applications use a delegate to specify the method that is called when raises the event. You must add a delegate to the event before calling . The delegate's method receives a object that contains a object that describes the result of the call. The object inherits the property. This property contains the `userToken` object passed into the call. + + If your application should block while waiting for a reply, use the methods; these methods are synchronous. + + If the ICMP echo reply message is not received within the time specified by the `timeout` parameter, the ICMP echo fails, and the property is set to . + > [!NOTE] -> When specifying very small numbers for `timeout`, the Ping reply can be received even if `timeout` milliseconds have elapsed. - - This overload uses default settings for packet fragmentation and packet forwarding. The packet that contains the ICMP echo message can be fragmented in transit if the total packet size exceeds the maximum packet size that can be transmitted by one of the routing nodes between the local and remote computers. To prevent fragmentation, use one of the methods that takes an `options` parameter, and set the property to `true`. When is `true` and the total packet size exceeds the maximum packet size that can be transmitted by one of the routing nodes between the local and remote computers, the ICMP echo request fails. When this happens, the is set to . The packet or packet fragments (if fragmented) can be forwarded by routing nodes 128 times before being discarded. To change this setting, use a overload that takes an `options` parameter, and set the property to the desired value. If the packet does not reach its destination after being forwarded the specified number of times, the packet is discarded and the ICMP echo request fails. When this happens, the is set to . - - - -## Examples - For a code example that demonstrates calling a overload, see the class overview. - +> When specifying very small numbers for `timeout`, the Ping reply can be received even if `timeout` milliseconds have elapsed. + + This overload uses default settings for packet fragmentation and packet forwarding. The packet that contains the ICMP echo message can be fragmented in transit if the total packet size exceeds the maximum packet size that can be transmitted by one of the routing nodes between the local and remote computers. To prevent fragmentation, use one of the methods that takes an `options` parameter, and set the property to `true`. When is `true` and the total packet size exceeds the maximum packet size that can be transmitted by one of the routing nodes between the local and remote computers, the ICMP echo request fails. When this happens, the is set to . The packet or packet fragments (if fragmented) can be forwarded by routing nodes 128 times before being discarded. To change this setting, use a overload that takes an `options` parameter, and set the property to the desired value. If the packet does not reach its destination after being forwarded the specified number of times, the packet is discarded and the ICMP echo request fails. When this happens, the is set to . + + + +## Examples + For a code example that demonstrates calling a overload, see the class overview. + ]]> @@ -1445,25 +1445,25 @@ An object that is passed to the method invoked when the asynchronous operation completes. Asynchronously attempts to send an Internet Control Message Protocol (ICMP) echo message to the specified computer, and receive a corresponding ICMP echo reply message from that computer. This overload allows you to specify a time-out value for the operation. - method sends the Echo message asynchronously and, when the operation completes (successfully or unsuccessfully), returns the status to your application. Call the method when your application should not block. Each call executes in a separate thread that is automatically allocated from the thread pool. When the asynchronous operation completes, it raises the event. Applications use a delegate to specify the method that is called when raises the event. You must add a delegate to the event before calling . The delegate's method receives a object that contains a object that describes the result of the call. The object inherits the property. This property contains the `userToken` object passed into the call. - - If your application should block while waiting for a reply, use the methods; these methods are synchronous. - - If the ICMP echo reply message is not received within the time specified by the `timeout` parameter, the ICMP echo fails, and the property is set to . - + method sends the Echo message asynchronously and, when the operation completes (successfully or unsuccessfully), returns the status to your application. Call the method when your application should not block. Each call executes in a separate thread that is automatically allocated from the thread pool. When the asynchronous operation completes, it raises the event. Applications use a delegate to specify the method that is called when raises the event. You must add a delegate to the event before calling . The delegate's method receives a object that contains a object that describes the result of the call. The object inherits the property. This property contains the `userToken` object passed into the call. + + If your application should block while waiting for a reply, use the methods; these methods are synchronous. + + If the ICMP echo reply message is not received within the time specified by the `timeout` parameter, the ICMP echo fails, and the property is set to . + > [!NOTE] -> When specifying very small numbers for `timeout`, the Ping reply can be received even if `timeout` milliseconds have elapsed. - - This overload uses default settings for packet fragmentation and packet forwarding. The packet that contains the ICMP echo message can be fragmented in transit if the total packet size exceeds the maximum packet size that can be transmitted by one of the routing nodes between the local and remote computers. To prevent fragmentation, use one of the methods that takes an `options` parameter, and set the property to `true`. When is `true` and the total packet size exceeds the maximum packet size that can be transmitted by one of the routing nodes between the local and remote computers, the ICMP echo request fails. When this happens, the is set to . The packet or packet fragments (if fragmented) can be forwarded by routing nodes 128 times before being discarded. To change this setting, use a overload that takes an `options` parameter, and set the property to the desired value. If the packet does not reach its destination after being forwarded the specified number of times, the packet is discarded and the ICMP echo request fails. When this happens, the is set to . - - - -## Examples - For a code example that demonstrates calling the method, see the class overview. - +> When specifying very small numbers for `timeout`, the Ping reply can be received even if `timeout` milliseconds have elapsed. + + This overload uses default settings for packet fragmentation and packet forwarding. The packet that contains the ICMP echo message can be fragmented in transit if the total packet size exceeds the maximum packet size that can be transmitted by one of the routing nodes between the local and remote computers. To prevent fragmentation, use one of the methods that takes an `options` parameter, and set the property to `true`. When is `true` and the total packet size exceeds the maximum packet size that can be transmitted by one of the routing nodes between the local and remote computers, the ICMP echo request fails. When this happens, the is set to . The packet or packet fragments (if fragmented) can be forwarded by routing nodes 128 times before being discarded. To change this setting, use a overload that takes an `options` parameter, and set the property to the desired value. If the packet does not reach its destination after being forwarded the specified number of times, the packet is discarded and the ICMP echo request fails. When this happens, the is set to . + + + +## Examples + For a code example that demonstrates calling the method, see the class overview. + ]]> @@ -1537,26 +1537,26 @@ An object that is passed to the method invoked when the asynchronous operation completes. Asynchronously attempts to send an Internet Control Message Protocol (ICMP) echo message with the specified data buffer to the computer that has the specified , and receive a corresponding ICMP echo reply message from that computer. This overload allows you to specify a time-out value for the operation. - method when your application should not block. Each call executes in a separate thread that is automatically allocated from the thread pool. When the asynchronous operation completes, it raises the event. To specify the method that is called when raises the event, you must add a delegate to the event before calling . The delegate's method receives a object that contains a object that describes the result of the call. The object inherits the property. This property contains the `userToken` object passed into the call. - + method when your application should not block. Each call executes in a separate thread that is automatically allocated from the thread pool. When the asynchronous operation completes, it raises the event. To specify the method that is called when raises the event, you must add a delegate to the event before calling . The delegate's method receives a object that contains a object that describes the result of the call. The object inherits the property. This property contains the `userToken` object passed into the call. + > [!NOTE] -> If your application blocks while waiting for a reply, use the methods; these methods are synchronous. - - If the ICMP echo reply message is not received within the time specified by the `timeout` parameter, the ICMP echo fails, and the property is set to . - +> If your application blocks while waiting for a reply, use the methods; these methods are synchronous. + + If the ICMP echo reply message is not received within the time specified by the `timeout` parameter, the ICMP echo fails, and the property is set to . + > [!NOTE] -> When specifying very small numbers for `timeout`, the Ping reply can be received even if `timeout` milliseconds have elapsed. - - This overload uses default settings for packet fragmentation and packet forwarding. The packet that contains the ICMP echo message can be fragmented in transit if the total packet size exceeds the maximum packet size that can be transmitted by one of the routing nodes between the local and remote computers. To prevent fragmentation, use one of the methods that takes an `options` parameter, and set the property to `true`. When is `true` and the total packet size exceeds the maximum packet size that can be transmitted by one of the routing nodes between the local and remote computers, the ICMP echo request fails. When this happens, the is set to . The packet or packet fragments (if fragmented) can be forwarded by routing nodes 128 times before being discarded. To change this setting, use a overload that takes an `options` parameter, and set the property to the desired value. If the packet does not reach its destination after being forwarded the specified number of times, the packet is discarded and the ICMP echo request fails. When this happens, the is set to . - - - -## Examples - For a code example that demonstrates calling a overload, see the class overview. - +> When specifying very small numbers for `timeout`, the Ping reply can be received even if `timeout` milliseconds have elapsed. + + This overload uses default settings for packet fragmentation and packet forwarding. The packet that contains the ICMP echo message can be fragmented in transit if the total packet size exceeds the maximum packet size that can be transmitted by one of the routing nodes between the local and remote computers. To prevent fragmentation, use one of the methods that takes an `options` parameter, and set the property to `true`. When is `true` and the total packet size exceeds the maximum packet size that can be transmitted by one of the routing nodes between the local and remote computers, the ICMP echo request fails. When this happens, the is set to . The packet or packet fragments (if fragmented) can be forwarded by routing nodes 128 times before being discarded. To change this setting, use a overload that takes an `options` parameter, and set the property to the desired value. If the packet does not reach its destination after being forwarded the specified number of times, the packet is discarded and the ICMP echo request fails. When this happens, the is set to . + + + +## Examples + For a code example that demonstrates calling a overload, see the class overview. + ]]> @@ -1632,32 +1632,32 @@ An object that is passed to the method invoked when the asynchronous operation completes. Asynchronously attempts to send an Internet Control Message Protocol (ICMP) echo message with the specified data buffer to the specified computer, and receive a corresponding ICMP echo reply message from that computer. This overload allows you to specify a time-out value for the operation. - method sends the Echo message asynchronously and, when the operation completes (successfully or unsuccessfully), returns the status to your application. Call the method when your application should not block. Each call executes in a separate thread that is automatically allocated from the thread pool. When the asynchronous operation completes, it raises the event. Applications use a delegate to specify the method that is called when raises the event. You must add a delegate to the event before calling . The delegate's method receives a object containing a object that describes the result of the call. The object inherits the property. This property contains the `userToken` object passed into the call. - - If your application should block while waiting for a reply, use the methods; these methods are synchronous. - - If the ICMP echo reply message is not received within the time specified by the `timeout` parameter, the ICMP echo fails, and the property is set to . - + method sends the Echo message asynchronously and, when the operation completes (successfully or unsuccessfully), returns the status to your application. Call the method when your application should not block. Each call executes in a separate thread that is automatically allocated from the thread pool. When the asynchronous operation completes, it raises the event. Applications use a delegate to specify the method that is called when raises the event. You must add a delegate to the event before calling . The delegate's method receives a object containing a object that describes the result of the call. The object inherits the property. This property contains the `userToken` object passed into the call. + + If your application should block while waiting for a reply, use the methods; these methods are synchronous. + + If the ICMP echo reply message is not received within the time specified by the `timeout` parameter, the ICMP echo fails, and the property is set to . + > [!NOTE] -> When specifying very small numbers for `timeout`, the Ping reply can be received even if `timeout` milliseconds have elapsed. - - This overload uses default settings for packet fragmentation and packet forwarding. The packet that contains the ICMP echo message can be fragmented in transit if the total packet size exceeds the maximum packet size that can be transmitted by one of the routing nodes between the local and remote computers. To prevent fragmentation, use one of the methods that takes an `options` parameter, and set the property to `true`. When is `true` and the total packet size exceeds the maximum packet size that can be transmitted by one of the routing nodes between the local and remote computers, the ICMP echo request fails. When this happens, the is set to . The packet or packet fragments (if fragmented) can be forwarded by routing nodes 128 times before being discarded. To change this setting, use a overload that takes an `options` parameter, and set the property to the desired value. If the packet does not reach its destination after being forwarded the specified number of times, the packet is discarded and the ICMP echo request fails. When this happens, the is set to . - - - -## Examples - The following code example demonstrates how to call a overload, see the class overview. - +> When specifying very small numbers for `timeout`, the Ping reply can be received even if `timeout` milliseconds have elapsed. + + This overload uses default settings for packet fragmentation and packet forwarding. The packet that contains the ICMP echo message can be fragmented in transit if the total packet size exceeds the maximum packet size that can be transmitted by one of the routing nodes between the local and remote computers. To prevent fragmentation, use one of the methods that takes an `options` parameter, and set the property to `true`. When is `true` and the total packet size exceeds the maximum packet size that can be transmitted by one of the routing nodes between the local and remote computers, the ICMP echo request fails. When this happens, the is set to . The packet or packet fragments (if fragmented) can be forwarded by routing nodes 128 times before being discarded. To change this setting, use a overload that takes an `options` parameter, and set the property to the desired value. If the packet does not reach its destination after being forwarded the specified number of times, the packet is discarded and the ICMP echo request fails. When this happens, the is set to . + + + +## Examples + The following code example demonstrates how to call a overload, see the class overview. + ]]> - is or is an empty string (""). - - -or- - + is or is an empty string (""). + + -or- + is . is less than zero. @@ -1733,37 +1733,37 @@ An object that is passed to the method invoked when the asynchronous operation completes. Asynchronously attempts to send an Internet Control Message Protocol (ICMP) echo message with the specified data buffer to the computer that has the specified , and receive a corresponding ICMP echo reply message from that computer. This overload allows you to specify a time-out value for the operation and control fragmentation and Time-to-Live values for the ICMP echo message packet. - method sends the Echo message asynchronously and, when the operation completes (successfully or unsuccessfully), returns the status to your application. Call the method when your application must not block. Each call executes in a separate thread that is automatically allocated from the thread pool. When the asynchronous operation completes, it raises the event. Applications use a delegate to specify the method that is called when raises the event. You must add a delegate to the event before calling . The delegate's method receives a object that contains a object that describes the result of the call. The object inherits the property. This property contains the `userToken` object passed into the call. - - If your application blocks while waiting for a reply, use the methods; these methods are synchronous. - - If the ICMP echo reply message is not received within the time specified by the `timeout` parameter, the ICMP echo fails, and the property is set to . - + method sends the Echo message asynchronously and, when the operation completes (successfully or unsuccessfully), returns the status to your application. Call the method when your application must not block. Each call executes in a separate thread that is automatically allocated from the thread pool. When the asynchronous operation completes, it raises the event. Applications use a delegate to specify the method that is called when raises the event. You must add a delegate to the event before calling . The delegate's method receives a object that contains a object that describes the result of the call. The object inherits the property. This property contains the `userToken` object passed into the call. + + If your application blocks while waiting for a reply, use the methods; these methods are synchronous. + + If the ICMP echo reply message is not received within the time specified by the `timeout` parameter, the ICMP echo fails, and the property is set to . + > [!NOTE] -> When specifying very small numbers for `timeout`, the Ping reply can be received even if `timeout` milliseconds have elapsed. - - If the property is `true` and the total packet size exceeds the maximum packet size that can be transmitted by one of the routing nodes between the local and remote computers, the ICMP echo request fails. When this happens, the is set to . - - Use the property to specify the maximum number of times the ICMP echo message can be forwarded before reaching its destination. If the packet does not reach its destination after being forwarded the specified number of times, the packet is discarded and the ICMP echo request fails. When this happens, the is set to . - - - -## Examples - The following code example demonstrates how to call this method. For an implementation of the callback method, see the method overload example section. - - The following code example requires the following namespaces: - +> When specifying very small numbers for `timeout`, the Ping reply can be received even if `timeout` milliseconds have elapsed. + + If the property is `true` and the total packet size exceeds the maximum packet size that can be transmitted by one of the routing nodes between the local and remote computers, the ICMP echo request fails. When this happens, the is set to . + + Use the property to specify the maximum number of times the ICMP echo message can be forwarded before reaching its destination. If the packet does not reach its destination after being forwarded the specified number of times, the packet is discarded and the ICMP echo request fails. When this happens, the is set to . + + + +## Examples + The following code example demonstrates how to call this method. For an implementation of the callback method, see the method overload example section. + + The following code example requires the following namespaces: + :::code language="cpp" source="~/snippets/cpp/VS_Snippets_Remoting/NCLPingSampler/CPP/pingtest.cpp" id="Snippet0"::: - :::code language="csharp" source="~/snippets/csharp/System.Net.NetworkInformation/Ping/Send/pingtest.cs" id="Snippet0"::: - - The following code example sends an ICMP echo message asynchronously. - + :::code language="csharp" source="~/snippets/csharp/System.Net.NetworkInformation/Ping/Send/pingtest.cs" id="Snippet0"::: + + The following code example sends an ICMP echo message asynchronously. + :::code language="cpp" source="~/snippets/cpp/VS_Snippets_Remoting/NCLPingSampler/CPP/pingtest.cpp" id="Snippet7"::: - :::code language="csharp" source="~/snippets/csharp/System.Net.NetworkInformation/Ping/Send/pingtest.cs" id="Snippet7"::: - + :::code language="csharp" source="~/snippets/csharp/System.Net.NetworkInformation/Ping/Send/pingtest.cs" id="Snippet7"::: + ]]> @@ -1842,37 +1842,37 @@ An object that is passed to the method invoked when the asynchronous operation completes. Asynchronously attempts to send an Internet Control Message Protocol (ICMP) echo message with the specified data buffer to the specified computer, and receive a corresponding ICMP echo reply message from that computer. This overload allows you to specify a time-out value for the operation and control fragmentation and Time-to-Live values for the ICMP packet. - method sends the Echo message asynchronously and, when the operation completes (successfully or unsuccessfully), returns the status to your application. Call the method when your application must not block. Each call executes in a separate thread that is automatically allocated from the thread pool. When the asynchronous operation completes, it raises the event. Applications use a delegate to specify the method that is called when raises the event. You must add a delegate to the event before calling . The delegate's method receives a object that contains a object that describes the result of the call. The object inherits the property. This property contains the `userToken` object passed into the call. - - If your application should block while waiting for a reply, use the methods; these methods are synchronous. - - If the ICMP echo reply message is not received within the time specified by the `timeout` parameter, the ICMP echo fails, and the property is set to . - + method sends the Echo message asynchronously and, when the operation completes (successfully or unsuccessfully), returns the status to your application. Call the method when your application must not block. Each call executes in a separate thread that is automatically allocated from the thread pool. When the asynchronous operation completes, it raises the event. Applications use a delegate to specify the method that is called when raises the event. You must add a delegate to the event before calling . The delegate's method receives a object that contains a object that describes the result of the call. The object inherits the property. This property contains the `userToken` object passed into the call. + + If your application should block while waiting for a reply, use the methods; these methods are synchronous. + + If the ICMP echo reply message is not received within the time specified by the `timeout` parameter, the ICMP echo fails, and the property is set to . + > [!NOTE] -> When specifying very small numbers for `timeout`, the Ping reply can be received even if `timeout` milliseconds have elapsed. - - If the property is `true` and the total packet size exceeds the maximum packet size that can be transmitted by one of the routing nodes between the local and remote computers, the ICMP echo request fails. When this happens, the is set to . - - Use the property to specify the maximum number of times the ICMP echo message can be forwarded before reaching its destination. If the packet does not reach its destination after being forwarded the specified number of times, the packet is discarded and the ICMP echo request fails. When this happens, the is set to . - - - -## Examples - The following code example demonstrates how to call this method. - +> When specifying very small numbers for `timeout`, the Ping reply can be received even if `timeout` milliseconds have elapsed. + + If the property is `true` and the total packet size exceeds the maximum packet size that can be transmitted by one of the routing nodes between the local and remote computers, the ICMP echo request fails. When this happens, the is set to . + + Use the property to specify the maximum number of times the ICMP echo message can be forwarded before reaching its destination. If the packet does not reach its destination after being forwarded the specified number of times, the packet is discarded and the ICMP echo request fails. When this happens, the is set to . + + + +## Examples + The following code example demonstrates how to call this method. + :::code language="cpp" source="~/snippets/cpp/VS_Snippets_Remoting/NclPingAsync/CPP/asyncping.cpp" id="Snippet1"::: - :::code language="csharp" source="~/snippets/csharp/System.Net.NetworkInformation/Ping/Overview/asyncping.cs" id="Snippet1"::: - + :::code language="csharp" source="~/snippets/csharp/System.Net.NetworkInformation/Ping/Overview/asyncping.cs" id="Snippet1"::: + ]]> - is or is an empty string (""). - - -or- - + is or is an empty string (""). + + -or- + is . is less than zero. @@ -1922,11 +1922,11 @@ Cancels all pending asynchronous requests to send an Internet Control Message Protocol (ICMP) echo message and receives a corresponding ICMP echo reply message. - that have not completed. - + that have not completed. + ]]> @@ -1940,11 +1940,11 @@ Sends an Internet Control Message Protocol (ICMP) echo message to a computer, and receives a corresponding ICMP echo reply message from that computer as an asynchronous operation. - methods can originate from a malicious remote computer. Do not connect to the remote computer using this. Use DNS to determine the IP address of the machine to which you want to connect. - + methods can originate from a malicious remote computer. Do not connect to the remote computer using this. Use DNS to determine the IP address of the machine to which you want to connect. + ]]> @@ -1990,11 +1990,11 @@ The IP address returned by any of the Send an Internet Control Message Protocol (ICMP) echo message with the specified data buffer to the computer that has the specified , and receives a corresponding ICMP echo reply message from that computer as an asynchronous operation. The task object representing the asynchronous operation. - > object will complete after the ICMP packet has been sent and the response has been received. - + > object will complete after the ICMP packet has been sent and the response has been received. + ]]> @@ -2047,11 +2047,11 @@ The IP address returned by any of the Sends an Internet Control Message Protocol (ICMP) echo message with the specified data buffer to the specified computer, and receive a corresponding ICMP echo reply message from that computer as an asynchronous operation. The task object representing the asynchronous operation. - > object will complete after the ICMP packet has been sent and the response has been received. - + > object will complete after the ICMP packet has been sent and the response has been received. + ]]> @@ -2106,11 +2106,11 @@ The IP address returned by any of the Send an Internet Control Message Protocol (ICMP) echo message with the specified data buffer to the computer that has the specified , and receives a corresponding ICMP echo reply message from that computer as an asynchronous operation. This overload allows you to specify a time-out value for the operation. The task object representing the asynchronous operation. - > object will complete after the ICMP packet has been sent and the response has been received. - + > object will complete after the ICMP packet has been sent and the response has been received. + ]]> @@ -2165,21 +2165,21 @@ The IP address returned by any of the Sends an Internet Control Message Protocol (ICMP) echo message with the specified data buffer to the specified computer, and receive a corresponding ICMP echo reply message from that computer as an asynchronous operation. This overload allows you to specify a time-out value for the operation. The task object representing the asynchronous operation. - > object will complete after the ICMP packet has been sent and the response has been received. - + > object will complete after the ICMP packet has been sent and the response has been received. + ]]> - is . + is . is less than zero. A call to the method is in progress. An exception was thrown while sending or receiving the ICMP messages. See the inner exception for the exact exception that was thrown. - is not a valid IP address. + is not a valid IP address. This object has been disposed. @@ -2228,11 +2228,11 @@ The IP address returned by any of the Send an Internet Control Message Protocol (ICMP) echo message with the specified data buffer to the computer that has the specified , and receives a corresponding ICMP echo reply message from that computer as an asynchronous operation. This overload allows you to specify a time-out value for the operation and a buffer to use for send and receive. The task object representing the asynchronous operation. - > object will complete after the ICMP packet has been sent and the response has been received. - + > object will complete after the ICMP packet has been sent and the response has been received. + ]]> @@ -2293,18 +2293,18 @@ The IP address returned by any of the Sends an Internet Control Message Protocol (ICMP) echo message with the specified data buffer to the specified computer, and receive a corresponding ICMP echo reply message from that computer as an asynchronous operation. This overload allows you to specify a time-out value for the operation and a buffer to use for send and receive. The task object representing the asynchronous operation. - > object will complete after the ICMP packet has been sent and the response has been received. - + > object will complete after the ICMP packet has been sent and the response has been received. + ]]> - is or is an empty string (""). - - -or- - + is or is an empty string (""). + + -or- + is . is less than zero. @@ -2372,11 +2372,11 @@ The IP address returned by any of the Sends an Internet Control Message Protocol (ICMP) echo message with the specified data buffer to the computer that has the specified , and receives a corresponding ICMP echo reply message from that computer as an asynchronous operation. This overload allows you to specify a time-out value for the operation, a buffer to use for send and receive, and control fragmentation and Time-to-Live values for the ICMP echo message packet. The task object representing the asynchronous operation. - > object will complete after the ICMP packet has been sent and the response has been received. - + > object will complete after the ICMP packet has been sent and the response has been received. + ]]> @@ -2447,18 +2447,18 @@ The IP address returned by any of the Sends an Internet Control Message Protocol (ICMP) echo message with the specified data buffer to the specified computer, and receive a corresponding ICMP echo reply message from that computer as an asynchronous operation. This overload allows you to specify a time-out value for the operation, a buffer to use for send and receive, and control fragmentation and Time-to-Live values for the ICMP echo message packet. The task object representing the asynchronous operation. - > object will complete after the ICMP packet has been sent and the response has been received. - + > object will complete after the ICMP packet has been sent and the response has been received. + ]]> - is or is an empty string (""). - - -or- - + is or is an empty string (""). + + -or- + is . is less than zero. @@ -2604,7 +2604,7 @@ The IP address returned by any of the object that has been disposed, you receive an . ]]> diff --git a/xml/System.Net.NetworkInformation/UnicastIPAddressInformationCollection.xml b/xml/System.Net.NetworkInformation/UnicastIPAddressInformationCollection.xml index bcca258b2e9..ec997cacf2d 100644 --- a/xml/System.Net.NetworkInformation/UnicastIPAddressInformationCollection.xml +++ b/xml/System.Net.NetworkInformation/UnicastIPAddressInformationCollection.xml @@ -282,22 +282,22 @@ The zero-based index in at which the copy begins. Copies the elements in this collection to a one-dimensional array of type . - is . - is less than zero. + is less than zero. - is multidimensional. - - -or- - + is multidimensional. + + -or- + The number of elements in this is greater than the available space from to the end of the destination . The elements in this cannot be cast automatically to the type of the destination . @@ -387,15 +387,15 @@ Returns an object that can be used to iterate through this collection. An object that implements the interface and provides access to the types in this collection. - method before you can access the first element. To access the element at the current position, call the property. - - Do not modify the collection while using the enumerator. If the collection is modified while an enumerator is in use, an attempt to set the position by calling or causes an . - - For a detailed description of enumerators, see the documentation for the class and the method. - + method before you can access the first element. To access the element at the current position, call the property. + + Do not modify the collection while using the enumerator. If the collection is modified while an enumerator is in use, an attempt to set the position by calling or causes an . + + For a detailed description of enumerators, see the documentation for the class and the method. + ]]> @@ -583,15 +583,15 @@ Returns an object that can be used to iterate through this collection. An object that implements the interface and provides access to the types in this collection. - method before you can access the first element. To access the element at the current position, call the property. - - Do not modify the collection while using the enumerator. If the collection is modified while an enumerator is in use, an attempt to set the position by calling or causes an . - - For a detailed description of enumerators, see the documentation for the class and the method. - + method before you can access the first element. To access the element at the current position, call the property. + + Do not modify the collection while using the enumerator. If the collection is modified while an enumerator is in use, an attempt to set the position by calling or causes an . + + For a detailed description of enumerators, see the documentation for the class and the method. + ]]> diff --git a/xml/System.Net.PeerToPeer.Collaboration/PeerContact.xml b/xml/System.Net.PeerToPeer.Collaboration/PeerContact.xml index 07ae5f46064..6af9f31bb62 100644 --- a/xml/System.Net.PeerToPeer.Collaboration/PeerContact.xml +++ b/xml/System.Net.PeerToPeer.Collaboration/PeerContact.xml @@ -30,15 +30,15 @@ Represents a peer for which a user has retrieved extended information. - object must be created for a remote peer or for a user to collaborate with the remote peer when it is outside of the "People Near Me" scope. A object can exist as either an application running on a remote computer, or the user of a remote computer. An instance of this class can be added to the which stores the contact information in a persistent manner. - - An application invitation from a is both authenticated and encrypted. The UI dialog to accept or reject an invitation from a peer contact also indicates that the inviter is trusted. - - Subscribing to a object means a remote peer can see its registered applications, objects and presence information. To subscribe to a , the caller must be signed in to the peer collaboration infrastructure via or signed in via the Windows UI. All other operations do not require sign-in. - + object must be created for a remote peer or for a user to collaborate with the remote peer when it is outside of the "People Near Me" scope. A object can exist as either an application running on a remote computer, or the user of a remote computer. An instance of this class can be added to the which stores the contact information in a persistent manner. + + An application invitation from a is both authenticated and encrypted. The UI dialog to accept or reject an invitation from a peer contact also indicates that the inviter is trusted. + + Subscribing to a object means a remote peer can see its registered applications, objects and presence information. To subscribe to a , the caller must be signed in to the peer collaboration infrastructure via or signed in via the Windows UI. All other operations do not require sign-in. + ]]> @@ -73,11 +73,11 @@ The serialization destination associated with the . No public constructor is defined for this class. - or methods. - + or methods. + ]]> @@ -139,11 +139,11 @@ Gets or sets the X509Certificate (public key) for the peer identified by this instance. The X509Certificate (public key) for the peer identified by this instance. The default value for this property is . - of . This state is created when the peer collaboration session begins. - + of . This state is created when the peer collaboration session begins. + ]]> This object has been disposed. @@ -173,11 +173,11 @@ which represents the display name of this . Unless explicitly specified, the default value for all properties is for reference types. - in instances where a may have multiple email addresses, or if there are multiple peers with the same display name. - + in instances where a may have multiple email addresses, or if there are multiple peers with the same display name. + ]]> This object has been disposed. @@ -214,11 +214,11 @@ to release both managed and unmanaged resources; to release only unmanaged resources. Releases the unmanaged resources and optionally releases the managed resources used by the object. - leaves a collaboration session, certain objects are no longer required. If this contact had been collaborating with any other endpoint(s) not directly registered with the peer host, and the host expects to continue to collaborate with them, the host must register those endpoints within an application or within its before disposing of this object. - + leaves a collaboration session, certain objects are no longer required. If this contact had been collaborating with any other endpoint(s) not directly registered with the peer host, and the host expects to continue to collaborate with them, the host must register those endpoints within an application or within its before disposing of this object. + ]]> @@ -244,11 +244,11 @@ object that contains the email address associated with the . - object is used to represent the mail address. The Contact Manager allows for multiple email addresses within one instance. The default value for this property is `null`. - + object is used to represent the mail address. The Contact Manager allows for multiple email addresses within one instance. The default value for this property is `null`. + ]]> This object has been disposed. @@ -262,11 +262,11 @@ Determines whether the of this object is equivalent to the name of another object. - has the same as the current instance, otherwise `false`. This method also returns `false` if passed parameters are `null`. - + has the same as the current instance, otherwise `false`. This method also returns `false` if passed parameters are `null`. + ]]> @@ -302,11 +302,11 @@ if the instance provided has matching data; otherwise, . - objects. - + objects. + ]]> The object has been disposed. @@ -337,13 +337,13 @@ if the instance provided has matching data; otherwise, . This method also returns if the passed parameter is . - objects include peer host names, relative peer names, and names de-encapsulated from other objects. - - Normalization does not occur on the strings prior to comparison. All normalization should have been completed while or before constructing the objects. - + objects include peer host names, relative peer names, and names de-encapsulated from other objects. + + Normalization does not occur on the strings prior to comparison. All normalization should have been completed while or before constructing the objects. + ]]> The object has been disposed. @@ -376,13 +376,13 @@ if the instances provided have matching data; otherwise, . - is in use simultaneously by two different remote peers. - - Other objects that may be compared with objects include peer host names, relative peer names, and names de-encapsulated from other objects. - + is in use simultaneously by two different remote peers. + + Other objects that may be compared with objects include peer host names, relative peer names, and names de-encapsulated from other objects. + ]]> @@ -418,18 +418,18 @@ Creates a instance based on provided XML data. A string that represents the XML object model for encoding the instance. - . - - This class is intended to be a lightweight implementation of a simple XML object model for use within the collaboration infrastructure, and not for use as a general XML object model. - + . + + This class is intended to be a lightweight implementation of a simple XML object model for use within the collaboration infrastructure, and not for use as a general XML object model. + ]]> Parameter cannot be . - - Unable to complete operation - + - Unable to complete operation + - Parameter is not a valid object. @@ -441,11 +441,11 @@ Retrieves the objects that were registered by the remote peer into the local cache. - class. This functionality is not exposed on any other type of peer for security reasons. - + class. This functionality is not exposed on any other type of peer for security reasons. + ]]> @@ -477,19 +477,19 @@ Retrieves the objects that were registered by the remote peer into the local cache. The from the local cache. If associated applications are not found for the , a collection of size zero (0) is returned. - associated with the specified the method must be called prior to calling this method. - - While the caller is not required to sign-in to the collaboration infrastructure for this method to complete successfully, a successful call to or one of the methods must have been completed while the caller was previously signed in. - - This functionality is only exposed on the class. This functionality is not exposed on any other type of peer for security reasons. - + associated with the specified the method must be called prior to calling this method. + + While the caller is not required to sign-in to the collaboration infrastructure for this method to complete successfully, a successful call to or one of the methods must have been completed while the caller was previously signed in. + + This functionality is only exposed on the class. This functionality is not exposed on any other type of peer for security reasons. + ]]> - - The calling peer is not subscribed to the . - + - The calling peer is not subscribed to the . + - The calling peer has not yet called the method. Unable to complete operation. @@ -527,19 +527,19 @@ Gets the collection of objects with the specified from the local cache. The from the local cache. If no applications are found with the specified , a collection of size zero (0) is returned. - associated with the specified the method must be called prior to calling this method. - - While the caller is not required to sign-in to the collaboration infrastructure for this method to complete successfully, a successful call to or one of the methods must have been completed while the caller was previously signed in. - - This functionality is only exposed on the class. This functionality is not exposed on any other type of peer for security reasons. - + associated with the specified the method must be called prior to calling this method. + + While the caller is not required to sign-in to the collaboration infrastructure for this method to complete successfully, a successful call to or one of the methods must have been completed while the caller was previously signed in. + + This functionality is only exposed on the class. This functionality is not exposed on any other type of peer for security reasons. + ]]> - - The calling peer is not subscribed to the . - + - The calling peer is not subscribed to the . + - The calling peer has not yet called the method. Unable to complete operation. @@ -578,21 +578,21 @@ Gets the associated with the specified . The associated with the specified . If applications are not associated with the specified , a collection of size zero (0) is returned. - associated with the specified the method must be called prior to calling this method. - - While the caller is not required to sign-in to the collaboration infrastructure for this method to complete successfully, a successful call to or one of the methods must have been completed while the caller was previously signed in. - - This functionality is only exposed on the class. This functionality is not exposed on any other type of peer for security reasons. - + associated with the specified the method must be called prior to calling this method. + + While the caller is not required to sign-in to the collaboration infrastructure for this method to complete successfully, a successful call to or one of the methods must have been completed while the caller was previously signed in. + + This functionality is only exposed on the class. This functionality is not exposed on any other type of peer for security reasons. + ]]> cannot be . - - The calling peer is not subscribed to the . - + - The calling peer is not subscribed to the . + - The calling peer has not yet called the method. Unable to complete operation. @@ -632,25 +632,25 @@ The endpoint associated with the . Contains application information associated with the . Gets the associated with the specified . - The collection of objects associated with the . - + The collection of objects associated with the . + If applications identified by the ID are not found for the , or if the ID for the endpoint is or invalid, a collection of size zero (0) is returned. - associated with the specified the method must be called prior to calling this method. - - While the caller is not required to sign-in to the collaboration infrastructure for this method to complete successfully, a successful call to or one of the methods must have been completed while the caller was previously signed in. - - This functionality is only exposed on the class. This functionality is not exposed on any other type of peer for security reasons. - + associated with the specified the method must be called prior to calling this method. + + While the caller is not required to sign-in to the collaboration infrastructure for this method to complete successfully, a successful call to or one of the methods must have been completed while the caller was previously signed in. + + This functionality is only exposed on the class. This functionality is not exposed on any other type of peer for security reasons. + ]]> cannot be . - - The calling peer is not subscribed to the . - + - The calling peer is not subscribed to the . + - The calling peer has not yet called the method. Unable to complete operation. @@ -682,11 +682,11 @@ Returns the hash code for a instance. A 32-bit signed integer hash code. - The object has been disposed. @@ -720,11 +720,11 @@ Contains the destination for the serialized stream associated with the object. Populates a object with the data needed to serialize the . - method of the base type. - + method of the base type. + ]]> @@ -774,24 +774,24 @@ Gets the registered by the specified and stored in the local cache. The associated with the specified . If no applications are associated with the endpoint, a collection of size zero (0) is returned. - associated with the specified the method must be called prior to calling this method. - - While the caller is not required to sign-in to the collaboration infrastructure for this method to complete successfully, a successful call to or one of the methods must have been completed while the caller was previously signed in. - + associated with the specified the method must be called prior to calling this method. + + While the caller is not required to sign-in to the collaboration infrastructure for this method to complete successfully, a successful call to or one of the methods must have been completed while the caller was previously signed in. + ]]> cannot be . - - The calling peer is not subscribed to the associated with the . - + - The calling peer is not subscribed to the associated with the . + - The calling peer has not yet called the method. Unable to complete operation. - Additional overloads are defined on the class instead of the subclasses and . - + Additional overloads are defined on the class instead of the subclasses and . + Calling this method requires a of . This state is created when the peer collaboration session begins. @@ -830,24 +830,24 @@ Gets the collection of peer objects registered by the specified and registered in the identified by the specified . The associated with the specified . If no applications are associated with the endpoint, a collection of size zero (0) is returned. - associated with the specified the method must be called prior to calling this method. - - While the caller is not required to sign-in to the collaboration infrastructure for this method to complete successfully, a successful call to or one of the methods must have been completed while the caller was previously signed in. - + associated with the specified the method must be called prior to calling this method. + + While the caller is not required to sign-in to the collaboration infrastructure for this method to complete successfully, a successful call to or one of the methods must have been completed while the caller was previously signed in. + ]]> cannot be . - - The calling peer is not subscribed to the . - + - The calling peer is not subscribed to the . + - The calling peer has not yet called the method. Unable to complete operation. - Additional overloads are defined on the class instead of the subclasses and . - + Additional overloads are defined on the class instead of the subclasses and . + Calling this method requires a of . This state is created when the peer collaboration session begins. @@ -862,11 +862,11 @@ Sends an invitation to join into peer collaboration activity sponsored by the sender. - infrastructure for this method to complete successfully. A from the invitee is not the same as the invitee accepting the invitation to collaborate. If an invitation is sent to a remote peer that has not installed the application, the invitation is automatically declined. - + infrastructure for this method to complete successfully. A from the invitee is not the same as the invitee accepting the invitation to collaborate. If an invitation is sent to a remote peer that has not installed the application, the invitation is automatically declined. + ]]> @@ -901,11 +901,11 @@ Sends an invitation to join into peer collaboration sponsored by the sender. A from the peer who received the invitation. - infrastructure for this method to complete successfully. A from the invitee is not the same as the invitee accepting the invitation to collaborate. If an invitation is sent to a remote peer that has not installed the application, the invitation is automatically declined. - + infrastructure for this method to complete successfully. A from the invitee is not the same as the invitee accepting the invitation to collaborate. If an invitation is sent to a remote peer that has not installed the application, the invitation is automatically declined. + ]]> The object has been disposed. @@ -948,20 +948,20 @@ Sends an invitation to a specific endpoint to join into peer collaboration with the sender of the invitation. A from the peer endpoint who received the invitation. - infrastructure for this method to complete successfully. A from the invitee is not the same as the invitee accepting the invitation to collaborate. If an invitation is sent to a remote peer that has not installed the application, the invitation is automatically declined. - + infrastructure for this method to complete successfully. A from the invitee is not the same as the invitee accepting the invitation to collaborate. If an invitation is sent to a remote peer that has not installed the application, the invitation is automatically declined. + ]]> cannot be . The object has been disposed. - - Unable to complete operation. - -- The currently executing application is not registered with the peer collaboration infrastructure. - + - Unable to complete operation. + +- The currently executing application is not registered with the peer collaboration infrastructure. + - specified by object is not valid. Calling this method requires a of . This state is created when the peer collaboration session begins. @@ -1005,13 +1005,13 @@ Sends the specified invitation to join into the specified sponsored by the sender. A from the peer who received the invitation. - infrastructure for this method to complete successfully. A from the invitee is not the same as the invitee accepting the invitation to collaborate. If an invitation is sent to a remote peer that has not installed the application, the invitation is automatically declined. - - Calling this method requires a of . This state is created when the peer collaboration session begins. - + infrastructure for this method to complete successfully. A from the invitee is not the same as the invitee accepting the invitation to collaborate. If an invitation is sent to a remote peer that has not installed the application, the invitation is automatically declined. + + Calling this method requires a of . This state is created when the peer collaboration session begins. + ]]> @@ -1062,16 +1062,16 @@ Sends the specified invitation to the specified to join into the specified application sponsored by the sender. A from the peer who received the invitation. - infrastructure for this method to complete successfully. A from the invitee is not the same as the invitee accepting the invitation to collaborate. If an invitation is sent to a remote peer that has not installed the application, the invitation is automatically declined. - + infrastructure for this method to complete successfully. A from the invitee is not the same as the invitee accepting the invitation to collaborate. If an invitation is sent to a remote peer that has not installed the application, the invitation is automatically declined. + ]]> - Endpoint in cannot be . - - object cannot be empty. - + Endpoint in cannot be . + - object cannot be empty. + - and objects cannot be . The object has been disposed. The for the current application does not exist or is empty. @@ -1090,16 +1090,16 @@ Begins an asynchronous invitation operation for an endpoint to join a application sponsored by the sender of the invitation. - infrastructure for this method to complete successfully. A from the invitee is not the same as the invitee accepting the invitation to collaborate. If an invitation is sent to a remote peer that has not installed the application, the invitation is automatically declined. - + infrastructure for this method to complete successfully. A from the invitee is not the same as the invitee accepting the invitation to collaborate. If an invitation is sent to a remote peer that has not installed the application, the invitation is automatically declined. + ]]> - Additional overloads are defined on the class instead of the subclasses and . - + Additional overloads are defined on the class instead of the subclasses and . + Calling this method requires a of . This state is created when the peer collaboration session begins. @@ -1136,22 +1136,22 @@ User-defined object to pass to the callback of the asynchronous operation. Also used to identify the asynchronous operation for cancellation. This parameter must be specified and is unique across all asynchronous invitation operations in progress. Begins an asynchronous invitation operation for an endpoint to join a application sponsored by the sender of the invitation. The invitation is identified using the specified . - infrastructure for this method to complete successfully. A from the invitee is not the same as the invitee accepting the invitation to collaborate. If an invitation is sent to a remote peer that has not installed the application, the invitation is automatically declined. - + infrastructure for this method to complete successfully. A from the invitee is not the same as the invitee accepting the invitation to collaborate. If an invitation is sent to a remote peer that has not installed the application, the invitation is automatically declined. + ]]> - cannot be . + cannot be . The object has been disposed. - - The for the current application does not exist or is empty. - + - The for the current application does not exist or is empty. + - cannot be . - Additional overloads are defined on the class instead of the subclasses and . - + Additional overloads are defined on the class instead of the subclasses and . + Calling this method requires a of . This state is created when the peer collaboration session begins. @@ -1190,23 +1190,23 @@ User-defined object to pass to the callback of the asynchronous operation. Also used to identify the asynchronous operation for cancellation. This parameter must be specified and is unique across all asynchronous invitation operations in progress. Begins an asynchronous invitation operation for the specified peer endpoint to join a application sponsored by the sender of the invitation. The invitation is identified using the specified . - infrastructure for this method to complete successfully. A from the invitee is not the same as the invitee accepting the invitation to collaborate. If an invitation is sent to a remote peer that has not installed the application, the invitation is automatically declined. - + infrastructure for this method to complete successfully. A from the invitee is not the same as the invitee accepting the invitation to collaborate. If an invitation is sent to a remote peer that has not installed the application, the invitation is automatically declined. + ]]> - - cannot be . - + - cannot be . + - Endpoint in cannot be . object cannot be . The object has been disposed. The for the current application does not exist or is empty. - Additional overloads are defined on the class instead of the subclasses and . - + Additional overloads are defined on the class instead of the subclasses and . + Calling this method requires a of . This state is created when the peer collaboration session begins. @@ -1250,24 +1250,24 @@ User-defined object to pass to the callback of the asynchronous operation. Also used to identify the asynchronous operation for cancellation. This parameter must be specified and is unique across all asynchronous invitation operations in progress. Begins an asynchronous invitation operation for the specified peer endpoints to join the specified collaboration sponsored by the sender of the invitation. - infrastructure for this method to complete successfully. A from the invitee is not the same as the invitee accepting the invitation to collaborate. If an invitation is sent to a remote peer that has not installed the application, the invitation is automatically declined. - + infrastructure for this method to complete successfully. A from the invitee is not the same as the invitee accepting the invitation to collaborate. If an invitation is sent to a remote peer that has not installed the application, the invitation is automatically declined. + ]]> - cannot be . + cannot be . object cannot be . The object has been disposed. - - The for the current application does not exist or is empty. - + - The for the current application does not exist or is empty. + - Endpoint collection is empty or . - Additional overloads are defined on the class instead of the subclasses and . - + Additional overloads are defined on the class instead of the subclasses and . + Calling this method requires a of . This state is created when the peer collaboration session begins. @@ -1312,23 +1312,23 @@ User-defined object to pass to the callback of the asynchronous operation. Also used to identify the asynchronous operation for cancellation. This parameter must be specified and is unique across all asynchronous invitation operations in progress. Begins an asynchronous invitation operation for the specified to join the specified collaboration sponsored by the sender of the invitation. - infrastructure for this method to complete successfully. A from the invitee is not the same as the invitee accepting the invitation to collaborate. If an invitation is sent to a remote peer that has not installed the application, the invitation is automatically declined. - + infrastructure for this method to complete successfully. A from the invitee is not the same as the invitee accepting the invitation to collaborate. If an invitation is sent to a remote peer that has not installed the application, the invitation is automatically declined. + ]]> - - cannot be null. - + - cannot be null. + - Endpoint specified by cannot be . and objects cannot be . The object has been disposed. The for the current application does not exist or is empty. - Additional overloads are defined on the class instead of the subclasses and . - + Additional overloads are defined on the class instead of the subclasses and . + Calling this method requires a of . This state is created when the peer collaboration session begins. @@ -1357,17 +1357,17 @@ if this is subscribed to this endpoint, if the contact has not subscribed or has unsubscribed. - is not the same as a peer host. A peer host has an instance within the of the remote peer, and the relationship is that they have invited the peer to collaborate. An endpoint has a "Me" instance within its own contact manager and the peer host, but the relationship is not specified. - - If the peer host is in the , and the peer contact chooses not to , its can have a value of blocked, rather than deleting its entry from the host Contact Manager. - - There is a many-to-many relationship between local peers, remote peers, peer hosts, and subscriptions. Subscriptions are per user, rather than per process, per application, or per domain. Consequently, the subscriptions associated with a object are the list of contacts to which it has subscribed and from which it expects updates. Those contacts either have updated their own application, object, and presence information, or they have updated information regarding contacts in the . - - This property always returns `true` if the object is a which represents the local or "Me" contact, since a contact is always subscribed to itself. - + is not the same as a peer host. A peer host has an instance within the of the remote peer, and the relationship is that they have invited the peer to collaborate. An endpoint has a "Me" instance within its own contact manager and the peer host, but the relationship is not specified. + + If the peer host is in the , and the peer contact chooses not to , its can have a value of blocked, rather than deleting its entry from the host Contact Manager. + + There is a many-to-many relationship between local peers, remote peers, peer hosts, and subscriptions. Subscriptions are per user, rather than per process, per application, or per domain. Consequently, the subscriptions associated with a object are the list of contacts to which it has subscribed and from which it expects updates. Those contacts either have updated their own application, object, and presence information, or they have updated information regarding contacts in the . + + This property always returns `true` if the object is a which represents the local or "Me" contact, since a contact is always subscribed to itself. + ]]> This object has been disposed. @@ -1391,15 +1391,14 @@ System.String - Gets or sets a string which represents the of the . - - which represents the nickname of the . The default value for this property is . + Gets or sets the nickname of the . + The nickname of the . The default value for this property is . - object in case there are multiple peers with the same display name. A collaboration session can also use the nickname to designate remote peers commonly used in larger collaboration efforts. - + object in case there are multiple peers with the same display name. A collaboration session can also use the nickname to designate remote peers commonly used in larger collaboration efforts. + ]]> This object has been disposed. @@ -1435,11 +1434,11 @@ This event is signaled whenever a associated with the has changed. - of . This state is created when the peer collaboration session begins. - + of . This state is created when the peer collaboration session begins. + ]]> This object has been disposed. @@ -1471,13 +1470,13 @@ The object to be passed to delegates associated with the event. Raises the event. - @@ -1540,11 +1539,11 @@ The object to be passed to delegates associated with the event. Raises the event when the of a peer has changed. - or . - + or . + ]]> @@ -1575,11 +1574,11 @@ The or object associated with the event. Raises the event. - event occurs. - + event occurs. + ]]> @@ -1616,18 +1615,18 @@ Gets the associated with this . The collection associated with this . The default value for this property is . - is a local peer, remote peer, or host peer for the peer contact represented by this instance is not relevant to the presence of the in either the endpoint or the . - - - -## Examples - The following code example illustrates the proper usage of the property: - - :::code language="csharp" source="~/snippets/csharp/System.Net.PeerToPeer.Collaboration/ContactManager/Overview/NCLPNRPContacts.cs" id="Snippet7"::: - + is a local peer, remote peer, or host peer for the peer contact represented by this instance is not relevant to the presence of the in either the endpoint or the . + + + +## Examples + The following code example illustrates the proper usage of the property: + + :::code language="csharp" source="~/snippets/csharp/System.Net.PeerToPeer.Collaboration/ContactManager/Overview/NCLPNRPContacts.cs" id="Snippet7"::: + ]]> This object has been disposed. @@ -1656,11 +1655,11 @@ which represents the of the . Unless explicitly specified, the default value for all properties is for reference types. - . - + . + ]]> This object has been disposed. @@ -1721,15 +1720,15 @@ Subscribes the calling peer to the , and as a result, the peer will receive any future events associated with the . - updates occur asynchronously after the method has succeeded. As a result, it is possible for a to be added to the collection of a before the associated is provided. - - To monitor these changes, it is recommended that the user subscribe to the relevant events; for example, . - - Calling this method requires a of . This state is created when the peer collaboration session begins. - + updates occur asynchronously after the method has succeeded. As a result, it is possible for a to be added to the collection of a before the associated is provided. + + To monitor these changes, it is recommended that the user subscribe to the relevant events; for example, . + + Calling this method requires a of . This state is created when the peer collaboration session begins. + ]]> The calling peer is not signed in to People Near Me. @@ -1761,17 +1760,17 @@ enumeration value that specifies whether this is exposed to collaboration events belonging to the peer host or hosting application. Unless explicitly specified, the default value for all properties is for reference types. - means the remote peer specified by this can see the registered applications, objects and presence information for the user or application that owns the in which this object resides. - - This property has no effect on a instance that represents the local or "Me" contact, since a contact is always subscribed to itself. - + means the remote peer specified by this can see the registered applications, objects and presence information for the user or application that owns the in which this object resides. + + This property has no effect on a instance that represents the local or "Me" contact, since a contact is always subscribed to itself. + ]]> - This - + This + object has been disposed. @@ -1801,17 +1800,17 @@ A user-defined that contains information about the operation. Asynchronously subscribes the calling peer to the , and as a result, the peer will receive any future events associated with the . - event is raised upon completion of this operation. If collaboration activities are not required to be asynchronous, the method should be used instead. - - Calling this method requires a of . This state is created when the peer collaboration session begins. - + event is raised upon completion of this operation. If collaboration activities are not required to be asynchronous, the method should be used instead. + + Calling this method requires a of . This state is created when the peer collaboration session begins. + ]]> - cannot be . + cannot be . The calling peer is not signed in to People Near Me. The object has been disposed. Duplicate identifier. @@ -1839,13 +1838,13 @@ Raised when a subscription operation has completed. - object should be examined to determine whether the process completed successfully. - - Calling this method requires a of . This state is created when the peer collaboration session begins. - + object should be examined to determine whether the process completed successfully. + + Calling this method requires a of . This state is created when the peer collaboration session begins. + ]]> This object has been disposed. @@ -1967,13 +1966,13 @@ Removes a subscription to the and as a result the calling peer no longer receives events associated with the . - specified the result is a no-op. A calling peer can verify whether it is subscribed to events for the peer identified by this instance with the property. - - Calling this method requires a of . This state is created when the peer collaboration session begins. - + specified the result is a no-op. A calling peer can verify whether it is subscribed to events for the peer identified by this instance with the property. + + Calling this method requires a of . This state is created when the peer collaboration session begins. + ]]> This object has been disposed. diff --git a/xml/System.Net.Security/NegotiateStream.xml b/xml/System.Net.Security/NegotiateStream.xml index 06039a64968..13676d11884 100644 --- a/xml/System.Net.Security/NegotiateStream.xml +++ b/xml/System.Net.Security/NegotiateStream.xml @@ -2651,7 +2651,7 @@ The following method is called when the operation completes. is . - . + is less than 0. -or- @@ -4256,7 +4256,7 @@ This method reads asynchronously as much data as is available into `buffer` and is . - . + is less than 0. -or- @@ -4372,7 +4372,7 @@ This method reads asynchronously as much data as is available into `buffer` and is . - . + is less than 0. -or- diff --git a/xml/System.Net.Security/SslStream.xml b/xml/System.Net.Security/SslStream.xml index 11b0b111eb7..5a7efe57296 100644 --- a/xml/System.Net.Security/SslStream.xml +++ b/xml/System.Net.Security/SslStream.xml @@ -593,7 +593,7 @@ The property bag for the SSL connection. - Called by clients to authenticate the server and optionally the client in a client-server connection. + Authenticates the server and optionally the client in a client-server connection. - is . + is . The authentication failed and left this object in an unusable state. Authentication has already occurred. @@ -1180,7 +1180,7 @@ ]]> - is . + is . The authentication failed and left this object in an unusable state. Authentication has already occurred. @@ -1525,7 +1525,7 @@ The property bag for the SSL connection. The token to monitor for cancellation requests. - Called by servers to authenticate the server and optionally the client in a client-server connection as an asynchronous operation. The authentication process uses information specified in the property bag. + Authenticates the server and optionally the client in a client-server connection as an asynchronous operation. The authentication process uses information specified in the property bag. The task object representing the asynchronous operation. Contains option values for joining an IPv6 multicast group. - object. - + object. + :::code language="cpp" source="~/snippets/cpp/VS_Snippets_Remoting/System.Net.Sockets.UdpClient.JoinMulticastGroup/CPP/joinmulticastgroup.cpp" id="Snippet4"::: :::code language="csharp" source="~/snippets/csharp/System.Net.Sockets/IPv6MulticastOption/Overview/joinmulticastgroup.cs" id="Snippet4"::: - :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_Remoting/System.Net.Sockets.UdpClient.JoinMulticastGroup/VB/joinmulticastgroup.vb" id="Snippet4"::: - + :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_Remoting/System.Net.Sockets.UdpClient.JoinMulticastGroup/VB/joinmulticastgroup.vb" id="Snippet4"::: + ]]> @@ -111,15 +111,15 @@ The of the multicast group. Initializes a new version of the class for the specified IP multicast group. - object. - + object. + :::code language="cpp" source="~/snippets/cpp/VS_Snippets_Remoting/System.Net.Sockets.UdpClient.JoinMulticastGroup/CPP/joinmulticastgroup.cpp" id="Snippet4"::: :::code language="csharp" source="~/snippets/csharp/System.Net.Sockets/IPv6MulticastOption/Overview/joinmulticastgroup.cs" id="Snippet4"::: - :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_Remoting/System.Net.Sockets.UdpClient.JoinMulticastGroup/VB/joinmulticastgroup.vb" id="Snippet4"::: - + :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_Remoting/System.Net.Sockets.UdpClient.JoinMulticastGroup/VB/joinmulticastgroup.vb" id="Snippet4"::: + ]]> @@ -167,27 +167,27 @@ The local interface address. Initializes a new instance of the class with the specified IP multicast group and the local interface address. - object. - + object. + :::code language="cpp" source="~/snippets/cpp/VS_Snippets_Remoting/System.Net.Sockets.UdpClient.JoinMulticastGroup/CPP/joinmulticastgroup.cpp" id="Snippet5"::: :::code language="csharp" source="~/snippets/csharp/System.Net.Sockets/IPv6MulticastOption/Overview/joinmulticastgroup.cs" id="Snippet5"::: - :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_Remoting/System.Net.Sockets.UdpClient.JoinMulticastGroup/VB/joinmulticastgroup.vb" id="Snippet5"::: - + :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_Remoting/System.Net.Sockets.UdpClient.JoinMulticastGroup/VB/joinmulticastgroup.vb" id="Snippet5"::: + ]]> - is less than 0. - - -or- - + is less than 0. + + -or- + is greater than 0x00000000FFFFFFFF. is . @@ -238,19 +238,19 @@ Gets or sets the IP address of a multicast group. An that contains the Internet address of a multicast group. - object. - + object. + :::code language="cpp" source="~/snippets/cpp/VS_Snippets_Remoting/System.Net.Sockets.UdpClient.JoinMulticastGroup/CPP/joinmulticastgroup.cpp" id="Snippet4"::: :::code language="csharp" source="~/snippets/csharp/System.Net.Sockets/IPv6MulticastOption/Overview/joinmulticastgroup.cs" id="Snippet4"::: - :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_Remoting/System.Net.Sockets.UdpClient.JoinMulticastGroup/VB/joinmulticastgroup.vb" id="Snippet4"::: - + :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_Remoting/System.Net.Sockets.UdpClient.JoinMulticastGroup/VB/joinmulticastgroup.vb" id="Snippet4"::: + ]]> - is . + The value to set is . @@ -298,20 +298,20 @@ Gets or sets the interface index that is associated with a multicast group. A value that specifies the address of the interface. - object. - + object. + :::code language="cpp" source="~/snippets/cpp/VS_Snippets_Remoting/System.Net.Sockets.UdpClient.JoinMulticastGroup/CPP/joinmulticastgroup.cpp" id="Snippet4"::: :::code language="csharp" source="~/snippets/csharp/System.Net.Sockets/IPv6MulticastOption/Overview/joinmulticastgroup.cs" id="Snippet4"::: - :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_Remoting/System.Net.Sockets.UdpClient.JoinMulticastGroup/VB/joinmulticastgroup.vb" id="Snippet4"::: - + :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_Remoting/System.Net.Sockets.UdpClient.JoinMulticastGroup/VB/joinmulticastgroup.vb" id="Snippet4"::: + ]]> The value that is specified for a set operation is less than 0 or greater than 0x00000000FFFFFFFF. diff --git a/xml/System.Net.Sockets/MulticastOption.xml b/xml/System.Net.Sockets/MulticastOption.xml index e4765e4a329..48df6342968 100644 --- a/xml/System.Net.Sockets/MulticastOption.xml +++ b/xml/System.Net.Sockets/MulticastOption.xml @@ -49,30 +49,30 @@ Contains values used to join and drop multicast groups. - to store the of a multicast group you want to join or drop. Use the method with the following parameters to join a multicast group. - -|Parameter|Value| -|---------------|-----------| -|socketOptionLevel|| -|socketOptionName|| -|object|| - + to store the of a multicast group you want to join or drop. Use the method with the following parameters to join a multicast group. + +|Parameter|Value| +|---------------|-----------| +|socketOptionLevel|| +|socketOptionName|| +|object|| + Use to drop a multicast group. - -## Examples - The following examples join the default IP interface to an IP multicast group. They assume the IP multicast group address in the range 224.0.0.0 to 239.255.255.255. - + +## Examples + The following examples join the default IP interface to an IP multicast group. They assume the IP multicast group address in the range 224.0.0.0 to 239.255.255.255. + :::code language="cpp" source="~/snippets/cpp/VS_Snippets_Remoting/System.Net.Sockets.MulticastOptionListener/CPP/listener.cpp" id="Snippet1"::: :::code language="csharp" source="~/snippets/csharp/System.Net.Sockets/MulticastOption/Overview/listener.cs" id="Snippet1"::: - :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_Remoting/System.Net.Sockets.MulticastOptionListener/VB/listener.vb" id="Snippet1"::: - + :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_Remoting/System.Net.Sockets.MulticastOptionListener/VB/listener.vb" id="Snippet1"::: + :::code language="cpp" source="~/snippets/cpp/VS_Snippets_Remoting/System.Net.Sockets.MulticastOptionSender/CPP/sender.cpp" id="Snippet1"::: :::code language="csharp" source="~/snippets/csharp/System.Net.Sockets/MulticastOption/Overview/sender.cs" id="Snippet1"::: - :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_Remoting/System.Net.Sockets.MulticastOptionSender/VB/sender.vb" id="Snippet1"::: - + :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_Remoting/System.Net.Sockets.MulticastOptionSender/VB/sender.vb" id="Snippet1"::: + ]]> @@ -126,11 +126,11 @@ The IP address of the multicast group. Initializes a new version of the class for the specified IP multicast group. - @@ -220,25 +220,25 @@ The local IP address. Initializes a new instance of the class with the specified IP multicast group address and local IP address associated with a network interface. - instances. - -## Examples - The following example creates a object. - + +## Examples + The following example creates a object. + :::code language="cpp" source="~/snippets/cpp/VS_Snippets_Remoting/System.Net.Sockets.MulticastOptionListener/CPP/listener.cpp" id="Snippet2"::: :::code language="csharp" source="~/snippets/csharp/System.Net.Sockets/MulticastOption/Overview/listener.cs" id="Snippet2"::: - :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_Remoting/System.Net.Sockets.MulticastOptionListener/VB/listener.vb" id="Snippet2"::: - + :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_Remoting/System.Net.Sockets.MulticastOptionListener/VB/listener.vb" id="Snippet2"::: + ]]> - is . - - -or- - + is . + + -or- + is . @@ -291,22 +291,22 @@ Gets or sets the IP address of a multicast group. The IP address of a multicast group. - - .NET 5 and later versions: is . + .NET 5 and later versions: The value to set is . @@ -405,18 +405,18 @@ Gets or sets the local address associated with a multicast group. The local address associated with a multicast group. - property contains the IP address of the interface associated with the multicast group membership. If is set to , the default interface is used. - -## Examples - The following example displays the value of this property. - + +## Examples + The following example displays the value of this property. + :::code language="cpp" source="~/snippets/cpp/VS_Snippets_Remoting/System.Net.Sockets.MulticastOptionListener/CPP/listener.cpp" id="Snippet3"::: :::code language="csharp" source="~/snippets/csharp/System.Net.Sockets/MulticastOption/Overview/listener.cs" id="Snippet3"::: - :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_Remoting/System.Net.Sockets.MulticastOptionListener/VB/listener.vb" id="Snippet3"::: - + :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_Remoting/System.Net.Sockets.MulticastOptionListener/VB/listener.vb" id="Snippet3"::: + ]]> diff --git a/xml/System.Net.Sockets/Socket.xml b/xml/System.Net.Sockets/Socket.xml index bbf47cf7eb2..ff09022bc8b 100644 --- a/xml/System.Net.Sockets/Socket.xml +++ b/xml/System.Net.Sockets/Socket.xml @@ -452,9 +452,7 @@ This method populates the instance with data ga This method stores in the task it returns all non-usage exceptions that the method's synchronous counterpart can throw. If an exception is stored into the returned task, that exception will be thrown when the task is awaited. Usage exceptions, such as , are still thrown synchronously. For the stored exceptions, see the exceptions thrown by . An invalid operation was requested. This exception occurs if the accepting is not listening for connections or the accepted socket is bound. - You must call the and method before calling the method. - - This exception also occurs if the socket is already connected or a socket operation was already in progress using the specified parameter. + You must call the and method before calling the method. An error occurred when attempting to access the socket. The has been closed. @@ -503,9 +501,7 @@ This method populates the instance with data ga To be added. An invalid operation was requested. This exception occurs if the accepting is not listening for connections or the accepted socket is bound. - You must call the and method before calling the method. - - This exception also occurs if the socket is already connected or a socket operation was already in progress using the specified parameter. + You must call the and method before calling the method. An error occurred when attempting to access the socket. The has been closed. @@ -584,7 +580,7 @@ This method populates the instance with data ga ]]> - An argument is not valid. This exception occurs if the buffer provided is not large enough. The buffer must be at least 2 * (sizeof(SOCKADDR_STORAGE + 16) bytes. + An argument is not valid. This exception occurs if the buffer provided is not large enough. The buffer must be at least 2 * (sizeof(SOCKADDR_STORAGE + 16)) bytes. This exception also occurs if multiple buffers are specified, the property is not null. An argument is out of range. The exception occurs if the is less than 0. @@ -640,9 +636,7 @@ This method populates the instance with data ga This method stores in the task it returns all non-usage exceptions that the method's synchronous counterpart can throw. If an exception is stored into the returned task, that exception will be thrown when the task is awaited. Usage exceptions, such as , are still thrown synchronously. For the stored exceptions, see the exceptions thrown by . An invalid operation was requested. This exception occurs if the accepting is not listening for connections or the accepted socket is bound. - You must call the and method before calling the method. - - This exception also occurs if the socket is already connected or a socket operation was already in progress using the specified parameter. + You must call the and method before calling the method. An error occurred when attempting to access the socket. The has been closed. The cancellation token was canceled. This exception is stored into the returned task. @@ -687,9 +681,7 @@ This method populates the instance with data ga To be added. An invalid operation was requested. This exception occurs if the accepting is not listening for connections or the accepted socket is bound. - You must call the and method before calling the method. - - This exception also occurs if the socket is already connected or a socket operation was already in progress using the specified parameter. + You must call the and method before calling the method. An error occurred when attempting to access the socket. The has been closed. The cancellation token was canceled. This exception is stored into the returned task. @@ -924,8 +916,6 @@ This method populates the instance with data ga -or- The accepted socket is bound. - - is less than 0. .NET Framework and .NET 5 and earlier only: An error occurred when attempting to access the socket. @@ -1468,7 +1458,7 @@ This method populates the instance with data ga The has been closed. This method is valid for sockets that use or . The port number is not valid. - The length of is zero. + The length of is zero. The has been placed in a listening state by calling , or an asynchronous operation is already in progress. @@ -1763,7 +1753,7 @@ This method populates the instance with data ga ]]> - is . + is . .NET Framework and .NET 5 and earlier only: An error occurred when attempting to access the socket. has been closed. @@ -1866,7 +1856,7 @@ This method populates the instance with data ga ]]> - is . + is . .NET Framework and .NET 5 and earlier only: An error occurred when attempting to access the socket. has been closed. @@ -3712,8 +3702,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 .NET Framework](/dotnet/framework/network-programming/network-tracing). - - ## Examples The following code example connects to a remote endpoint and then verifies the connection. @@ -3810,7 +3798,7 @@ This method populates the instance with data ga An error occurred when attempting to access the socket. The has been closed. The socket is not in the or families. - The length of is zero. + The length of is zero. The has been placed in a listening state by calling . @@ -5057,7 +5045,7 @@ On .NET 5+, has .NET Core on any OS and .NET 5+ on Unix-based OS only: The current platform is not supported. - is not a valid process id. + is not a valid process id. -or- @@ -7876,7 +7864,7 @@ The maximum length of the pending connections queue is determined automatically. ]]> - The parameter is . + The parameter is . An error occurred while attempting to access the socket. The has been closed. diff --git a/xml/System.Net.Sockets/SocketTaskExtensions.xml b/xml/System.Net.Sockets/SocketTaskExtensions.xml index c37fd0bd677..7478d4a667c 100644 --- a/xml/System.Net.Sockets/SocketTaskExtensions.xml +++ b/xml/System.Net.Sockets/SocketTaskExtensions.xml @@ -330,10 +330,10 @@ To be added. The parameter cannot be null. - is less than . - - -or- - + is less than . + + -or- + is greater than . The is listening. An error occurred when attempting to access the socket. @@ -395,10 +395,10 @@ The parameter cannot be null. The parameter cannot be empty array. - is less than . - - -or- - + is less than . + + -or- + is greater than . The is listening. An error occurred when attempting to access the socket. @@ -459,10 +459,10 @@ To be added. The parameter cannot be null. - is less than . - - -or- - + is less than . + + -or- + is greater than . The is listening. An error occurred when attempting to access the socket. @@ -514,10 +514,10 @@ To be added. The parameter cannot be null. - is less than . - - -or- - + is less than . + + -or- + is greater than . The is listening. An error occurred when attempting to access the socket. @@ -571,10 +571,10 @@ The parameter cannot be null. The parameter cannot be empty array. - is less than . - - -or- - + is less than . + + -or- + is greater than . The is listening. An error occurred when attempting to access the socket. @@ -627,10 +627,10 @@ To be added. The parameter cannot be null. - is less than . - - -or- - + is less than . + + -or- + is greater than . The is listening. An error occurred when attempting to access the socket. @@ -885,7 +885,7 @@ -or- - is . + is . An error occurred when attempting to access the socket. The has been closed. A caller in the call stack does not have the required permissions. diff --git a/xml/System.Net.Sockets/TcpClient.xml b/xml/System.Net.Sockets/TcpClient.xml index 8fe495242c4..8dd17ffcd0d 100644 --- a/xml/System.Net.Sockets/TcpClient.xml +++ b/xml/System.Net.Sockets/TcpClient.xml @@ -944,7 +944,7 @@ The `Available` property is a way to determine whether data is queued for readin ]]> - The parameter is . + The parameter is . An error occurred when accessing the socket. The is closed. @@ -1371,7 +1371,7 @@ The `Available` property is a way to determine whether data is queued for readin ]]> - The parameter is . + The parameter is . The port number is not valid. An error occurred when attempting to access the socket. The has been closed. @@ -1622,7 +1622,7 @@ The `Available` property is a way to determine whether data is queued for readin ]]> - The parameter is . + The parameter is . The port number is not valid. An error occurred when attempting to access the socket. The has been closed. diff --git a/xml/System.Net.Sockets/UdpClient.xml b/xml/System.Net.Sockets/UdpClient.xml index 2a64107e051..75840802752 100644 --- a/xml/System.Net.Sockets/UdpClient.xml +++ b/xml/System.Net.Sockets/UdpClient.xml @@ -2942,7 +2942,7 @@ ]]> - is . + is . The has already established a default remote host. The is closed. An error occurred when accessing the socket. @@ -3051,7 +3051,7 @@ ]]> - is . + is . has already established a default remote host. @@ -3175,7 +3175,7 @@ ]]> - is . + is . The has already established a default remote host. The is closed. An error occurred when accessing the socket. diff --git a/xml/System.Net/CookieContainer.xml b/xml/System.Net/CookieContainer.xml index 0e9c24d9ac9..f5d9f7920aa 100644 --- a/xml/System.Net/CookieContainer.xml +++ b/xml/System.Net/CookieContainer.xml @@ -262,7 +262,7 @@ and - is less than or equal to zero or is greater than . + is less than or equal to zero or greater than . is less than or equal to zero. @@ -616,7 +616,7 @@ ]]> - is less than or equal to zero or (value is less than and is not equal to Int32.MaxValue). + The capacity to set is less than or equal to zero or (value is less than and is not equal to Int32.MaxValue). @@ -1080,7 +1080,7 @@ ]]> - is less than or equal to zero. + The size to set is less than or equal to zero. @@ -1144,16 +1144,16 @@ value is less than the current value, and if any of the domain collections contain more instances than the new value, the collections are pruned to fit. This uses the same basic rules as described in the property. However, this does the clean-up only on the collection for this domain. + If the new value is less than the current value, and if any of the domain collections contain more instances than the new value, the collections are pruned to fit. This uses the same basic rules as described in the property. However, this does the cleanup only on the collection for this domain. ]]> - is less than or equal to zero. + The value to set is less than or equal to zero. -or- - is greater than the maximum allowable number of cookies instances, 300, and is not equal to Int32.MaxValue). + The value to set is greater than the maximum allowable number of cookies instances, 300, and is not equal to Int32.MaxValue. diff --git a/xml/System.Net/CredentialCache.xml b/xml/System.Net/CredentialCache.xml index dde5b2509e3..aad27f195ee 100644 --- a/xml/System.Net/CredentialCache.xml +++ b/xml/System.Net/CredentialCache.xml @@ -67,22 +67,22 @@ Provides storage for multiple credentials. - class stores credentials for multiple Internet resources. Applications that need to access multiple resources can store the credentials for those resources in a instance that then provides the proper set of credentials to the Internet resource when required. When the method is called, it compares the Uniform Resource Identifier (URI) and authentication type provided with those stored in the cache and returns the first set of credentials that match. - - The property contains the system credentials of the current security context. For client applications, these represent the user name, password, and domain of the user who is currently logged in. For ASP.NET applications, the default credentials are the user credentials of the logged-in user or the user being impersonated. - - - -## Examples - The following code example initializes a with multiple security credentials and uses those credentials with a . - + class stores credentials for multiple Internet resources. Applications that need to access multiple resources can store the credentials for those resources in a instance that then provides the proper set of credentials to the Internet resource when required. When the method is called, it compares the Uniform Resource Identifier (URI) and authentication type provided with those stored in the cache and returns the first set of credentials that match. + + The property contains the system credentials of the current security context. For client applications, these represent the user name, password, and domain of the user who is currently logged in. For ASP.NET applications, the default credentials are the user credentials of the logged-in user or the user being impersonated. + + + +## Examples + The following code example initializes a with multiple security credentials and uses those credentials with a . + :::code language="cpp" source="~/snippets/cpp/VS_Snippets_Remoting/Classic CredentialCache.Add Example/CPP/source.cpp" id="Snippet1"::: :::code language="csharp" source="~/snippets/csharp/System.Net/CredentialCache/Overview/source.cs" id="Snippet1"::: - :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_Remoting/Classic CredentialCache.Add Example/VB/source.vb" id="Snippet1"::: - + :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_Remoting/Classic CredentialCache.Add Example/VB/source.vb" id="Snippet1"::: + ]]> @@ -125,20 +125,20 @@ Creates a new instance of the class. - instance. - - - -## Examples - The following code example initializes a with multiple security credentials and uses those credentials with a . - + instance. + + + +## Examples + The following code example initializes a with multiple security credentials and uses those credentials with a . + :::code language="cpp" source="~/snippets/cpp/VS_Snippets_Remoting/Classic CredentialCache.Add Example/CPP/source.cpp" id="Snippet1"::: :::code language="csharp" source="~/snippets/csharp/System.Net/CredentialCache/Overview/source.cs" id="Snippet1"::: - :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_Remoting/Classic CredentialCache.Add Example/VB/source.vb" id="Snippet1"::: - + :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_Remoting/Classic CredentialCache.Add Example/VB/source.vb" id="Snippet1"::: + ]]> @@ -201,27 +201,25 @@ The to add to the credential cache. Adds a instance to the credential cache for use with protocols other than SMTP and associates it with a Uniform Resource Identifier (URI) prefix and authentication protocol. - method places a instance for use with protocols other than SMTP into the . The cache stores credentials in the order in which they are added to it. When the method is called, it returns the proper matching instance. - - - -## Examples - The following code example initializes a with multiple security credentials and uses those credentials with a . - + method places a instance for use with protocols other than SMTP into the . The cache stores credentials in the order in which they are added to it. When the method is called, it returns the proper matching instance. + +## Examples + The following code example initializes a with multiple security credentials and uses those credentials with a . + :::code language="cpp" source="~/snippets/cpp/VS_Snippets_Remoting/Classic CredentialCache.Add Example/CPP/source.cpp" id="Snippet1"::: :::code language="csharp" source="~/snippets/csharp/System.Net/CredentialCache/Overview/source.cs" id="Snippet1"::: - :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_Remoting/Classic CredentialCache.Add Example/VB/source.vb" id="Snippet1"::: - + :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_Remoting/Classic CredentialCache.Add Example/VB/source.vb" id="Snippet1"::: + ]]> - is . - - -or- - + is . + + -or- + is . The same credentials are added more than once. @@ -270,38 +268,36 @@ A that identifies the host computer. A that specifies the port to connect to on . - A that identifies the authentication scheme used when connecting to using . + A that identifies the authentication scheme used when connecting to using . The to add to the credential cache. Adds a instance for use with SMTP to the credential cache and associates it with a host computer, port, and authentication protocol. Credentials added using this method are valid for SMTP only. This method does not work for HTTP or FTP requests. - instance for use with SMTP into the . The cache stores credentials in the order in which they are added to it. When the method is called, it returns a instance that is selected by matching the `host`, `port`, and `authType`. The comparison is done case-insensitively. - - The supported values for `authType` are "NTLM", "Digest", "Kerberos", and "Negotiate". - - Credentials added with this method are only valid for use with SMTP. This method does not work for HTTP or FTP protocols. - - - -## Examples - The following code example initializes a with multiple security credentials for use with SMTP and uses one of those credentials with a . - + instance for use with SMTP into the . The cache stores credentials in the order in which they are added to it. When the method is called, it returns a instance that is selected by matching the `host`, `port`, and `authenticationType`. The comparison is done case-insensitively. + + The supported values for `authenticationType` are "NTLM", "Digest", "Kerberos", and "Negotiate". + + Credentials added with this method are only valid for use with SMTP. This method does not work for HTTP or FTP protocols. + +## Examples + The following code example initializes a with multiple security credentials for use with SMTP and uses one of those credentials with a . + :::code language="cpp" source="~/snippets/cpp/VS_Snippets_Remoting/NCL_Credential.Cache.Add_SMTP/CPP/source.cpp" id="Snippet1"::: :::code language="csharp" source="~/snippets/csharp/System.Net/CredentialCache/Add/source.cs" id="Snippet1"::: - :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_Remoting/NCL_Credential.Cache.Add_SMTP/VB/source.vb" id="Snippet1"::: - + :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_Remoting/NCL_Credential.Cache.Add_SMTP/VB/source.vb" id="Snippet1"::: + ]]> - is . - - -or- - - is . + is . + + -or- + + is . - not an accepted value. + not an accepted value. is less than zero. @@ -346,29 +342,25 @@ Gets the system credentials of the application. An that represents the system credentials of the application. - property applies only to NTLM, negotiate, and Kerberos-based authentication. - - represents the system credentials for the current security context in which the application is running. For a client-side application, these are usually the Windows credentials (user name, password, and domain) of the user running the application. For ASP.NET applications, the default credentials are the user credentials of the logged-in user, or the user being impersonated. - - To get the credentials as a instance, use the property. - - The supported values for `authType` are "NTLM", "Digest", "Kerberos", and "Negotiate". This method does not work for HTTP or FTP protocols. - + property applies only to NTLM, negotiate, and Kerberos-based authentication. + + represents the system credentials for the current security context in which the application is running. For a client-side application, these are usually the Windows credentials (user name, password, and domain) of the user running the application. For ASP.NET applications, the default credentials are the user credentials of the logged-in user, or the user being impersonated. + + To get the credentials as a instance, use the property. + > [!NOTE] -> The instance returned by cannot be used to view the user name, password, or domain of the current security context. - - - -## Examples - The following code example uses the property to get the system credentials of the application. - +> The instance returned by cannot be used to view the user name, password, or domain of the current security context. + +## Examples + The following code example uses the property to get the system credentials of the application. + :::code language="cpp" source="~/snippets/cpp/VS_Snippets_Remoting/CredentialCache_DefaultCredentials/CPP/credentialcache_defaultcredentials.cpp" id="Snippet1"::: :::code language="csharp" source="~/snippets/csharp/System.Net/CredentialCache/DefaultCredentials/credentialcache_defaultcredentials.cs" id="Snippet1"::: - :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_Remoting/CredentialCache_DefaultCredentials/VB/credentialcache_defaultcredentials.vb" id="Snippet1"::: - + :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_Remoting/CredentialCache_DefaultCredentials/VB/credentialcache_defaultcredentials.vb" id="Snippet1"::: + ]]> @@ -412,13 +404,13 @@ Gets the network credentials of the current security context. An that represents the network credentials of the current user or application. - property is applicable only for NTLM, negotiate, and Kerberos-based authentication. - - The credentials returned by represents the authentication credentials for the current security context in which the application is running. For a client-side application, these are usually the Windows credentials (user name, password, and domain) of the user running the application. For ASP.NET applications, the default network credentials are the user credentials of the logged-in user, or the user being impersonated. - + property is applicable only for NTLM, negotiate, and Kerberos-based authentication. + + The credentials returned by represents the authentication credentials for the current security context in which the application is running. For a client-side application, these are usually the Windows credentials (user name, password, and domain) of the user running the application. For ASP.NET applications, the default network credentials are the user credentials of the logged-in user, or the user being impersonated. + ]]> @@ -484,28 +476,26 @@ Returns the instance associated with the specified Uniform Resource Identifier (URI) and authentication type. A or, if there is no matching credential in the cache, . - method searches the and returns the instance for the specified URI and authorization type. If the contains no matching instance, `null` is returned. - - uses the longest matching URI prefix in the cache to determine which set of credentials to return for an authorization type. The following table shows examples. - -|URI Prefix|Matches| -|----------------|-------------| -|`http://www.contoso.com/portal/news.htm`|Requests for the specific Web page `news.htm`.| -|`http://www.contoso.com/portal/`|Requests for all content in the `portal` path, except the page `news.htm`.| -|`http://www.contoso.com/`|Requests for all resources at `www.contoso.com`, except those in the `portal` path.| - - - -## Examples - The following code example uses the method to return the instance associated with the specified URI and authentication type. - + method searches the and returns the instance for the specified URI and authorization type. If the contains no matching instance, `null` is returned. + + uses the longest matching URI prefix in the cache to determine which set of credentials to return for an authorization type. The following table shows examples. + +|URI Prefix|Matches| +|----------------|-------------| +|`http://www.contoso.com/portal/news.htm`|Requests for the specific Web page `news.htm`.| +|`http://www.contoso.com/portal/`|Requests for all content in the `portal` path, except the page `news.htm`.| +|`http://www.contoso.com/`|Requests for all resources at `www.contoso.com`, except those in the `portal` path.| + +## Examples + The following code example uses the method to return the instance associated with the specified URI and authentication type. + :::code language="cpp" source="~/snippets/cpp/VS_Snippets_Remoting/CredentialCache_GetCredential/CPP/credentialcache_getcredential.cpp" id="Snippet1"::: :::code language="csharp" source="~/snippets/csharp/System.Net/CredentialCache/GetCredential/credentialcache_getcredential.cs" id="Snippet1"::: - :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_Remoting/CredentialCache_GetCredential/VB/credentialcache_getcredential.vb" id="Snippet1"::: - + :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_Remoting/CredentialCache_GetCredential/VB/credentialcache_getcredential.vb" id="Snippet1"::: + ]]> @@ -563,26 +553,26 @@ Returns the instance associated with the specified host, port, and authentication protocol. A or, if there is no matching credential in the cache, . - and returns the instance for the specified host, port, and authorization type. The `host`, `port`, and `authType` values passed to this method are case-insensitively compared to the values specified when the credential was added to the using the methods. - - The supported values for `authType` are "NTLM", "Digest", "Kerberos", and "Negotiate". - + and returns the instance for the specified host, port, and authorization type. The `host`, `port`, and `authenticationType` values passed to this method are case-insensitively compared to the values specified when the credential was added to the using the methods. + + The supported values for `authenticationType` are "NTLM", "Digest", "Kerberos", and "Negotiate". + ]]> - is . - - -or- - - is . + is . + + -or- + + is . - not an accepted value. - - -or- - + not an accepted value. + + -or- + is equal to the empty string (""). is less than zero. @@ -632,15 +622,15 @@ Returns an enumerator that can iterate through the instance. An for the . - method to return an enumerator that can iterate through the instance. - + method to return an enumerator that can iterate through the instance. + :::code language="cpp" source="~/snippets/cpp/VS_Snippets_Remoting/CredentialCache_GetEnumerator/CPP/credentialcache_getenumerator.cpp" id="Snippet1"::: :::code language="csharp" source="~/snippets/csharp/System.Net/CredentialCache/GetEnumerator/credentialcache_getenumerator.cs" id="Snippet1"::: - :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_Remoting/CredentialCache_GetEnumerator/VB/credentialcache_getenumerator.vb" id="Snippet1"::: - + :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_Remoting/CredentialCache_GetEnumerator/VB/credentialcache_getenumerator.vb" id="Snippet1"::: + ]]> @@ -702,22 +692,20 @@ The authentication scheme used by the host named in . Deletes a instance from the cache if it is associated with the specified Uniform Resource Identifier (URI) prefix and authentication protocol. - instance from the if the specified URI prefix and authentication protocol match those associated with the credential. Multiple calls to the method for the same have no effect. - - If `authType` is `null` or `uriPrefix` is `null`, or no matching credential is found in the cache, this method does nothing. - - - -## Examples - The following code example uses this method to delete a instance from the cache. - + instance from the if the specified URI prefix and authentication protocol match those associated with the credential. Multiple calls to the method for the same have no effect. + + If `authType` is `null` or `uriPrefix` is `null`, or no matching credential is found in the cache, this method does nothing. + +## Examples + The following code example uses this method to delete a instance from the cache. + :::code language="cpp" source="~/snippets/cpp/VS_Snippets_Remoting/CredentialCache_Add_Remove/CPP/credentialcache_add_remove.cpp" id="Snippet3"::: :::code language="csharp" source="~/snippets/csharp/System.Net/CredentialCache/Remove/credentialcache_add_remove.cs" id="Snippet3"::: - :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_Remoting/CredentialCache_Add_Remove/VB/credentialcache_add_remove.vb" id="Snippet3"::: - + :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_Remoting/CredentialCache_Add_Remove/VB/credentialcache_add_remove.vb" id="Snippet3"::: + ]]> @@ -769,13 +757,13 @@ A that identifies the authentication scheme used when connecting to . Deletes a instance from the cache if it is associated with the specified host, port, and authentication protocol. - instance from the if the specified host, port, and authentication protocol match those associated with the credential. Multiple calls to the method for the same have no effect. - - If `authType` is `null` or `uriPrefix` is `null`, or no matching credential is found in the cache, this method does nothing. - + instance from the if the specified host, port, and authentication protocol match those associated with the credential. Multiple calls to the method for the same have no effect. + + If `authenticationType` is `null` or `uriPrefix` is `null`, or no matching credential is found in the cache, this method does nothing. + ]]> diff --git a/xml/System.Net/HttpListenerRequest.xml b/xml/System.Net/HttpListenerRequest.xml index 221229dbbe5..35804309fa3 100644 --- a/xml/System.Net/HttpListenerRequest.xml +++ b/xml/System.Net/HttpListenerRequest.xml @@ -535,7 +535,7 @@ is . - was not obtained by calling . + was not obtained by calling . This method was already called for the operation identified by . diff --git a/xml/System.Net/HttpWebRequest.xml b/xml/System.Net/HttpWebRequest.xml index 9a2af865a94..5c571520745 100644 --- a/xml/System.Net/HttpWebRequest.xml +++ b/xml/System.Net/HttpWebRequest.xml @@ -521,8 +521,6 @@ Both constructors are obsolete and should not b When receiving the response from a range request, only the HTTP headers associated with the entire request are parsed and made available via properties on the class. Headers associated with each range are returned in the response. - - ## Examples The following code example adds a range header to the request. @@ -533,7 +531,7 @@ Both constructors are obsolete and should not b ]]> - is invalid. + is invalid. The range header could not be added. @@ -621,7 +619,7 @@ Both constructors are obsolete and should not b ]]> - is invalid. + is invalid. The range header could not be added. @@ -700,8 +698,6 @@ Both constructors are obsolete and should not b When receiving the response from a range request, only the HTTP headers associated with the entire request are parsed and made available via properties on the class. Headers associated with each range are returned in the response. - - ## Examples The following code example adds a range header to the request. @@ -711,8 +707,6 @@ Both constructors are obsolete and should not b ]]> - - is invalid. is greater than @@ -803,8 +797,6 @@ Both constructors are obsolete and should not b ]]> - - is invalid. is greater than diff --git a/xml/System.Net/IPAddress.xml b/xml/System.Net/IPAddress.xml index 5a843e77566..edb473ab637 100644 --- a/xml/System.Net/IPAddress.xml +++ b/xml/System.Net/IPAddress.xml @@ -2165,8 +2165,6 @@ The notation that is used to specify the `ScopeId` with an address is `Address%ScopeId`. For example, `FE80::5EFE:192.168.41.30%2.` - - ## Examples :::code language="cpp" source="~/snippets/cpp/VS_Snippets_Remoting/System.Net.IPAddress/CPP/ipaddress.cpp" id="Snippet3"::: :::code language="csharp" source="~/snippets/csharp/System.Net/IPAddress/Overview/ipaddress.cs" id="Snippet3"::: @@ -2176,12 +2174,11 @@ = . - - < 0 + The scope identifier is < 0 -or- - > 0x00000000FFFFFFFF +The scope identifier is > 0x00000000FFFFFFFF diff --git a/xml/System.Net/SocketAddress.xml b/xml/System.Net/SocketAddress.xml index f44bf53abb2..863255517a1 100644 --- a/xml/System.Net/SocketAddress.xml +++ b/xml/System.Net/SocketAddress.xml @@ -56,20 +56,20 @@ Stores serialized information from derived classes. - enumerated value. When the is used to store a serialized , the third and fourth bytes are used to store port number information. The next bytes are used to store the IP address. You can access any information within this underlying byte buffer by referring to its index position; the byte buffer uses zero-based indexing. You can also use the and properties to get the value and the buffer size, respectively. To view any of this information as a string, use the method. - - - -## Examples - The following example demonstrates how to use to serialize an instance of the class. After serialization, the underlying byte buffer of the contains all of the state information. - - :::code language="cpp" source="~/snippets/cpp/VS_Snippets_Remoting/Classic SocketAddressExample/CPP/source.cpp" id="Snippet1"::: - :::code language="csharp" source="~/snippets/csharp/System.Net/SocketAddress/Overview/source.cs" id="Snippet1"::: - :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_Remoting/Classic SocketAddressExample/VB/source.vb" id="Snippet1"::: - + enumerated value. When the is used to store a serialized , the third and fourth bytes are used to store port number information. The next bytes are used to store the IP address. You can access any information within this underlying byte buffer by referring to its index position; the byte buffer uses zero-based indexing. You can also use the and properties to get the value and the buffer size, respectively. To view any of this information as a string, use the method. + + + +## Examples + The following example demonstrates how to use to serialize an instance of the class. After serialization, the underlying byte buffer of the contains all of the state information. + + :::code language="cpp" source="~/snippets/cpp/VS_Snippets_Remoting/Classic SocketAddressExample/CPP/source.cpp" id="Snippet1"::: + :::code language="csharp" source="~/snippets/csharp/System.Net/SocketAddress/Overview/source.cs" id="Snippet1"::: + :::code language="vb" source="~/snippets/visualbasic/VS_Snippets_Remoting/Classic SocketAddressExample/VB/source.vb" id="Snippet1"::: + ]]> @@ -132,11 +132,11 @@ An enumerated value. Creates a new instance of the class for the given address family. - @@ -185,11 +185,11 @@ The number of bytes to allocate for the underlying buffer. Creates a new instance of the class using the specified address family and buffer size. - class with a particular underlying buffer size. - + class with a particular underlying buffer size. + ]]> @@ -262,7 +262,7 @@ The object to compare. Indicates whether the current object is equal to another object of the same type. - if the current object is equal to the parameter; otherwise, . + if the current object is equal to the parameter; otherwise, . To be added. @@ -359,11 +359,11 @@ Gets the enumerated value of the current . One of the enumerated values. - enumerated value that represents the addressing scheme of the current . If you want to view the corresponding string representation of , use the method. - + enumerated value that represents the addressing scheme of the current . If you want to view the corresponding string representation of , use the method. + ]]> @@ -496,14 +496,14 @@ Gets or sets the specified index element in the underlying buffer. The value of the specified index element in the underlying buffer. - [!NOTE] -> Be sure to call before referring to elements in the underlying buffer. Referring to an index that does not exist will cause the to throw an . - + [!NOTE] +> Be sure to call before referring to elements in the underlying buffer. Referring to an index that does not exist will cause the to throw an . + ]]> The specified index does not exist in the buffer. @@ -562,11 +562,11 @@ Gets the underlying buffer size of the . The underlying buffer size of the . - in bytes. - + in bytes. + ]]> @@ -614,11 +614,11 @@ Returns information about the socket address. A string that contains information about the . - method returns a string that contains the enumerated value, the size of the underlying buffer of the structure, and the remaining contents of the buffer. - + method returns a string that contains the enumerated value, the size of the underlying buffer of the structure, and the remaining contents of the buffer. + ]]> diff --git a/xml/System.Net/WebClient.xml b/xml/System.Net/WebClient.xml index ce458e983d8..8b304088d77 100644 --- a/xml/System.Net/WebClient.xml +++ b/xml/System.Net/WebClient.xml @@ -1220,7 +1220,7 @@ -or- - is or . + is or . -or- @@ -1303,7 +1303,7 @@ -or- - is or . + is or . -or- diff --git a/xml/System.Net/WebHeaderCollection.xml b/xml/System.Net/WebHeaderCollection.xml index 7a41a51676f..3eeb3817348 100644 --- a/xml/System.Net/WebHeaderCollection.xml +++ b/xml/System.Net/WebHeaderCollection.xml @@ -250,9 +250,9 @@ ]]> - contains invalid characters. + The header name contains invalid characters. - is a null reference or . + The header name is a null reference or . XML and SOAP Serialization @@ -320,8 +320,6 @@ If the header specified in `header` is already present in the collection, the value part of the `header` is concatenated with the existing value. - - ## Examples The following example adds a name/value pair to a using the Method. @@ -341,7 +339,9 @@ does not contain a colon (:) character. - The length of is greater than 65535. + -or- + + The length of the value portion of is greater than 65535. -or-