IPInterfaceProperties.DnsSuffix 속성
정의
중요
일부 정보는 릴리스되기 전에 상당 부분 수정될 수 있는 시험판 제품과 관련이 있습니다. Microsoft는 여기에 제공된 정보에 대해 어떠한 명시적이거나 묵시적인 보증도 하지 않습니다.
이 인터페이스와 관련된 DNS(Domain Name System) 접미사를 가져옵니다.
public:
abstract property System::String ^ DnsSuffix { System::String ^ get(); };
[System.Runtime.Versioning.UnsupportedOSPlatform("android")]
public abstract string DnsSuffix { get; }
public abstract string DnsSuffix { get; }
[<System.Runtime.Versioning.UnsupportedOSPlatform("android")>]
member this.DnsSuffix : string
member this.DnsSuffix : string
Public MustOverride ReadOnly Property DnsSuffix As String
속성 값
이 인터페이스의 DNS 접미사가 들어 있는 String이거나, 인터페이스의 DNS 접미사가 없는 경우 Empty입니다.
- 특성
예제
다음 코드 예제에서는 DNS 접미사를 표시합니다.
public static void DisplayDnsConfiguration()
{
NetworkInterface[] adapters = NetworkInterface.GetAllNetworkInterfaces();
foreach (NetworkInterface adapter in adapters)
{
IPInterfaceProperties properties = adapter.GetIPProperties();
Console.WriteLine(adapter.Description);
Console.WriteLine(" DNS suffix .............................. : {0}",
properties.DnsSuffix);
Console.WriteLine(" DNS enabled ............................. : {0}",
properties.IsDnsEnabled);
Console.WriteLine(" Dynamically configured DNS .............. : {0}",
properties.IsDynamicDnsEnabled);
}
Console.WriteLine();
}
Public Shared Sub DisplayDnsConfiguration()
Dim adapters As NetworkInterface() = NetworkInterface.GetAllNetworkInterfaces()
Dim adapter As NetworkInterface
For Each adapter In adapters
Dim properties As IPInterfaceProperties = adapter.GetIPProperties()
Console.WriteLine(adapter.Description)
Console.WriteLine(" DNS suffix................................. :{0}", properties.DnsSuffix)
Console.WriteLine(" DNS enabled ............................. : {0}", properties.IsDnsEnabled)
Console.WriteLine(" Dynamically configured DNS .............. : {0}", properties.IsDynamicDnsEnabled)
Next adapter
End Sub
설명
DNS 접미사는 DNS 이름 쿼리에 적합한 FQDN(정규화된 도메인 이름)을 얻기 위해 정규화되지 않은 호스트 이름에 추가되는 도메인 이름(예: "contoso.com")을 식별합니다. 예를 들어 로컬 머신에 "contoso.com"DnsSuffix이 있고 정규화되지 않은 호스트 이름 "www"를 resolve 경우 쿼리할 FQDN은 "www.contoso.com"입니다.