本文整理汇总了VB.NET中System.Net.IPAddress.NetworkToHostOrder方法的典型用法代码示例。如果您正苦于以下问题:VB.NET IPAddress.NetworkToHostOrder方法的具体用法?VB.NET IPAddress.NetworkToHostOrder怎么用?VB.NET IPAddress.NetworkToHostOrder使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类System.Net.IPAddress
的用法示例。
在下文中一共展示了IPAddress.NetworkToHostOrder方法的3个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的VB.NET代码示例。
示例1:
Public Sub NetworkToHostOrder_Integer(networkByte As Integer)
Dim hostByte As Integer
' Converts an integer value from network byte order to host byte order.
hostByte = IPAddress.NetworkToHostOrder(networkByte)
Console.WriteLine("Network byte order to Host byte order of {0} is {1}", networkByte, hostByte)
End Sub
示例2:
Public Sub NetworkToHostOrder_Long(networkByte As Long)
Dim hostByte As Long
' Converts a long value from network byte order to host byte order.
hostByte = IPAddress.NetworkToHostOrder(networkByte)
Console.WriteLine("Network byte order to Host byte order of {0} is {1}", networkByte, hostByte)
End Sub
示例3:
Public Sub NetworkToHostOrder_Short(networkByte As Short)
Dim hostByte As Short
' Converts a short value from network byte order to host byte order.
hostByte = IPAddress.NetworkToHostOrder(networkByte)
Console.WriteLine("Network byte order to Host byte order of {0} is {1}", networkByte, hostByte)
End Sub