The QKnxNetIpServerInfo class stores information about a KNXnet/IP server. 更多...
头: | #include <QKnxNetIpServerInfo> |
qmake: | QT += knx |
QKnxNetIpServerInfo (QKnxNetIpServerInfo && other ) | |
QKnxNetIpServerInfo (const QKnxNetIpServerInfo & other ) | |
QKnxNetIpServerInfo () | |
QKnxNetIpServerInfo & | operator= (QKnxNetIpServerInfo && other ) |
QKnxNetIpServerInfo & | operator= (const QKnxNetIpServerInfo & other ) |
~QKnxNetIpServerInfo () | |
QHostAddress | controlEndpointAddress () const |
quint16 | controlEndpointPort () const |
QString | deviceName () const |
QKnxNetIpHpai | endpoint () const |
QKnxNetIpDib | extendedHardware () const |
QKnxNetIpDib | hardware () const |
QHostAddress | hostAddress () const |
QKnxAddress | individualAddress () const |
quint16 | maskVersion () const |
quint16 | maximumLocalApduLength () const |
QKnx::MediumStatus | mediumStatus () const |
QNetworkInterface | networkInterface () const |
QKnxNetIpDib | services () const |
QVector<QKnxServiceInfo> | supportedServices () const |
void | swap (QKnxNetIpServerInfo & other ) |
QKnxNetIpDib | tunnelingInfo () const |
QVector<QKnxNetIpTunnelingSlotInfo> | tunnelingSlotInfos () const |
bool | operator!= (const QKnxNetIpServerInfo & other ) const |
bool | operator== (const QKnxNetIpServerInfo & other ) const |
A KNXnet/IP server information object contains the information provided by the server during its discovery (using for example QKnxNetIpServerDiscoveryAgent ) that the client needs to establish a connection. This includes the device name and individual address of the server, a KNXnet/IP transport connection endpoint, and the services supported by the server.
KNXnet/IP servers are typically connected to one KNX subnetwork and to an IP network. Therefore, they have one KNX individual address returned by individualAddress () and one IP address returned by controlEndpointAddress ().
A KNXnet/IP server can support the following service types: core, device management, tunneling, routing, remote logging and configuration, and object server. The supported services are returned by supportedServices () as a vector of QKnxServiceInfo objects or by services () as a QKnxNetIpDib object which can be accessed via QKnxNetIpServiceFamiliesDibProxy .
Furthermore, as specified by the KNX application note AN185, the server info may contain additional tunneling and extend device hardware information. If the information is present, it is made accessible through the mediumStatus (), maximumLocalApduLength (), maskVersion (),和 tunnelingSlotInfos () functions. It is also possible to introspect the raw structures via their corresponding proxy objects.
Here is an example on how to use the extended device information proxy in a search that is started using the QKnxNetIpServerDiscoveryAgent :
const auto servers = agent.discoveredServers(); for (auto server : servers) { const auto dib = server.extendedHardware(); QKnxNetIpExtendedDeviceDibProxy proxy(dib); if (!proxy.isValid()) continue; qDebug() << "Medium status:" << proxy.mediumStatus() << "Maximum local APDU length:" << proxy.maximumLocalApduLength() << "Device mask:" << proxy.deviceDescriptorType0(); }
另请参阅 QKnxAddress , QKnxNetIpHpai , QKnxNetIpHpaiProxy , QKnxNetIpDib , QKnxNetIpDeviceDibProxy , QKnxNetIpServiceFamiliesDibProxy ,和 Qt KNXnet/IP Connection Classes .
Move-constructs an object instance, making it point to the same object that other 所指向的。
构造副本为 other .
Creates a KNXnet/IP server information object.
Move-constructs an object instance, making it point to the same object that other 所指向的。
赋值 other 到此对象。
Deletes a KNXnet/IP server information object.
Returns the host address of the control endpoint.
Returns the port number of the control endpoint.
Returns the device name.
Returns a KNXnet/IP transport connection endpoint.
另请参阅 QKnxNetIpHpaiProxy .
Returns extended hardware information about the KNXnet/IP server hardware.
该函数在 Qt 5.12 引入。
另请参阅 QKnxNetIpExtendedDeviceDibProxy .
Returns information about the KNXnet/IP server hardware.
另请参阅 QKnxNetIpDeviceDibProxy .
Returns the host address which has been used to discover the KNXnet/IP server hardware.
该函数在 Qt 5.14 引入。
另请参阅 QHostAddress .
Returns the individual address of the server.
Returns the mask version (device descriptor 0) of the discovered KNXnet/IP server if it supports extended device information; otherwise returns a
默认构造值
which can be
0
.
该函数在 Qt 5.12 引入。
Returns the maximum local application protocol data unit (APDU) length of the discovered KNXnet/IP server if it supports extended device information; otherwise returns a
默认构造值
which can be
0
.
该函数在 Qt 5.12 引入。
Returns the medium status of the discovered KNXnet/IP server if it supports extended device information; otherwise returns QKnx::Unknown .
该函数在 Qt 5.12 引入。
Returns the network interface which has been used to discover the KNXnet/IP server hardware.
该函数在 Qt 5.14 引入。
另请参阅 QNetworkInterface .
Returns the services available on a KNXnet/IP server.
另请参阅 QKnxNetIpServiceFamiliesDibProxy .
Returns the services supported by a KNXnet/IP server.
Swaps the server information object other with this object.
Returns tunneling information if available on a KNXnet/IP server.
该函数在 Qt 5.12 引入。
另请参阅 QKnxNetIpTunnelingInfoDibProxy .
Returns the available tunneling slots of the discovered KNXnet/IP server if it supports providing this kind of information; otherwise returns an empty vector.
该函数在 Qt 5.12 引入。
返回
true
if
other
points to a different item than this server information object. Otherwise, returns
false
.
返回
true
if
other
points to the same item as this server information object. Otherwise, returns
false
.