Click or drag to resize

TransportIsLocalAddress Method

Determines if an IP address (or DNS name) is a local IP address.

Namespace: GSF.Communication
Assembly: GSF.Communication (in GSF.Communication.dll) Version: 2.4.205-beta
Syntax
public static bool IsLocalAddress(
	string hostNameOrAddress
)
View Source

Parameters

hostNameOrAddress  String
DNS name or IP address to test.

Return Value

Boolean
true if hostNameOrAddress is a local IP address; otherwise false.
Exceptions
ExceptionCondition
SocketExceptionAn error is encountered when resolving hostNameOrAddress.
ArgumentExceptionhostNameOrAddress is an invalid IP address.
ArgumentOutOfRangeExceptionThe length of hostNameOrAddress is greater than 255 characters.
ArgumentNullExceptionhostNameOrAddress is null.
See Also