QBluetoothAuthorizationAgent Class Reference
|
Constant | Value | Description |
---|---|---|
QBluetoothAuthorizationAgent::NoError | 0 | No error. |
QBluetoothAuthorizationAgent::AlreadyExists | 1 | Another passkey agent has already been registered. |
QBluetoothAuthorizationAgent::DoesNotExist | 2 | The passkey agent has not been registered. |
QBluetoothAuthorizationAgent::UnknownError | 3 | An unknown error has occurred. |
Constructs an authorization agent. The name parameter specifies a unique name of the authorization agent. The name should be a valid identifier name, e.g. it cannot contain special characters or start with a number. For instance: DefaultAuthAgent.
The parent parameter holds the QObject parent.
Destroys the passkey agent.
This virtual function will be called whenever the bluetooth system has received an authorization request, and the agent is registered to handle the particular request.
The localDevice parameter contains the local adapter this request came in on. The remote parameter contains the Bluetooth address of the remote device requesting authorization, and service parameter holds the name of the service the authorization is being obtained for. The uuid contains an optional uuid of the request.
This function should return true if the request is to be authorized and false otherwise.
See also cancel().
This function will be called whenever an authorization request has been canceled by the requestor (e.g. connection to the service has been dropped).
The request being cancelled is on localDevice and remote is the address of the remote device. The service is the service name of the service canceling the authorization request. The uuid contains an optional uuid of the request.
See also authorize().
Returns the last error that has occurred.
Returns the name of the passkey agent as a string.
Register the authorization agent for all local adapters.
Returns true if the agent cou7ld be registered successfully, and false otherwise. If the call fails, the error can be obtained by calling error().
See also unregisterAgent() and error().
This is an overloaded member function, provided for convenience.
Register the authorization agent for localDevice adapter. The adapter name can be obtained from the QBluetoothLocalDevice object.
Returns true if the agent could be registered successfully, and false otherwise. If the call fails, the error can be obtained by calling error().
See also unregisterAgent(), error(), and QBluetoothLocalDevice.
This function will be called whenever a passkey agent has been unregistered.
See also unregisterAgent().
Unregister the authorization agent for all local adapters.
Returns true if the agent could be registered successfully, and false otherwise. If the call fails, the error can be obtained by calling error().
See also registerAgent() and error().
This is an overloaded member function, provided for convenience.
Unregister the authorization agent for localDevice adapter. The adapter name can be obtained from the QBluetoothLocalDevice object.
Returns true if the agent could be registered successfully, and false otherwise. If the call fails, the error can be obtained by calling error().
See also unregisterAgent(), error(), and QBluetoothLocalDevice.
Cette page est une traduction d'une page de la documentation de Qt, écrite par Nokia Corporation and/or its subsidiary(-ies). Les éventuels problèmes résultant d'une mauvaise traduction ne sont pas imputables à Nokia. | Qt qtextended4.4 | |
Copyright © 2012 Developpez LLC. Tous droits réservés Developpez LLC. Aucune reproduction, même partielle, ne peut être faite de ce site et de l'ensemble de son contenu : textes, documents et images sans l'autorisation expresse de Developpez LLC. Sinon, vous encourez selon la loi jusqu'à 3 ans de prison et jusqu'à 300 000 E de dommages et intérêts. Cette page est déposée à la SACD. | ||
Vous avez déniché une erreur ? Un bug ? Une redirection cassée ? Ou tout autre problème, quel qu'il soit ? Ou bien vous désirez participer à ce projet de traduction ? N'hésitez pas à nous contacter ou par MP ! |
Copyright © 2000-2012 - www.developpez.com