63 */ |
69 */ |
64 ~SmfMusicService ( ); |
70 ~SmfMusicService ( ); |
65 |
71 |
66 public slots: |
72 public slots: |
67 /** |
73 /** |
68 * Gets self profile information asynchronously. |
74 * Gets self profile information (e.g. music likings, feavorites etc) asynchronously. |
69 * userInfoAvailable() signal is emitted with SmfMusicProfile when the info is arrived |
75 * userMusicInfoAvailable() signal is emitted with SmfMusicProfile when the info is arrived |
70 */ |
76 * @return SmfError. SmfNoError if success, else appropriate error code |
71 void userinfo ( ); |
77 */ |
|
78 SmfError userMusicInfo ( ); |
|
79 |
|
80 /** |
|
81 * Asynchronously searches information about artists in this service. All information |
|
82 * in SmfArtists is not required, however more available the better |
|
83 * searchArtistInfoAvailable() signal is emitted when the info is arrived. |
|
84 * @param artist The search criteria |
|
85 * @param pageNum Page number to download, SMF_FIRST_PAGE denotes fresh query. |
|
86 * @param perPage Item per page, default is SMF_ITEMS_PER_PAGE |
|
87 * @return SmfError, SmfNoError if success, else appropriate error value |
|
88 */ |
|
89 SmfError searchArtist ( SmfArtists artist, int pageNum = SMF_FIRST_PAGE, |
|
90 int perPage = SMF_ITEMS_PER_PAGE ); |
|
91 |
|
92 /** |
|
93 * Asynchronously searches information about albums in this service. All information |
|
94 * in SmfAlbum is not required, however more available the better |
|
95 * searchAlbumInfoAvailable() signal is emitted when the info is arrived. |
|
96 * @param album The search criteria |
|
97 * @param pageNum Page number to download, SMF_FIRST_PAGE denotes fresh query. |
|
98 * @param perPage Item per page, default is SMF_ITEMS_PER_PAGE |
|
99 * @return SmfError, SmfNoError if success, else appropriate error value |
|
100 */ |
|
101 SmfError searchAlbum ( SmfAlbum album, int pageNum = SMF_FIRST_PAGE, |
|
102 int perPage = SMF_ITEMS_PER_PAGE ); |
|
103 |
|
104 /** |
|
105 * Asynchronously searches information about events in this service. All information |
|
106 * in SmfEvents is not required, however more available the better |
|
107 * searchEventsInfoAvailable() signal is emitted when the info is arrived. |
|
108 * @param event The search criteria |
|
109 * @param pageNum Page number to download, SMF_FIRST_PAGE denotes fresh query. |
|
110 * @param perPage Item per page, default is SMF_ITEMS_PER_PAGE |
|
111 * @return SmfError, SmfNoError if success, else appropriate error value |
|
112 */ |
|
113 SmfError searchEvents ( SmfEvent event, int pageNum = SMF_FIRST_PAGE, |
|
114 int perPage = SMF_ITEMS_PER_PAGE ); |
|
115 |
|
116 /** |
|
117 * Asynchronously searches information about venue in this service. All information |
|
118 * in SmfVenue is not required, however more available the better |
|
119 * searchVenueInfoAvailable() signal is emitted when the info is arrived. |
|
120 * @param location The search criteria |
|
121 * @param pageNum Page number to download, SMF_FIRST_PAGE denotes fresh query. |
|
122 * @param perPage Item per page, default is SMF_ITEMS_PER_PAGE |
|
123 * @return SmfError, SmfNoError if success, else appropriate error value |
|
124 */ |
|
125 SmfError searchVenue ( SmfLocation location, int pageNum = SMF_FIRST_PAGE, |
|
126 int perPage = SMF_ITEMS_PER_PAGE ); |
72 |
127 |
73 /** |
128 /** |
74 * Asynchronously searches information about other service users for a particular venue |
129 * Asynchronously searches information about other service users for a particular venue |
75 * searchInfoAvailable() signal is emitted with SmfMusicProfileList when the info is arrived. |
130 * searchUserInfoAvailable() signal is emitted with SmfMusicProfileList when the info is arrived. |
76 * When the list is big user can specify the page number and per page item data. |
131 * When the list is big user can specify the page number and per page item data. |
77 * If not supplied by the user default values are used. |
132 * If not supplied by the user default values are used. |
78 * @param pageNum Page number to download, SMF_FIRST_PAGE denotes fresh query. |
133 * @param location The search criteria |
79 * @param perPage Item per page, default is SMF_ITEMS_PER_PAGE |
134 * @param pageNum Page number to download, SMF_FIRST_PAGE denotes fresh query. |
80 */ |
135 * @param perPage Item per page, default is SMF_ITEMS_PER_PAGE |
81 void searchUser ( SmfLocation venue, int pageNum = SMF_FIRST_PAGE, |
136 * @return SmfError, SmfNoError if success, else appropriate error value |
|
137 */ |
|
138 SmfError searchUser ( SmfLocation venue, int pageNum = SMF_FIRST_PAGE, |
82 int perPage = SMF_ITEMS_PER_PAGE); |
139 int perPage = SMF_ITEMS_PER_PAGE); |
83 |
140 |
|
141 /** |
|
142 * Posts currently playing track. |
|
143 * Success can be checked by checking the signal postFinished() |
|
144 * @param track Track to post |
|
145 * @return SmfError, SmfNoError if success, else appropriate error value |
|
146 */ |
|
147 SmfError postCurrentPlaying ( SmfTrackInfo track); |
|
148 |
|
149 /** |
|
150 * Rate a music via this API |
|
151 * Success can be checked by checking the signal postFinished() |
|
152 * @param track Track on which rating should be posted |
|
153 * @param rate Rating value |
|
154 * @return SmfError, SmfNoError if success, else appropriate error value |
|
155 */ |
|
156 SmfError postRating ( SmfTrackInfo track, SmfMusicRating rate); |
|
157 |
|
158 /** |
|
159 * Comment on a track via this API |
|
160 * Success can be checked by checking the signal postFinished() |
|
161 * @param track Track on which comment should be posted |
|
162 * @param comment The comemnt to be posted |
|
163 * @return SmfError, SmfNoError if success, else appropriate error value |
|
164 */ |
|
165 SmfError postComments ( SmfTrackInfo track, SmfComment comment); |
|
166 |
84 /** |
167 /** |
85 * Request for a custom operation. The signal customDataAvailable() is emitted |
168 * Request for a custom operation. The signal customDataAvailable() is emitted |
86 * when the result is available. |
169 * when the result is available. |
87 * @param operationId OperationId |
170 * @param operationId OperationId |
88 * @param customData Custom data to be sent |
171 * @param customData Custom data to be sent |
|
172 * @return SmfError. SmfNoError if success, else appropriate error code |
89 * Note:-Interpretation of operationId and customData is upto the concerned |
173 * Note:-Interpretation of operationId and customData is upto the concerned |
90 * plugin and client application. service provider should provide some |
174 * plugin and client application. service provider should provide some |
91 * serializing-deserializing utilities for these custom data |
175 * serializing-deserializing utilities for these custom data |
92 */ |
176 */ |
93 void customRequest ( const int& operationId, QByteArray* customData ); |
177 SmfError customRequest ( const int& operationId, QByteArray* customData ); |
94 |
178 |
95 public slots: |
179 /** |
96 /** |
180 * Cancels a request generated due to the call to any API which results |
97 * Posts currently playing track. |
181 * into http request. Might return error if no request is currently pending. |
98 * Success can be checked by checking the signal postFinished() |
182 * Please note that there can be only one request pending at any point of time |
99 * @param track Track to post |
183 * @return Appropriate SmfError value |
100 */ |
184 */ |
101 void postCurrentPlaying ( SmfTrackInfo track); |
185 SmfError cancelRequest (); |
102 |
186 |
103 void postRating ( SmfTrackInfo track, SmfMusicRating rate); |
187 |
104 |
|
105 void postComments ( SmfTrackInfo track, SmfComment comment); |
|
106 |
|
107 signals: |
188 signals: |
108 /** |
189 /** |
109 * Notification on arrival of the self profile as result of userinfo(). |
190 * Notification on arrival of the self profile as result of userinfo(). |
110 * @param profile The self profile |
191 * @param profile The self profile |
111 */ |
192 * @param error SmfNoError if success, else appropriate error value |
112 void userInfoAvailable ( SmfMusicProfile* profile, SmfError error ); |
193 */ |
|
194 void userMusicInfoAvailable ( SmfMusicProfile* profile, SmfError error ); |
113 |
195 |
114 /** |
196 /** |
115 * Notification on arrival of search info |
197 * Notification on arrival of search info |
116 * @param profileList List of music profiles |
198 * @param profileList List of music profiles |
117 */ |
199 * @param error SmfNoError if success, else appropriate error value |
118 void searchInfoAvailable ( SmfMusicProfileList* profileList, |
200 */ |
|
201 void searchUserInfoAvailable ( SmfMusicProfileList* profileList, |
|
202 SmfError error, SmfResultPage resultPage ); |
|
203 |
|
204 /** |
|
205 * Notification on arrival of search info |
|
206 * @param artists List of artists |
|
207 * @param error SmfNoError if success, else appropriate error value |
|
208 */ |
|
209 void searchArtistInfoAvailable (QList<SmfArtists>* artists, |
|
210 SmfError error, SmfResultPage resultPage ); |
|
211 |
|
212 /** |
|
213 * Notification on arrival of search info |
|
214 * @param albumList List of albums |
|
215 * @param error SmfNoError if success, else appropriate error value |
|
216 */ |
|
217 void searchAlbumInfoAvailable ( QList<SmfAlbum>* albumList, |
|
218 SmfError error, SmfResultPage resultPage ); |
|
219 |
|
220 /** |
|
221 * Notification on arrival of search info |
|
222 * @param eventList List of events |
|
223 * @param error SmfNoError if success, else appropriate error value |
|
224 */ |
|
225 void searchEventsInfoAvailable ( SmfEventList* eventList, |
|
226 SmfError error, SmfResultPage resultPage ); |
|
227 |
|
228 /** |
|
229 * Notification on arrival of search info |
|
230 * @param venueList List of venues |
|
231 * @param error SmfNoError if success, else appropriate error value |
|
232 */ |
|
233 void searchVenueInfoAvailable ( SmfLocationList* venueList, |
119 SmfError error, SmfResultPage resultPage ); |
234 SmfError error, SmfResultPage resultPage ); |
120 |
235 |
121 /** |
236 /** |
122 * Signals availability of the result of the customRequest |
237 * Signals availability of the result of the customRequest |
123 * @param operationId The ID to be shared between clients and the plugin |
238 * @param operationId The ID to be shared between clients and the plugin |
188 * When the list is big user can specify the page number and per page item data. |
304 * When the list is big user can specify the page number and per page item data. |
189 * If not supplied by the user default values are used. |
305 * If not supplied by the user default values are used. |
190 * @param track The search criteria, similar tracks are searched |
306 * @param track The search criteria, similar tracks are searched |
191 * @param pageNum Page number to download, SMF_FIRST_PAGE denotes fresh query. |
307 * @param pageNum Page number to download, SMF_FIRST_PAGE denotes fresh query. |
192 * @param perPage Item per page, default is SMF_ITEMS_PER_PAGE |
308 * @param perPage Item per page, default is SMF_ITEMS_PER_PAGE |
193 */ |
309 * @return SmfNoError if success, else appropriate error value |
194 void tracks ( SmfTrackInfo track, int pageNum = SMF_FIRST_PAGE, |
310 */ |
|
311 SmfError tracksSimilar ( SmfTrackInfo track, int pageNum = SMF_FIRST_PAGE, |
|
312 int perPage = SMF_ITEMS_PER_PAGE); |
|
313 |
|
314 /** |
|
315 * Searches for tracks for a given album asynchronously. |
|
316 * The signal trackSearchAvailable() is emitted with SmfTrackInfoList |
|
317 * once its arrived. |
|
318 * When the list is big user can specify the page number and per page item data. |
|
319 * If not supplied by the user default values are used. |
|
320 * @param album The album containing the id |
|
321 * @param pageNum Page number to download, SMF_FIRST_PAGE denotes fresh query. |
|
322 * @param perPage Item per page, default is SMF_ITEMS_PER_PAGE |
|
323 * @return SmfNoError if success, else appropriate error value |
|
324 */ |
|
325 SmfError tracksOfAlbum ( SmfAlbum album, int pageNum = SMF_FIRST_PAGE, |
|
326 int perPage = SMF_ITEMS_PER_PAGE); |
|
327 |
|
328 /** |
|
329 * Searches for tracks for a given artist(s) asynchronously. |
|
330 * The signal trackSearchAvailable() is emitted with SmfTrackInfoList |
|
331 * once its arrived. |
|
332 * When the list is big user can specify the page number and per page item data. |
|
333 * If not supplied by the user default values are used. |
|
334 * @param artists The artists list |
|
335 * @param pageNum Page number to download, SMF_FIRST_PAGE denotes fresh query. |
|
336 * @param perPage Item per page, default is SMF_ITEMS_PER_PAGE |
|
337 * @return SmfNoError if success, else appropriate error value |
|
338 */ |
|
339 SmfError tracksOfArtist ( SmfArtists artists, int pageNum = SMF_FIRST_PAGE, |
195 int perPage = SMF_ITEMS_PER_PAGE); |
340 int perPage = SMF_ITEMS_PER_PAGE); |
196 |
341 |
197 /** |
342 /** |
198 * Searches for a track having similar finger print asynchronously. |
343 * Searches for a track having similar finger print asynchronously. |
199 * The signal trackSearchAvailable() is emitted with SmfTrackInfoList |
344 * The signal trackSearchAvailable() is emitted with SmfTrackInfoList |
200 * once its arrived. |
345 * once its arrived. |
201 * @param signature The search criteria,signature to be searched for |
346 * @param signature The search criteria,signature to be searched for |
202 * @param pageNum Page number to download, SMF_FIRST_PAGE denotes fresh query. |
347 * @param pageNum Page number to download, SMF_FIRST_PAGE denotes fresh query. |
203 * @param perPage Item per page, default is SMF_ITEMS_PER_PAGE |
348 * @param perPage Item per page, default is SMF_ITEMS_PER_PAGE |
204 */ |
349 * @return SmfNoError if success, else appropriate error value |
205 void trackInfo ( SmfMusicFingerPrint signature, int pageNum = SMF_FIRST_PAGE, |
350 */ |
|
351 SmfError trackInfo ( SmfMusicFingerPrint signature, int pageNum = SMF_FIRST_PAGE, |
206 int perPage = SMF_ITEMS_PER_PAGE); |
352 int perPage = SMF_ITEMS_PER_PAGE); |
207 |
353 |
208 /** |
354 /** |
209 * Search information about where to buy this song from asynchronously. |
355 * Search information about where to buy this song from asynchronously. |
210 * The signal storeSearchAvailable() is emitted with SmfProviderList once its arrived. |
356 * The signal storeSearchAvailable() is emitted with SmfProviderList once its arrived. |
211 * @param track The search criteria for stores |
357 * @param track The search criteria for stores |
212 * @param pageNum Page number to download, SMF_FIRST_PAGE denotes fresh query. |
358 * @param pageNum Page number to download, SMF_FIRST_PAGE denotes fresh query. |
213 * @param perPage Item per page, default is SMF_ITEMS_PER_PAGE |
359 * @param perPage Item per page, default is SMF_ITEMS_PER_PAGE |
214 */ |
360 * @return SmfNoError if success, else appropriate error value |
215 void stores ( SmfTrackInfo track, int pageNum = SMF_FIRST_PAGE, |
361 */ |
|
362 SmfError stores ( SmfTrackInfo track, int pageNum = SMF_FIRST_PAGE, |
216 int perPage = SMF_ITEMS_PER_PAGE); |
363 int perPage = SMF_ITEMS_PER_PAGE); |
217 |
364 |
218 /** |
365 /** |
219 * Request for a custom operation. The signal customDataAvailable() is emitted |
366 * Request for a custom operation. The signal customDataAvailable() is emitted |
220 * when the result is available. |
367 * when the result is available. |
221 * @param operationId OperationId |
368 * @param operationId OperationId |
222 * @param customData Custom data to be sent |
369 * @param customData Custom data to be sent |
|
370 * @return SmfNoError if success, else appropriate error value |
223 * Note:-Interpretation of operationId and customData is upto the concerned |
371 * Note:-Interpretation of operationId and customData is upto the concerned |
224 * plugin and client application. service provider should provide some |
372 * plugin and client application. service provider should provide some |
225 * serializing-deserializing utilities for these custom data |
373 * serializing-deserializing utilities for these custom data |
226 */ |
374 */ |
227 void customRequest ( const int& operationId, QByteArray* customData ); |
375 SmfError customRequest ( const int& operationId, QByteArray* customData ); |
|
376 |
|
377 /** |
|
378 * Cancels a request generated due to the call to any API which results |
|
379 * into http request. Might return error if no request is currently pending. |
|
380 * Please note that there can be only one request pending at any point of time |
|
381 * @return Appropriate SmfError value |
|
382 */ |
|
383 SmfError cancelRequest (); |
228 |
384 |
229 signals: |
385 signals: |
230 /** |
386 /** |
231 * Emitted when the search result for a track is available. |
387 * Emitted when the search results for tracks (for album, artist, etc) are available. |
232 * Note if number of tacks in the search is large, then it can download the list page by page. |
388 * Note if number of tacks in the search is large, then it can download the list page by page. |
233 * In that case this signal is emitted multiple times. |
389 * @param result list of tracks |
|
390 * @param error SmfNoError if success, else appropriate error value |
234 * @param resultPage Page number info |
391 * @param resultPage Page number info |
235 */ |
392 */ |
236 void trackSearchAvailable ( SmfTrackInfoList* result, |
393 void trackSearchAvailable ( SmfTrackInfoList* result, |
237 SmfError error, SmfResultPage resultPage); |
394 SmfError error, SmfResultPage resultPage); |
238 |
395 |
239 /** |
396 /** |
240 * Emitted when the search result for a store is available. |
397 * Emitted when the search result for a store is available. |
241 * Note if number of tacks in the search is large, then it can download the list page by page. |
398 * Note if number of tacks in the search is large, then it can download the list page by page. |
242 * In that case this signal is emitted multiple times. |
399 * @param result List of stores |
|
400 * @param error SmfNoError if success, else appropriate error value |
243 * @param resultPage Page number info |
401 * @param resultPage Page number info |
244 */ |
402 */ |
245 void storeSearchAvailable ( SmfProviderList* result, |
403 void storeSearchAvailable ( SmfProviderList* result, |
246 SmfError error, SmfResultPage resultPage ); |
404 SmfError error, SmfResultPage resultPage ); |
247 |
405 |
320 * When the list is big user can specify the page number and per page item data. |
479 * When the list is big user can specify the page number and per page item data. |
321 * If not supplied by the user default values are used. |
480 * If not supplied by the user default values are used. |
322 * @param user User for which to get the playlists |
481 * @param user User for which to get the playlists |
323 * @param pageNum Page number to download, SMF_FIRST_PAGE denotes fresh query. |
482 * @param pageNum Page number to download, SMF_FIRST_PAGE denotes fresh query. |
324 * @param perPage Item per page, default is SMF_ITEMS_PER_PAGE |
483 * @param perPage Item per page, default is SMF_ITEMS_PER_PAGE |
325 */ |
484 * @return SmfNoError if success, else appropriate error value |
326 void playlistsOf ( SmfMusicProfile* user, int pageNum = SMF_FIRST_PAGE, |
485 */ |
|
486 SmfError playlistsOf ( SmfContact* user, int pageNum = SMF_FIRST_PAGE, |
327 int perPage = SMF_ITEMS_PER_PAGE); |
487 int perPage = SMF_ITEMS_PER_PAGE); |
328 |
488 |
329 public slots: |
489 public slots: |
330 /** |
490 /** |
331 * Upload currently playing track to a playlist. Signal |
491 * Upload currently playing track to a playlist. Signal |
332 * playlistUpdated() can be checked for success value |
492 * playlistUpdated() can be checked for success value |
333 * @param plst The playlist to be added in |
493 * @param plst The playlist to be added in |
334 * @param tracks The list of tracks to uploaded |
494 * @param tracks The list of tracks to uploaded |
335 */ |
495 * @return SmfNoError if success, else appropriate error value |
336 int addToPlaylist ( SmfPlaylist plst, SmfTrackInfoList* tracks ); |
496 */ |
|
497 SmfError addToPlaylist ( SmfPlaylist plst, SmfTrackInfoList* tracks ); |
337 |
498 |
338 /** |
499 /** |
339 * Upload currently playing playlist . Signal |
500 * Upload currently playing playlist . Signal |
340 * playlistUpdated() can be checked for success value |
501 * playlistUpdated() can be checked for success value |
341 * @param plst The playlist to be uploaded |
502 * @param plst The playlist to be uploaded |
342 */ |
503 * @return SmfNoError if success, else appropriate error value |
343 int postCurrentPlayingPlaylist ( SmfPlaylist plst ); |
504 */ |
|
505 SmfError postCurrentPlayingPlaylist ( SmfPlaylist plst ); |
344 |
506 |
345 /** |
507 /** |
346 * Request for a custom operation. The signal customDataAvailable() is emitted |
508 * Request for a custom operation. The signal customDataAvailable() is emitted |
347 * when the result is available. |
509 * when the result is available. |
348 * @param operationId OperationId |
510 * @param operationId OperationId |
349 * @param customData Custom data to be sent |
511 * @param customData Custom data to be sent |
|
512 * @return SmfNoError if success, else appropriate error value |
350 * Note:-Interpretation of operationId and customData is upto the concerned |
513 * Note:-Interpretation of operationId and customData is upto the concerned |
351 * plugin and client application. service provider should provide some |
514 * plugin and client application. service provider should provide some |
352 * serializing-deserializing utilities for these custom data |
515 * serializing-deserializing utilities for these custom data |
353 */ |
516 */ |
354 void customRequest ( const int& operationId, QByteArray* customData ); |
517 SmfError customRequest ( const int& operationId, QByteArray* customData ); |
|
518 |
|
519 /** |
|
520 * Cancels a request generated due to the call to any API which results |
|
521 * into http request. Might return error if no request is currently pending. |
|
522 * Please note that there can be only one request pending at any point of time |
|
523 * @return Appropriate SmfError value |
|
524 */ |
|
525 SmfError cancelRequest (); |
355 |
526 |
356 signals: |
527 signals: |
357 /** |
528 /** |
358 * Notification of availability of list of playlists requested. |
529 * Notification of availability of list of playlists requested. |
359 * Note if number of list is large, then it can download the list page by page. |
530 * Note if number of list is large, then it can download the list page by page. |
360 * In that case this signal is emitted multiple times. |
531 * @param plst List of playlists |
|
532 * @param error, SmfNoError if success, else appropriate error value |
361 * @param resultPage Page number info |
533 * @param resultPage Page number info |
362 */ |
534 */ |
363 void playlistsListAvailable ( SmfPlaylistList*, |
535 void playlistsListAvailable ( SmfPlaylistList* plst, |
364 SmfError error, SmfResultPage resultPage ); |
536 SmfError error, SmfResultPage resultPage ); |
365 /** |
537 /** |
366 * Signals remote updation of playlist with success value |
538 * Signals remote updation of playlist with success value |
367 */ |
539 * @param error, SmfNoError if success, else appropriate error value |
368 void playlistUpdated ( SmfError success ); |
540 */ |
|
541 void playlistUpdated ( SmfError error ); |
369 |
542 |
370 /** |
543 /** |
371 * Signals availability of the result of the customRequest |
544 * Signals availability of the result of the customRequest |
372 * @param operationId The ID to be shared between clients and the plugin |
545 * @param operationId The ID to be shared between clients and the plugin |
373 * @param customData data |
546 * @param customData data |
387 |
560 |
388 }; |
561 }; |
389 |
562 |
390 SMF_SERVICE_NAME(SmfPlaylistService, "org.symbian.smf.client.music.playlist\0.2") |
563 SMF_SERVICE_NAME(SmfPlaylistService, "org.symbian.smf.client.music.playlist\0.2") |
391 |
564 |
392 |
|
393 /** |
|
394 * provides service ("org.symbian.smf.client.music.events") |
|
395 */ |
|
396 class SMFCLIENT_EXPORT SmfMusicEvents : public QObject |
|
397 { |
|
398 Q_OBJECT |
|
399 |
|
400 public: |
|
401 /** |
|
402 * Constructs SmfMusicEvents with base provider info |
|
403 * Seeing as this is a plug-in implementation, these will realistically |
|
404 * be generated by SMF factory of some kind |
|
405 */ |
|
406 SmfMusicEvents ( SmfProvider* baseProvider = 0 ); |
|
407 |
|
408 /** |
|
409 * Destructor |
|
410 */ |
|
411 ~SmfMusicEvents ( ); |
|
412 |
|
413 public: |
|
414 /** |
|
415 * Gets list of events in a particular venue asynchronously. |
|
416 * eventsAvailable() signal is emitted with SmfEventsList once its arrived. |
|
417 * When the list is big user can specify the page number and per page item data. |
|
418 * If not supplied by the user default values are used. |
|
419 * @param pageNum Page number to download, SMF_FIRST_PAGE denotes fresh query. |
|
420 * @param perPage Item per page, default is SMF_ITEMS_PER_PAGE |
|
421 */ |
|
422 void events ( SmfLocation venue, int pageNum = SMF_FIRST_PAGE, |
|
423 int perPage = SMF_ITEMS_PER_PAGE); |
|
424 |
|
425 /** |
|
426 * Gets list of venues of a particular location asynchronously. |
|
427 * venuesAvailable() signal is emitted with SmfLocationList once its arrived. |
|
428 * When the list is big user can specify the page number and per page item data. |
|
429 * If not supplied by the user default values are used. |
|
430 * @param pageNum Page number to download, SMF_FIRST_PAGE denotes fresh query. |
|
431 * @param perPage Item per page, default is SMF_ITEMS_PER_PAGE |
|
432 */ |
|
433 void venues ( SmfLocation location, int pageNum = SMF_FIRST_PAGE, |
|
434 int perPage = SMF_ITEMS_PER_PAGE); |
|
435 |
|
436 public slots: |
|
437 /** |
|
438 * Updates events. Might not be supported by all service provider. |
|
439 * eventsUpdated() signal can be checked for success value. |
|
440 * @param SmfEventsList List of events to be posted |
|
441 */ |
|
442 void postEvents ( SmfEventList events ); |
|
443 |
|
444 /** |
|
445 * Request for a custom operation. The signal customDataAvailable() is emitted |
|
446 * when the result is available. |
|
447 * @param operationId OperationId |
|
448 * @param customData Custom data to be sent |
|
449 * Note:-Interpretation of operationId and customData is upto the concerned |
|
450 * plugin and client application. service provider should provide some |
|
451 * serializing-deserializing utilities for these custom data |
|
452 */ |
|
453 void customRequest ( const int& operationId, QByteArray* customData ); |
|
454 |
|
455 signals: |
|
456 /** |
|
457 * Notification on arrival of event lists |
|
458 * Note if number of list is large, then it can download the list page by page. |
|
459 * In that case this signal is emitted multiple times. |
|
460 * @param resultPage Page number info |
|
461 */ |
|
462 void eventsAvailable ( SmfEventList* list, |
|
463 SmfError error, SmfResultPage resultPage ); |
|
464 |
|
465 /** |
|
466 * Notification on arrival of venues lists |
|
467 * Note if number of list is large, then it can download the list page by page. |
|
468 * In that case this signal is emitted multiple times. |
|
469 * @param resultPage Page number info |
|
470 */ |
|
471 void venuesAvailable ( SmfLocationList* list, |
|
472 SmfError error, SmfResultPage resultPage ); |
|
473 |
|
474 /** |
|
475 * Notification of the success of request to post an event |
|
476 */ |
|
477 void eventsUpdated ( SmfError success ); |
|
478 |
|
479 /** |
|
480 * Signals availability of the result of the customRequest |
|
481 * @param operationId The ID to be shared between clients and the plugin |
|
482 * @param customData data |
|
483 */ |
|
484 void customDataAvailable( const int& operationId, QByteArray* customData ); |
|
485 |
|
486 private: |
|
487 /** |
|
488 * Gets the base provider info |
|
489 */ |
|
490 SmfProvider* getProvider() const; |
|
491 |
|
492 private: |
|
493 SmfProvider* m_baseProvider; |
|
494 SmfMusicEventsPrivate* m_private; |
|
495 friend class SmfMusicEventsPrivate; |
|
496 |
|
497 }; |
|
498 |
|
499 SMF_SERVICE_NAME(SmfMusicEvents, "org.symbian.smf.client.music.events\0.2") |
|
500 |
565 |
501 |
566 |
502 /** |
567 /** |
503 * provides service ("org.symbian.smf.client.music.lyrics") |
568 * provides service ("org.symbian.smf.client.music.lyrics") |
504 */ |
569 */ |
522 * Get the lyrics lists asynchrnously, it fetches texts without time info. |
587 * Get the lyrics lists asynchrnously, it fetches texts without time info. |
523 * lyricsAvailable() notification comes SmfLyricsList with when the data is available |
588 * lyricsAvailable() notification comes SmfLyricsList with when the data is available |
524 * @param track Track for which lyrics needs to be fetched. |
589 * @param track Track for which lyrics needs to be fetched. |
525 * @param pageNum Page number to download, SMF_FIRST_PAGE denotes fresh query. |
590 * @param pageNum Page number to download, SMF_FIRST_PAGE denotes fresh query. |
526 * @param perPage Item per page, default is SMF_ITEMS_PER_PAGE |
591 * @param perPage Item per page, default is SMF_ITEMS_PER_PAGE |
527 */ |
592 * @return SmfNoError if success, else appropriate error value |
528 void lyrics ( SmfTrackInfo track, int pageNum = SMF_FIRST_PAGE, |
593 */ |
|
594 SmfError lyrics ( SmfTrackInfo track, int pageNum = SMF_FIRST_PAGE, |
529 int perPage = SMF_ITEMS_PER_PAGE); |
595 int perPage = SMF_ITEMS_PER_PAGE); |
530 |
596 |
531 /** |
597 /** |
532 * Get the lyrics lists asynchrnously, it fetches texts with time info. |
598 * Get the lyrics lists asynchrnously, it fetches texts with time info. |
533 * Subtitle search filter can be applied |
599 * Subtitle search filter can be applied |
534 * subtitleAvailable() notification comes SmfSubtitleList with when the data is available |
600 * subtitleAvailable() notification comes SmfSubtitleList with when the data is available |
535 * @param track Track for which subtitle needs to be fetched. |
601 * @param track Track for which subtitle needs to be fetched. |
536 * @param filter Subtitle search filter |
602 * @param filter Subtitle search filter |
537 * @param pageNum Page number to download, SMF_FIRST_PAGE denotes fresh query. |
603 * @param pageNum Page number to download, SMF_FIRST_PAGE denotes fresh query. |
538 * @param perPage Item per page, default is SMF_ITEMS_PER_PAGE |
604 * @param perPage Item per page, default is SMF_ITEMS_PER_PAGE |
539 */ |
605 * @return SmfNoError if success, else appropriate error value |
540 void subtitles ( SmfTrackInfo track, SmfSubtitleSearchFilter filter, |
606 */ |
|
607 SmfError subtitles ( SmfTrackInfo track, SmfSubtitleSearchFilter filter, |
541 int pageNum = SMF_FIRST_PAGE, int perPage = SMF_ITEMS_PER_PAGE); |
608 int pageNum = SMF_FIRST_PAGE, int perPage = SMF_ITEMS_PER_PAGE); |
542 |
609 |
543 /** |
610 /** |
544 * Request for a custom operation. The signal customDataAvailable() is emitted |
611 * Request for a custom operation. The signal customDataAvailable() is emitted |
545 * when the result is available. |
612 * when the result is available. |
546 * @param operationId OperationId |
613 * @param operationId OperationId |
547 * @param customData Custom data to be sent |
614 * @param customData Custom data to be sent |
|
615 * @return SmfNoError if success, else appropriate error value |
548 * Note:-Interpretation of operationId and customData is upto the concerned |
616 * Note:-Interpretation of operationId and customData is upto the concerned |
549 * plugin and client application. service provider should provide some |
617 * plugin and client application. service provider should provide some |
550 * serializing-deserializing utilities for these custom data |
618 * serializing-deserializing utilities for these custom data |
551 */ |
619 */ |
552 void customRequest ( const int& operationId, QByteArray* customData ); |
620 SmfError customRequest ( const int& operationId, QByteArray* customData ); |
|
621 |
|
622 /** |
|
623 * Cancels a request generated due to the call to any API which results |
|
624 * into http request. Might return error if no request is currently pending. |
|
625 * Please note that there can be only one request pending at any point of time |
|
626 * @return Appropriate SmfError value |
|
627 */ |
|
628 SmfError cancelRequest (); |
553 |
629 |
554 signals: |
630 signals: |
555 /** |
631 /** |
556 * Notification on arrival of lyrics |
632 * Notification on arrival of lyrics |
557 * Note if the list is large, then it can download the list page by page. |
633 * Note if the list is large, then it can download the list page by page. |
558 * In that case this signal is emitted multiple times. |
634 * @param list List of lyrics |
|
635 * @param error SmfNoError if success, else appropriate error value |
559 * @param resultPage Page number info |
636 * @param resultPage Page number info |
560 */ |
637 */ |
561 void lyricsAvailable ( SmfLyricsList* list, |
638 void lyricsAvailable ( SmfLyricsList* list, |
562 SmfError error, SmfResultPage resultPage ); |
639 SmfError error, SmfResultPage resultPage ); |
563 |
640 |
564 /** |
641 /** |
565 * Notification on arrival of subtitle based on filter. |
642 * Notification on arrival of subtitle based on filter. |
566 * Note if the list is large, then it can download the list page by page. |
643 * Note if the list is large, then it can download the list page by page. |
567 * In that case this signal is emitted multiple times. |
644 * @param list List of subtitles |
|
645 * @param error SmfNoError if success, else appropriate error value |
568 * @param resultPage Page number info |
646 * @param resultPage Page number info |
569 */ |
647 */ |
570 void subtitleAvailable ( SmfSubtitleList* list, |
648 void subtitleAvailable ( SmfSubtitleList* list, |
571 SmfError error, SmfResultPage resultPage ); |
649 SmfError error, SmfResultPage resultPage ); |
572 |
650 |