diff -r 1cee9f1b95e0 -r a180113055cb smf/smfservermodule/smfclient/smfcontactfetcher_p.h --- a/smf/smfservermodule/smfclient/smfcontactfetcher_p.h Thu Sep 23 17:20:22 2010 +0530 +++ b/smf/smfservermodule/smfclient/smfcontactfetcher_p.h Thu Sep 23 17:43:31 2010 +0530 @@ -71,9 +71,9 @@ * by the user default values are used. * @param pageNum Page number to download, SMF_FIRST_PAGE denotes fresh query. * @param perPage Item per page, default is SMF_ITEMS_PER_PAGE - * @return true if success, else false + * @return SmfError. SmfNoError if success, else appropriate error code */ - bool friends ( int pageNum = SMF_FIRST_PAGE, int perPage = SMF_ITEMS_PER_PAGE ); + SmfError friends ( int pageNum = SMF_FIRST_PAGE, int perPage = SMF_ITEMS_PER_PAGE ); /** * Get the list of followers asynchronously. The followersListAvailable() signal @@ -83,9 +83,9 @@ * If not supplied by the user default values are used. * @param pageNum Page number to download, SMF_FIRST_PAGE denotes fresh query. * @param perPage Item per page, default is SMF_ITEMS_PER_PAGE - * @return true if success, else false + * @return SmfError. SmfNoError if success, else appropriate error code */ - bool followers ( int pageNum = SMF_FIRST_PAGE, int perPage = SMF_ITEMS_PER_PAGE ); + SmfError followers ( int pageNum = SMF_FIRST_PAGE, int perPage = SMF_ITEMS_PER_PAGE ); /** * Searches for a contact The searchContactFinished() signal @@ -96,8 +96,9 @@ * set as one of its fields. * @param pageNum Page number to download, SMF_FIRST_PAGE denotes fresh query. * @param perPage Item per page, default is SMF_ITEMS_PER_PAGE + * @return SmfError. SmfNoError if success, else appropriate error code */ - void search ( SmfContact* contact, int pageNum = SMF_FIRST_PAGE, + SmfError search ( SmfContact* contact, int pageNum = SMF_FIRST_PAGE, int perPage = SMF_ITEMS_PER_PAGE ); /** @@ -110,8 +111,9 @@ * @param proximity The search boundary criteria * @param pageNum Page number to download, SMF_FIRST_PAGE denotes fresh query. * @param perPage Item per page, default is SMF_ITEMS_PER_PAGE + * @return SmfError. SmfNoError if success, else appropriate error code */ - bool searchNear ( SmfLocation* location, + SmfError searchNear ( SmfLocation* location, SmfLocationSearchBoundary proximity, int pageNum = SMF_FIRST_PAGE, int perPage = SMF_ITEMS_PER_PAGE); @@ -124,8 +126,9 @@ * by the user default values are used. * @param pageNum Page number to download, SMF_FIRST_PAGE denotes fresh query. * @param perPage Item per page, default is SMF_ITEMS_PER_PAGE + * @return SmfError. SmfNoError if success, else appropriate error code */ - bool groups ( int pageNum = SMF_FIRST_PAGE, int perPage = SMF_ITEMS_PER_PAGE ); + SmfError groups ( int pageNum = SMF_FIRST_PAGE, int perPage = SMF_ITEMS_PER_PAGE ); /** * Searches for Smf Contacts in an Smf group. The signal searchInGroupFinished() @@ -133,11 +136,13 @@ * can specify the page number and per page item data. If not supplied by the * user default values are used. * @param group The group to be searched in + * @contact The contact to be searched, default (NULL) is the self contact. * @param pageNum Page number to download, SMF_FIRST_PAGE denotes fresh query. * @param perPage Item per page, default is SMF_ITEMS_PER_PAGE - * @return true if success, else false + * @return SmfError. SmfNoError if success, else appropriate error code */ - bool searchInGroup ( SmfGroup group, + SmfError searchInGroup ( SmfGroup group, + SmfContact* contact = NULL, int pageNum = SMF_FIRST_PAGE, int perPage = SMF_ITEMS_PER_PAGE ); @@ -146,11 +151,20 @@ * when the result is available. * @param operationId OperationId * @param customData Custom data to be sent + * @return SmfError. SmfNoError if success, else appropriate error code * Note:-Interpretation of operationId and customData is upto the concerned * plugin and client application. service provider should provide some * serializing-deserializing utilities for these custom data */ - void customRequest ( const int& operationId, QByteArray* customData ); + SmfError customRequest ( const int& operationId, QByteArray* customData ); + + /** + * Cancels a request generated due to the call to any API which results + * into http request. Might return error if no request is currently pending. + * Please note that there can be only one request pending at any point of time + * @return Appropriate SmfError value + */ + SmfError cancelRequest (); public: //from smfobserver /**