|
1 /** |
|
2 * Copyright (c) 2010 Sasken Communication Technologies Ltd. |
|
3 * All rights reserved. |
|
4 * This component and the accompanying materials are made available |
|
5 * under the terms of the "Eclipse Public License v1.0" |
|
6 * which accompanies this distribution, and is available |
|
7 * at the URL "http://www.eclipse.org/legal/epl-v10.html" |
|
8 * |
|
9 * Initial Contributors: |
|
10 * Chandradeep Gandhi, Sasken Communication Technologies Ltd - Initial contribution |
|
11 * |
|
12 * Contributors: |
|
13 * Manasij Roy, Nalina Hariharan |
|
14 * |
|
15 * Description: |
|
16 * Interface specification for music track lyrics |
|
17 * |
|
18 */ |
|
19 |
|
20 |
|
21 #ifndef SMFLYRICSSERVICEPLUGIN_H_ |
|
22 #define SMFLYRICSSERVICEPLUGIN_H_ |
|
23 |
|
24 #include <smfpluginbase.h> |
|
25 #include <smftrackinfo.h> |
|
26 #include <QString> |
|
27 #include <smfsubtitle.h> |
|
28 #include <smflyrics.h> |
|
29 |
|
30 // Forward declaration |
|
31 class SmfPluginManagerUtil; |
|
32 |
|
33 /** |
|
34 * @ingroup smf_plugin_group |
|
35 * Interface specification for music track lyrics |
|
36 * |
|
37 * All of the functionality described here should be implemented by a service |
|
38 * specific plug-in. |
|
39 */ |
|
40 class SmfLyricsServicePlugin : public SmfPluginBase |
|
41 { |
|
42 Q_OBJECT |
|
43 public: |
|
44 /** |
|
45 * Constructor with default argument |
|
46 * @param aUtil The SmfPluginManagerUtil instance. The plugins can |
|
47 * call the method getAuthKeys() of this class, with its pluginID to |
|
48 * get the OAuth keys, keys are returned only if this plugin is |
|
49 * authorised by Smf franework |
|
50 */ |
|
51 SmfLyricsServicePlugin( SmfPluginManagerUtil* aUtil ); |
|
52 |
|
53 /** |
|
54 * Destructor |
|
55 */ |
|
56 ~SmfLyricsServicePlugin( ); |
|
57 |
|
58 /** |
|
59 * Method to get the lyrics |
|
60 * @param aRequest [out] The request data to be sent to network |
|
61 * @param aTrack The track whose lyrics need to be fetched |
|
62 * @param aPageNum The page to be extracted |
|
63 * @param aItemsPerPage Number of items per page |
|
64 * @return SmfPluginError Plugin error if any, else SmfPluginErrNone |
|
65 */ |
|
66 virtual SmfPluginError lyrics( SmfPluginRequestData &aRequest, |
|
67 const SmfTrackInfo &aTrack, |
|
68 const int aPageNum = SMF_FIRST_PAGE, |
|
69 const int aItemsPerPage = SMF_ITEMS_PER_PAGE ) = 0; |
|
70 |
|
71 /** |
|
72 * Method to get the subtitle |
|
73 * @param aRequest [out] The request data to be sent to network |
|
74 * @param aTrack The track whose subtitle need to be fetched |
|
75 * @param aFilter The subtitle search filter if any |
|
76 * @param aPageNum The page to be extracted |
|
77 * @param aItemsPerPage Number of items per page |
|
78 * @return SmfPluginError Plugin error if any, else SmfPluginErrNone |
|
79 */ |
|
80 virtual SmfPluginError subtitles( SmfPluginRequestData &aRequest, |
|
81 const SmfTrackInfo &aTrack, |
|
82 const SmfSubtitleSearchFilter &aFilter = SubtitleAll, |
|
83 const int aPageNum = SMF_FIRST_PAGE, |
|
84 const int aItemsPerPage = SMF_ITEMS_PER_PAGE ) = 0; |
|
85 |
|
86 }; |
|
87 |
|
88 Q_DECLARE_INTERFACE( SmfLyricsServicePlugin, "org.symbian.smf.plugin.music.lyrics/v1.0" ); |
|
89 |
|
90 #endif /* SMFLYRICSSERVICEPLUGIN_H_ */ |