17static_assert(
sizeof(std::unique_ptr<QSerialPortInfoPrivate>)
18 ==
sizeof(QScopedPointer<QSerialPortInfoPrivate>));
83 if (name == info.portName()) {
109 d_ptr.swap(other.d_ptr);
129 return !d ? QString() : d->portName;
140 return !d ? QString() : d->device;
152 return !d ? QString() : d->description;
164 return !d ? QString() : d->manufacturer;
180 return !d ? QString() : d->serialNumber;
192 return !d ? 0 : d->vendorIdentifier;
204 return !d ? 0 : d->productIdentifier;
216 return !d ? false : d->hasVendorIdentifier;
228 return !d ? false : d->hasProductIdentifier;
Provides information about existing serial ports.
quint16 productIdentifier() const
Returns the 16-bit product number for the serial port, if available; otherwise returns zero.
QString manufacturer() const
Returns the manufacturer string of the serial port, if available; otherwise returns an empty string.
void swap(QSerialPortInfo &other)
Swaps QSerialPortInfo other with this QSerialPortInfo.
QString portName() const
Returns the name of the serial port.
bool hasVendorIdentifier() const
Returns true if there is a valid 16-bit vendor number present; otherwise returns false.
QString serialNumber() const
static QList< QSerialPortInfo > availablePorts()
Returns a list of available serial ports on the system.
QString systemLocation() const
Returns the system location of the serial port.
~QSerialPortInfo()
Destroys the QSerialPortInfo object.
QString description() const
Returns the description string of the serial port, if available; otherwise returns an empty string.
quint16 vendorIdentifier() const
Returns the 16-bit vendor number for the serial port, if available; otherwise returns zero.
bool hasProductIdentifier() const
Returns true if there is a valid 16-bit product number present; otherwise returns false.
QSerialPortInfo & operator=(const QSerialPortInfo &other)
Sets the QSerialPortInfo object to be equal to other.
QSerialPortInfo()
Constructs an empty QSerialPortInfo object.
static QList< qint32 > standardBaudRates()
Returns a list of available standard baud rates supported by the target platform.
static QList< qint32 > standardBaudRates()
Provides functions to access serial ports.