Home · All Namespaces · All Classes · Grouped Classes · Modules · Functions codeless banner

QBluetoothPasskeyRequest Class Reference
[QtBluetoothModule]

The QBluetoothPasskeyRequest class encapsulates a Bluetooth PIN request. More...

    #include <QBluetoothPasskeyRequest>

Public Functions


Detailed Description

The QBluetoothPasskeyRequest class encapsulates a Bluetooth PIN request.

The QBluetoothPasskeyRequest class encapsulates a passkey request received from the bluetooth system. The request can be rejected, cancelled or accepted. If it is accepted, a valid passkey must be provided.

See also QBluetoothPasskeyAgent.


Member Function Documentation

QBluetoothPasskeyRequest::QBluetoothPasskeyRequest ( const QString & localDevice, const QBluetoothAddress & remoteDevice )

Constructs a QBluetoothPasskeyRequest. The localDevice parameter specifies the local bluetooth adapter the request came in on. This string should be in the form hciX, such that it can be passed to QBluetoothLocalDevice constructor. The remoteDevice parameter specifies the remote device being paired to.

By default, the request is set to be rejected.

QBluetoothPasskeyRequest::QBluetoothPasskeyRequest ( const QBluetoothPasskeyRequest & other )

Copy constructor. Constructs a QBluetoothPasskeyRequest from other.

QBluetoothPasskeyRequest::~QBluetoothPasskeyRequest ()

Destroys the passkey request.

bool QBluetoothPasskeyRequest::isRejected () const

Returns true if the request has been rejected.

See also setRejected().

const QString & QBluetoothPasskeyRequest::localDevice () const

Returns the name of the local device adapter. The string returned is of the form hciX. This can be passed in to the QBluetoothLocalDevice constructor.

See also QBluetoothLocalDevice.

const QString & QBluetoothPasskeyRequest::passkey () const

Returns the passkey for the request.

See also setPasskey().

const QBluetoothAddress & QBluetoothPasskeyRequest::remoteDevice () const

Returns the address of the remote device associated with this request.

void QBluetoothPasskeyRequest::setPasskey ( const QString & passkey )

Accepts the pairing request, and sets the passkey to passkey.

See also setRejected() and passkey().

void QBluetoothPasskeyRequest::setRejected ()

Sets the request to be rejected. This usually means that the user has explicitly rejected the request.

See also isRejected() and setPasskey().

bool QBluetoothPasskeyRequest::operator!= ( const QBluetoothPasskeyRequest & other ) const

Comparison operator. Compares the contents of other to the current passkey request. Returns true if the contents are not equal.

QBluetoothPasskeyRequest & QBluetoothPasskeyRequest::operator= ( const QBluetoothPasskeyRequest & other )

Assignment operator. Assigns the contents of other to the current passkey request.

bool QBluetoothPasskeyRequest::operator== ( const QBluetoothPasskeyRequest & other ) const

Comparison operator. Compares the contents of other to the current passkey request. Returns true if the contents are equal.


Copyright © 2009 Nokia Trademarks
Qt Extended 4.4.3