Home · All Namespaces · All Classes · Grouped Classes · Modules · Functions |
The QBluetoothSdpUuid class encapsulates Unique Identifiers defined and used by the Bluetooth Service Discovery Protocol. More...
#include <QBluetoothSdpUuid>
The QBluetoothSdpUuid class encapsulates Unique Identifiers defined and used by the Bluetooth Service Discovery Protocol.
There are three UUID sizes: 16 bit, 32 bit and 128 bit. The 16 bit and 32 bit UUIDs can be upward converted to a 128 bit UUID.
All values to this class should be given in host byte order. They will be converted to the appropriate byte ordering automatically.
Defines the size of the UUID.
Constant | Value | Description |
---|---|---|
QBluetoothSdpUuid::UUID16 | 0 | 16 bit UUID. |
QBluetoothSdpUuid::UUID32 | 1 | 32 bit UUID. |
QBluetoothSdpUuid::UUID128 | 2 | 128 bit UUID. |
Constructs a new invalid UUID.
See also isValid().
Constructs a new 16 bit UUID with the value given by data. The type of the UUID will be UUID16
See also isValid().
Constructs a new 32 bit UUID with the value given by data. The type of the UUID will be UUID32
See also isValid().
Constructs a new 128 bit UUID with the value given by data. The type of the UUID will be UUID128
See also isValid().
Constructs a new UUID from a string representation str. The UUID type will be inferred from the size and format of the string. If the string is not in a valid format, an invalid UUID is created.
See also isValid().
Constructs a UUID from a UUID given by other.
Deconstructs a UUID.
This is a convenience method for creating 128 bit UUIDs. The id parameter specifies the 128 bit id to create.
See also create16Bit() and create32Bit().
This is a convenience method for creating 16 bit UUIDs. The id parameter specifies the 16 bit id to create.
See also create32Bit() and create128Bit().
This is a convenience method for creating 32 bit UUIDs. The id parameter specifies the 32 bit id to create.
See also create16Bit() and create128Bit().
This is a convenience method for creating a QBluetoothSdpUuid from profile. The profile enumeration is converted to a Bluetooth assigned number corresponding to the the profile UUID.
Returns whether the UUID is valid.
Converts a UUID into string form.
If the UUID is a 16 bit UUID, the string returned will be in this format: 0xXXXX, where X represents a hexadecimal number. The string will be 0-padded, e.g. 0x00FF.
If the UUID is a 32 bit UUID, the string returned will be in this format: 0xXXXXXXXX where X represents a hexadecimal number. The string will be 0-padded, e.g. 0x0000FFFFFF.
If the UUID is a 128 bit UUID, the string returned will be in the format of: XXXXXXXX-XXXX-XXXX-XXXX-XXXXXXXXXXXX where X is a hexadecimal number.
Converts a 16 or 32 bit UUID to a 128 bit UUID and returns the result. If the UUID is already a 128 bit UUID, a copy of the current object is returned.
See also type().
Returns the type of the UUID.
See also uuid().
Returns the uuid as a QVariant. The QVariant should be interpreted based on the QBluetoothSdpUuid type. E.g. quint16 if type is UUID16, quint32 if type is UUID32, and quint128 if type is UUID128.
See also type().
This function returns true if UUID in the current does not match the UUID given by other.
See also operator==().
Assigns the contents of UUID other to the current UUID object.
Compares the current UUID to uuid given by other. If the types do not match, the UUIDs are converted to 128 bit UUIDs and are bitwise compared. The method returns true if uuids match, false otherwise.
Copyright © 2009 Nokia | Trademarks | Qt Extended 4.4.3 |