[This is preliminary documentation and is subject to change.]
Resolve IP address by Name
Namespace: NFXAssembly: NFX (in NFX.dll) Version: 3.0.0.1 (3.0.0.1)
public static IPEndPoint ToIPEndPoint(
this string epoint,
int dfltPort = 0
)
public static IPEndPoint ToIPEndPoint(
this string epoint,
int dfltPort = 0
)
<ExtensionAttribute>
Public Shared Function ToIPEndPoint (
epoint As String,
Optional dfltPort As Integer = 0
) As IPEndPoint
<ExtensionAttribute>
Public Shared Function ToIPEndPoint (
epoint As String,
Optional dfltPort As Integer = 0
) As IPEndPoint
public:
[ExtensionAttribute]
static IPEndPoint^ ToIPEndPoint(
String^ epoint,
int dfltPort = 0
)
public:
[ExtensionAttribute]
static IPEndPoint^ ToIPEndPoint(
String^ epoint,
int dfltPort = 0
)
static member ToIPEndPoint :
epoint : string *
?dfltPort : int
(* Defaults:
let _dfltPort = defaultArg dfltPort 0
*)
-> IPEndPoint
static member ToIPEndPoint :
epoint : string *
?dfltPort : int
(* Defaults:
let _dfltPort = defaultArg dfltPort 0
*)
-> IPEndPoint
Parameters
- epoint
- Type:
System String
An ip address or DNS host name with optional port separated by ':'
- dfltPort (Optional)
- Type:
System Int32
Port number to use if not supplied in endpoint string
Return Value
Type:
IPEndPointIPEndPoint instance or null supplied string could not be parsed
Usage Note
In Visual Basic and C#, you can call this method as an instance method on any object of type
String. When you use instance method syntax to call this method, omit the first parameter. For more information, see
Extension Methods (Visual Basic) or
Extension Methods (C# Programming Guide).