Viadeo Twitter Google Bookmarks ! Facebook Digg del.icio.us MySpace Yahoo MyWeb Blinklist Netvouz Reddit Simpy StumbleUpon Bookmarks Windows Live Favorites 
Logo Documentation Qt ·  Page d'accueil  ·  Toutes les classes  ·  Toutes les fonctions  ·  Vues d'ensemble  · 

QContactAbstractRequest Class Reference

The QContactAbstractRequest class provides a mechanism for asynchronous requests to be made of a manager if it supports them. More...

    #include <QContactAbstractRequest>

Inherits QObject.

Inherited by QContactDetailDefinitionFetchRequest, QContactDetailDefinitionRemoveRequest, QContactDetailDefinitionSaveRequest, QContactFetchRequest, QContactLocalIdFetchRequest, QContactRelationshipFetchRequest, QContactRelationshipRemoveRequest, QContactRelationshipSaveRequest, QContactRemoveRequest, and QContactSaveRequest.


Public Types

enum RequestType { InvalidRequest, ContactFetchRequest, ContactLocalIdFetchRequest, ContactRemoveRequest, ..., RelationshipSaveRequest }
enum Status { Inactive, Active, Cancelling, Cancelled, Finished }

Public Functions

QContactAbstractRequest ()
virtual ~QContactAbstractRequest ()
QContactManager::Error error () const
QList<QContactManager::Error> errors () const
bool isActive () const
bool isFinished () const
QContactManager * manager () const
void setManager ( QContactManager * manager )
Status status () const
RequestType type () const
  • 29 public functions inherited from QObject

Public Slots

bool cancel ()
bool start ()
bool waitForFinished ( int msecs = 0 )
bool waitForProgress ( int msecs = 0 )
  • 1 public slot inherited from QObject

Protected Functions

QContactAbstractRequest ( QContactAbstractRequestPrivate * otherd )
  • 7 protected functions inherited from QObject

Additional Inherited Members

  • 1 property inherited from QObject
  • 1 signal inherited from QObject
  • 1 public type inherited from QObject
  • 4 static public members inherited from QObject
  • 2 protected variables inherited from QObject

Detailed Description

The QContactAbstractRequest class provides a mechanism for asynchronous requests to be made of a manager if it supports them.

It allows a client to asynchronously request some functionality of a particular QContactManager.


Member Type Documentation

enum QContactAbstractRequest::RequestType

Enumerates the various possible types of asynchronous requests

ConstantValueDescription
QContactAbstractRequest::InvalidRequest0An invalid request
QContactAbstractRequest::ContactFetchRequest1A request to fetch a list of contacts
QContactAbstractRequest::ContactLocalIdFetchRequest2A request to fetch a list of local contact ids
QContactAbstractRequest::ContactRemoveRequest3A request to remove a list of contacts
QContactAbstractRequest::ContactSaveRequest4A request to save a list of contacts
QContactAbstractRequest::DetailDefinitionFetchRequest5A request to fetch a collection of detail definitions
QContactAbstractRequest::DetailDefinitionRemoveRequest6A request to remove a list of detail definitions
QContactAbstractRequest::DetailDefinitionSaveRequest7A request to save a list of detail definitions
QContactAbstractRequest::RelationshipFetchRequest8A request to fetch relationships between contacts
QContactAbstractRequest::RelationshipRemoveRequest9A request to remove any relationships which match the request criteria
QContactAbstractRequest::RelationshipSaveRequest10A request to save a list of relationships

enum QContactAbstractRequest::Status

Enumerates the various states that a request may be in at any given time

ConstantValueDescription
QContactAbstractRequest::Inactive0Operation not yet started
QContactAbstractRequest::Active1Operation started, not yet finished
QContactAbstractRequest::Cancelling2Operation started then cancelled, not yet finished
QContactAbstractRequest::Cancelled3Operation is finished due to cancellation
QContactAbstractRequest::Finished4Operation successfully completed


Member Function Documentation

QContactAbstractRequest::QContactAbstractRequest ()

Constructs a new, invalid asynchronous request

QContactAbstractRequest::QContactAbstractRequest ( QContactAbstractRequestPrivate * otherd )   [protected]

