Note
Access to this page requires authorization. You can try signing in or .
Access to this page requires authorization. You can try .
IPHostEntry Class
Definition
- Namespace:
- System.Net
- Assemblies:
- netstandard.dll, System.Net.NameResolution.dll
- Assembly:
- System.Net.NameResolution.dll
- Assembly:
- System.dll
- Assembly:
- netstandard.dll
- Source:
- IPHostEntry.cs
- Source:
- IPHostEntry.cs
- Source:
- IPHostEntry.cs
- Source:
- IPHostEntry.cs
- Source:
- IPHostEntry.cs
Important
Some information relates to prerelease product that may be substantially modified before itβs released. Microsoft makes no warranties, express or implied, with respect to the information provided here.
Provides a container class for Internet host address information.
public ref class IPHostEntry
public class IPHostEntry
type IPHostEntry = class
Public Class IPHostEntry
- Inheritance
-
IPHostEntry
Examples
The following example queries the DNS database for information on the host www.contoso.com and returns the information in an IPHostEntry instance.
IPHostEntry hostInfo = Dns.GetHostEntry("www.contoso.com");
Dim hostInfo As IPHostEntry = Dns.GetHostEntry("www.contoso.com")
Remarks
The IPHostEntry class associates a Domain Name System (DNS) host name with an array of aliases and an array of matching IP addresses.
The IPHostEntry class is used as a helper class with the Dns class.
Constructors
| Name | Description |
|---|---|
| IPHostEntry() |
Initializes a new instance of the IPHostEntry class. |
Properties
| Name | Description |
|---|---|
| AddressList |
Gets or sets a list of IP addresses that are associated with a host. |
| Aliases |
Gets or sets a list of aliases that are associated with a host. |
| HostName |
Gets or sets the DNS name of the host. |
Methods
| Name | Description |
|---|---|
| Equals(Object) |
Determines whether the specified object is equal to the current object. (Inherited from Object) |
| GetHashCode() |
Serves as the default hash function. (Inherited from Object) |
| GetType() |
Gets the Type of the current instance. (Inherited from Object) |
| MemberwiseClone() |
Creates a shallow copy of the current Object. (Inherited from Object) |
| ToString() |
Returns a string that represents the current object. (Inherited from Object) |
Applies to
See also
Feedback
Was this page helpful?
