68 * If not supplied by the user default values are used. |
68 * If not supplied by the user default values are used. |
69 * @param names the subject or any keywords to be used to filter albums with that name |
69 * @param names the subject or any keywords to be used to filter albums with that name |
70 * @param user the user whose albums are requested |
70 * @param user the user whose albums are requested |
71 * @param pageNum Page number to download, SMF_FIRST_PAGE denotes fresh query. |
71 * @param pageNum Page number to download, SMF_FIRST_PAGE denotes fresh query. |
72 * @param perPage Item per page, default is SMF_ITEMS_PER_PAGE |
72 * @param perPage Item per page, default is SMF_ITEMS_PER_PAGE |
|
73 * @return SmfError. SmfNoError if success, else appropriate error code |
73 */ |
74 */ |
74 void albums ( QStringList names, SmfContact* user, |
75 SmfError albums ( QStringList names, SmfContact* user, |
75 int pageNum = SMF_FIRST_PAGE, |
76 int pageNum = SMF_FIRST_PAGE, |
76 int perPage = SMF_ITEMS_PER_PAGE ); |
77 int perPage = SMF_ITEMS_PER_PAGE ); |
77 |
78 |
78 /** |
79 /** |
79 * Get the picture listing asynchronously. The picturesAvailable() signal is |
80 * Get the picture listing asynchronously. The picturesAvailable() signal is |
81 * When the list is big user can specify the page number and per page item data. |
82 * When the list is big user can specify the page number and per page item data. |
82 * If not supplied by the user default values are used. |
83 * If not supplied by the user default values are used. |
83 * @param albums album(s) whose pictures are being requested |
84 * @param albums album(s) whose pictures are being requested |
84 * @param pageNum Page number to download, SMF_FIRST_PAGE denotes fresh query. |
85 * @param pageNum Page number to download, SMF_FIRST_PAGE denotes fresh query. |
85 * @param perPage Item per page, default is SMF_ITEMS_PER_PAGE |
86 * @param perPage Item per page, default is SMF_ITEMS_PER_PAGE |
|
87 * @return SmfError. SmfNoError if success, else appropriate error code |
86 */ |
88 */ |
87 void pictures ( SmfPictureAlbumList &albums, |
89 SmfError pictures ( SmfPictureAlbumList &albums, |
88 int pageNum = SMF_FIRST_PAGE, |
90 int pageNum = SMF_FIRST_PAGE, |
89 int perPage = SMF_ITEMS_PER_PAGE ); |
91 int perPage = SMF_ITEMS_PER_PAGE ); |
90 |
92 |
91 /** |
93 /** |
92 * Returns a user title/caption for the picture |
94 * Returns a user title/caption for the picture |
|
95 * @return SmfError. SmfNoError if success, else appropriate error code |
93 */ |
96 */ |
94 void description ( SmfPicture& picture ); |
97 SmfError description ( SmfPicture& picture ); |
95 |
98 |
96 /** |
99 /** |
97 * Upload an image.Implemented as slot to connect to UI controls more easily |
100 * Upload an image.Implemented as slot to connect to UI controls more easily |
98 * uploadFinished() signal is emitted with the success value of the upload |
101 * uploadFinished() signal is emitted with the success value of the upload |
99 * @param image the image to be uploaded |
102 * @param image the image to be uploaded |
100 * @param album the optional destination album name |
103 * @param album the optional destination album name |
|
104 * @return SmfError. SmfNoError if success, else appropriate error code |
101 */ |
105 */ |
102 void upload ( SmfPicture* image, SmfPictureAlbum* album = NULL ); |
106 SmfError upload ( SmfPicture* image, SmfPictureAlbum* album = NULL ); |
103 |
107 |
104 /** |
108 /** |
105 * Upload an list image.Implemented as slot to connect to UI controls more easily |
109 * Upload an list image.Implemented as slot to connect to UI controls more easily |
106 * uploadFinished() signal is emitted with the success value of the upload |
110 * uploadFinished() signal is emitted with the success value of the upload |
107 * @param images the list image to be uploaded |
111 * @param images the list image to be uploaded |
108 * @param album the optional destination album name |
112 * @param album the optional destination album name |
|
113 * @return SmfError. SmfNoError if success, else appropriate error code |
109 */ |
114 */ |
110 void upload ( SmfPictureList* images, SmfPictureAlbum* album = NULL ); |
115 SmfError upload ( SmfPictureList* images, SmfPictureAlbum* album = NULL ); |
111 |
116 |
112 /** |
117 /** |
113 * Posts a comment for an image. uploadFinished() signal is emitted |
118 * Posts a comment for an image. uploadFinished() signal is emitted |
114 * with success of the post once comment is posted. |
119 * with success of the post once comment is posted. |
115 * @param image Image to comment on |
120 * @param image Image to comment on |
116 * @param comment Comment to post |
121 * @param comment Comment to post |
|
122 * @return SmfError. SmfNoError if success, else appropriate error code |
117 */ |
123 */ |
118 void postComment ( SmfPicture image, SmfComment comment ); |
124 SmfError postComment ( SmfPicture image, SmfComment comment ); |
119 |
125 |
120 /** |
126 /** |
121 * Request for a custom operation. |
127 * Request for a custom operation. |
122 * @param operationId OperationId |
128 * @param operationId OperationId |
123 * @param customData Custom data to be sent |
129 * @param customData Custom data to be sent |
|
130 * @return SmfError. SmfNoError if success, else appropriate error code |
124 * Note:-Interpretation of operationId and customData is upto the concerned |
131 * Note:-Interpretation of operationId and customData is upto the concerned |
125 * plugin and client application. service provider should provide some |
132 * plugin and client application. service provider should provide some |
126 * serializing-deserializing utilities for these custom data |
133 * serializing-deserializing utilities for these custom data |
127 */ |
134 */ |
128 void customRequest ( const int& operationId, QByteArray* customData ); |
135 SmfError customRequest ( const int& operationId, QByteArray* customData ); |
|
136 |
|
137 /** |
|
138 * Cancels a request generated due to the call to any API which results |
|
139 * into http request. Might return error if no request is currently pending. |
|
140 * Please note that there can be only one request pending at any point of time |
|
141 * @return Appropriate SmfError value |
|
142 */ |
|
143 SmfError cancelRequest (); |
129 |
144 |
130 public:// from smfobserver |
145 public:// from smfobserver |
131 /** |
146 /** |
132 * To notify availibility of asynchronous requests. |
147 * To notify availibility of asynchronous requests. |
133 * @param result Requested result, before using must check error param. |
148 * @param result Requested result, before using must check error param. |