Constructs a new request from the given request data otherd

QContactAbstractRequest::~QContactAbstractRequest ()   [virtual]

Cleans up the memory used by this request

bool QContactAbstractRequest::cancel ()   [slot]

Attempts to cancel the request. Returns false if the request is not in the QContactAbstractRequest::Active state, or if the request is unable to be cancelled by the manager engine; otherwise returns true.

QContactManager::Error QContactAbstractRequest::error () const

Returns the overall error of the most recent asynchronous operation

QList<QContactManager::Error> QContactAbstractRequest::errors () const

Returns the list of errors which occurred during the most recent asynchronous operation. Each individual error in the list corresponds to a result in the result list.

bool QContactAbstractRequest::isActive () const

Returns true if the request is pending, processing or cancelling; otherwise, returns false.

See also status().

bool QContactAbstractRequest::isFinished () const

Returns true if the request is finished or cancelled; otherwise, returns false.

See also status().

QContactManager * QContactAbstractRequest::manager () const

Returns a pointer to the manager of which this request instance requests operations

See also setManager().

void QContactAbstractRequest::setManager ( QContactManager * manager )

Sets the manager of which this request instance requests operations to manager

See also manager().

bool QContactAbstractRequest::start ()   [slot]

Attempts to start the request. Returns false if the request is not in the QContactAbstractRequest::Inactive, QContactAbstractRequest::Finished or QContactAbstractRequest::Cancelled states, or if the request was unable to be performed by the manager engine; otherwise returns true.

Status QContactAbstractRequest::status () const

Returns the current status of the request.

See also isFinished() and isActive().

RequestType QContactAbstractRequest::type () const

Returns the type of this asynchronous request

bool QContactAbstractRequest::waitForFinished ( int msecs = 0 )   [slot]

Blocks until the request has been completed by the manager engine, or until msecs milliseconds has elapsed. If msecs is zero, this function will block indefinitely. Returns true if the request was cancelled or completed successfully within the given period, otherwise false.

bool QContactAbstractRequest::waitForProgress ( int msecs = 0 )   [slot]

Blocks until the manager engine signals that more partial results are available for the request, or until msecs milliseconds has elapsed. If msecs is zero, this function will block indefinitely. Returns true if the request was cancelled or more partial results were made available within the given period, otherwise false.

Publicité

Best Of

Actualités les plus lues

Semaine
Mois
Année
  1. « Quelque chose ne va vraiment pas avec les développeurs "modernes" », un développeur à "l'ancienne" critique la multiplication des bibliothèques 94
  2. Apercevoir la troisième dimension ou l'utilisation multithreadée d'OpenGL dans Qt, un article des Qt Quarterly traduit par Guillaume Belz 0
  3. Pourquoi les programmeurs sont-ils moins payés que les gestionnaires de programmes ? Manquent-ils de pouvoir de négociation ? 45
  4. Les développeurs ignorent-ils trop les failles découvertes dans leur code ? Prenez-vous en compte les remarques des autres ? 17
  5. Les développeurs détestent-ils les antivirus ? Un programmeur manifeste sa haine envers ces solutions de sécurité 6
  6. Quelles nouveautés de C++11 Visual C++ doit-il rapidement intégrer ? Donnez-nous votre avis 10
  7. Qt Commercial : Digia organise un webinar gratuit le 27 mars sur la conception d'interfaces utilisateur et d'applications avec le framework 0
Page suivante

Le Qt Quarterly au hasard

Logo

Conserver la réactivité de l'IHM

Qt Quarterly est la revue trimestrielle proposée par Nokia et à destination des développeurs Qt. Ces articles d'une grande qualité technique sont rédigés par des experts Qt. Lire l'article.

Communauté

Ressources

Liens utiles

Contact

  • Vous souhaitez rejoindre la rédaction ou proposer un tutoriel, une traduction, une question... ? Postez dans le forum Contribuez ou contactez-nous par MP ou par email (voir en bas de page).

Qt dans le magazine

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 qtmobility-1.0-tp
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 !
 
 
 
 
Partenaires

Hébergement Web