• 7324阅读
  • 3回复

QHostAddress::Broadcast [复制链接]

上一主题 下一主题
离线asdfgsdgasd
 
只看楼主 倒序阅读 楼主  发表于: 2010-05-29
问一下 QHostAddress::Broadcast这返回的是什么  还是没有值  ,
toLatin1  这是什么类型啊
离线wd007

只看该作者 1楼 发表于: 2010-05-29
帮助中这样说明的:

QHostAddress QNetworkAddressEntry::broadcast () const

Returns the broadcast address associated with the IPv4 address and netmask. It can usually be derived from those two by setting to 1 the bits of the IP address where the netmask contains a 0. (In other words, by bitwise-OR'ing the IP address with the inverse of the netmask)

This member is always empty for IPv6 addresses, since the concept of broadcast has been abandoned in that system in favor of multicast. In particular, the group of hosts corresponding to all the nodes in the local network can be reached by the "all-nodes" special multicast group (address FF02::1).

See also setBroadcast().
欢迎访问我的博客,一起学习提高
http://blog.csdn.net/qter_wd007
离线asdfgsdgasd
只看该作者 2楼 发表于: 2010-05-30
谢谢了
离线foxgod

只看该作者 3楼 发表于: 2014-10-30
回 wd007 的帖子
wd007:帮助中这样说明的:
QHostAddress QNetworkAddressEntry::broadcast () const
Returns the broadcast address associated with the IPv4 address and netmask. It can usually be derived from those two by setting to 1 the bits of the IP address where the netmask contain .. (2010-05-29 22:20) 

如何判断两个IP是一个网段内呢
快速回复
限100 字节
 
上一个 下一个