smf/smfservermodule/smfclient/client/smfmusic.h
author cgandhi <chandradeep.gandhi@sasken.com>
Wed, 23 Jun 2010 20:47:13 +0530
changeset 15 9b00ca3cc206
parent 14 a469c0e6e7fb
permissions -rw-r--r--
Adding missing settings.ui file
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
8
4102c67b6e56 Restoring the missing activity related and music headers
cgandhi <chandradeep.gandhi@sasken.com>
parents:
diff changeset
     1
/**
4102c67b6e56 Restoring the missing activity related and music headers
cgandhi <chandradeep.gandhi@sasken.com>
parents:
diff changeset
     2
 * Copyright (c) 2010 Sasken Communication Technologies Ltd.
4102c67b6e56 Restoring the missing activity related and music headers
cgandhi <chandradeep.gandhi@sasken.com>
parents:
diff changeset
     3
 * All rights reserved.
4102c67b6e56 Restoring the missing activity related and music headers
cgandhi <chandradeep.gandhi@sasken.com>
parents:
diff changeset
     4
 * This component and the accompanying materials are made available
4102c67b6e56 Restoring the missing activity related and music headers
cgandhi <chandradeep.gandhi@sasken.com>
parents:
diff changeset
     5
 * under the terms of the "Eclipse Public License v1.0"
4102c67b6e56 Restoring the missing activity related and music headers
cgandhi <chandradeep.gandhi@sasken.com>
parents:
diff changeset
     6
 * which accompanies  this distribution, and is available
4102c67b6e56 Restoring the missing activity related and music headers
cgandhi <chandradeep.gandhi@sasken.com>
parents:
diff changeset
     7
 * at the URL "http://www.eclipse.org/legal/epl-v10.html"
4102c67b6e56 Restoring the missing activity related and music headers
cgandhi <chandradeep.gandhi@sasken.com>
parents:
diff changeset
     8
 *
4102c67b6e56 Restoring the missing activity related and music headers
cgandhi <chandradeep.gandhi@sasken.com>
parents:
diff changeset
     9
 * Initial Contributors:
4102c67b6e56 Restoring the missing activity related and music headers
cgandhi <chandradeep.gandhi@sasken.com>
parents:
diff changeset
    10
 * Chandradeep Gandhi, Sasken Communication Technologies Ltd - Initial contribution
4102c67b6e56 Restoring the missing activity related and music headers
cgandhi <chandradeep.gandhi@sasken.com>
parents:
diff changeset
    11
 *
4102c67b6e56 Restoring the missing activity related and music headers
cgandhi <chandradeep.gandhi@sasken.com>
parents:
diff changeset
    12
 * Contributors:
4102c67b6e56 Restoring the missing activity related and music headers
cgandhi <chandradeep.gandhi@sasken.com>
parents:
diff changeset
    13
 * Manasij Roy, Nalina Hariharan
4102c67b6e56 Restoring the missing activity related and music headers
cgandhi <chandradeep.gandhi@sasken.com>
parents:
diff changeset
    14
 *
4102c67b6e56 Restoring the missing activity related and music headers
cgandhi <chandradeep.gandhi@sasken.com>
parents:
diff changeset
    15
 * Description:
14
a469c0e6e7fb changes for SmfPost, SmfCredentialMgr, PLuginManager, SmfServer. Adding Sample Plugins and Sample Client Applications.
cgandhi <chandradeep.gandhi@sasken.com>
parents: 8
diff changeset
    16
 * Music related services
8
4102c67b6e56 Restoring the missing activity related and music headers
cgandhi <chandradeep.gandhi@sasken.com>
parents:
diff changeset
    17
 *
4102c67b6e56 Restoring the missing activity related and music headers
cgandhi <chandradeep.gandhi@sasken.com>
parents:
diff changeset
    18
 */
4102c67b6e56 Restoring the missing activity related and music headers
cgandhi <chandradeep.gandhi@sasken.com>
parents:
diff changeset
    19
4102c67b6e56 Restoring the missing activity related and music headers
cgandhi <chandradeep.gandhi@sasken.com>
parents:
diff changeset
    20
#ifndef SMFMUSIC_H
14
a469c0e6e7fb changes for SmfPost, SmfCredentialMgr, PLuginManager, SmfServer. Adding Sample Plugins and Sample Client Applications.
cgandhi <chandradeep.gandhi@sasken.com>
parents: 8
diff changeset
    21
#define SMFMUSIC_H
8
4102c67b6e56 Restoring the missing activity related and music headers
cgandhi <chandradeep.gandhi@sasken.com>
parents:
diff changeset
    22
4102c67b6e56 Restoring the missing activity related and music headers
cgandhi <chandradeep.gandhi@sasken.com>
parents:
diff changeset
    23
#include <qmobilityglobal.h>
4102c67b6e56 Restoring the missing activity related and music headers
cgandhi <chandradeep.gandhi@sasken.com>
parents:
diff changeset
    24
#include <qgeopositioninfo.h>
4102c67b6e56 Restoring the missing activity related and music headers
cgandhi <chandradeep.gandhi@sasken.com>
parents:
diff changeset
    25
#include "smfglobal.h"
4102c67b6e56 Restoring the missing activity related and music headers
cgandhi <chandradeep.gandhi@sasken.com>
parents:
diff changeset
    26
#include "smfprovider.h"
4102c67b6e56 Restoring the missing activity related and music headers
cgandhi <chandradeep.gandhi@sasken.com>
parents:
diff changeset
    27
#include "smfcontact.h"
4102c67b6e56 Restoring the missing activity related and music headers
cgandhi <chandradeep.gandhi@sasken.com>
parents:
diff changeset
    28
#include "smfevent.h"
14
a469c0e6e7fb changes for SmfPost, SmfCredentialMgr, PLuginManager, SmfServer. Adding Sample Plugins and Sample Client Applications.
cgandhi <chandradeep.gandhi@sasken.com>
parents: 8
diff changeset
    29
#include "smfmusicfingerprint.h"
a469c0e6e7fb changes for SmfPost, SmfCredentialMgr, PLuginManager, SmfServer. Adding Sample Plugins and Sample Client Applications.
cgandhi <chandradeep.gandhi@sasken.com>
parents: 8
diff changeset
    30
#include "smfmusicrating.h"
a469c0e6e7fb changes for SmfPost, SmfCredentialMgr, PLuginManager, SmfServer. Adding Sample Plugins and Sample Client Applications.
cgandhi <chandradeep.gandhi@sasken.com>
parents: 8
diff changeset
    31
#include "smfcomment.h"
a469c0e6e7fb changes for SmfPost, SmfCredentialMgr, PLuginManager, SmfServer. Adding Sample Plugins and Sample Client Applications.
cgandhi <chandradeep.gandhi@sasken.com>
parents: 8
diff changeset
    32
#include "smfsubtitle.h"
8
4102c67b6e56 Restoring the missing activity related and music headers
cgandhi <chandradeep.gandhi@sasken.com>
parents:
diff changeset
    33
14
a469c0e6e7fb changes for SmfPost, SmfCredentialMgr, PLuginManager, SmfServer. Adding Sample Plugins and Sample Client Applications.
cgandhi <chandradeep.gandhi@sasken.com>
parents: 8
diff changeset
    34
#include "smfmusicprofile.h"
a469c0e6e7fb changes for SmfPost, SmfCredentialMgr, PLuginManager, SmfServer. Adding Sample Plugins and Sample Client Applications.
cgandhi <chandradeep.gandhi@sasken.com>
parents: 8
diff changeset
    35
#include "smfalbum.h"
a469c0e6e7fb changes for SmfPost, SmfCredentialMgr, PLuginManager, SmfServer. Adding Sample Plugins and Sample Client Applications.
cgandhi <chandradeep.gandhi@sasken.com>
parents: 8
diff changeset
    36
#include "smfartists.h"
a469c0e6e7fb changes for SmfPost, SmfCredentialMgr, PLuginManager, SmfServer. Adding Sample Plugins and Sample Client Applications.
cgandhi <chandradeep.gandhi@sasken.com>
parents: 8
diff changeset
    37
#include "smfgroup.h"
a469c0e6e7fb changes for SmfPost, SmfCredentialMgr, PLuginManager, SmfServer. Adding Sample Plugins and Sample Client Applications.
cgandhi <chandradeep.gandhi@sasken.com>
parents: 8
diff changeset
    38
#include "smflyrics.h"
a469c0e6e7fb changes for SmfPost, SmfCredentialMgr, PLuginManager, SmfServer. Adding Sample Plugins and Sample Client Applications.
cgandhi <chandradeep.gandhi@sasken.com>
parents: 8
diff changeset
    39
#include "smfplaylist.h"
a469c0e6e7fb changes for SmfPost, SmfCredentialMgr, PLuginManager, SmfServer. Adding Sample Plugins and Sample Client Applications.
cgandhi <chandradeep.gandhi@sasken.com>
parents: 8
diff changeset
    40
#include "smftrackinfo.h"
a469c0e6e7fb changes for SmfPost, SmfCredentialMgr, PLuginManager, SmfServer. Adding Sample Plugins and Sample Client Applications.
cgandhi <chandradeep.gandhi@sasken.com>
parents: 8
diff changeset
    41
#include "smflocation.h"
a469c0e6e7fb changes for SmfPost, SmfCredentialMgr, PLuginManager, SmfServer. Adding Sample Plugins and Sample Client Applications.
cgandhi <chandradeep.gandhi@sasken.com>
parents: 8
diff changeset
    42
class SmfMusicServicePrivate;
a469c0e6e7fb changes for SmfPost, SmfCredentialMgr, PLuginManager, SmfServer. Adding Sample Plugins and Sample Client Applications.
cgandhi <chandradeep.gandhi@sasken.com>
parents: 8
diff changeset
    43
class SmfMusicSearchPrivate;
a469c0e6e7fb changes for SmfPost, SmfCredentialMgr, PLuginManager, SmfServer. Adding Sample Plugins and Sample Client Applications.
cgandhi <chandradeep.gandhi@sasken.com>
parents: 8
diff changeset
    44
class SmfLyricsServicePrivate;
a469c0e6e7fb changes for SmfPost, SmfCredentialMgr, PLuginManager, SmfServer. Adding Sample Plugins and Sample Client Applications.
cgandhi <chandradeep.gandhi@sasken.com>
parents: 8
diff changeset
    45
class SmfPlaylistServicePrivate;
a469c0e6e7fb changes for SmfPost, SmfCredentialMgr, PLuginManager, SmfServer. Adding Sample Plugins and Sample Client Applications.
cgandhi <chandradeep.gandhi@sasken.com>
parents: 8
diff changeset
    46
class SmfMusicEventsPrivate;
a469c0e6e7fb changes for SmfPost, SmfCredentialMgr, PLuginManager, SmfServer. Adding Sample Plugins and Sample Client Applications.
cgandhi <chandradeep.gandhi@sasken.com>
parents: 8
diff changeset
    47
a469c0e6e7fb changes for SmfPost, SmfCredentialMgr, PLuginManager, SmfServer. Adding Sample Plugins and Sample Client Applications.
cgandhi <chandradeep.gandhi@sasken.com>
parents: 8
diff changeset
    48
using namespace QtMobility;
8
4102c67b6e56 Restoring the missing activity related and music headers
cgandhi <chandradeep.gandhi@sasken.com>
parents:
diff changeset
    49
4102c67b6e56 Restoring the missing activity related and music headers
cgandhi <chandradeep.gandhi@sasken.com>
parents:
diff changeset
    50
typedef QList<SmfMusicProfile> SmfMusicProfileList;
4102c67b6e56 Restoring the missing activity related and music headers
cgandhi <chandradeep.gandhi@sasken.com>
parents:
diff changeset
    51
typedef QList<SmfTrackInfo> SmfTrackInfoList;
4102c67b6e56 Restoring the missing activity related and music headers
cgandhi <chandradeep.gandhi@sasken.com>
parents:
diff changeset
    52
typedef QList<SmfPlaylist> SmfPlaylistList;
4102c67b6e56 Restoring the missing activity related and music headers
cgandhi <chandradeep.gandhi@sasken.com>
parents:
diff changeset
    53
typedef QList<SmfLyrics> SmfLyricsList;
4102c67b6e56 Restoring the missing activity related and music headers
cgandhi <chandradeep.gandhi@sasken.com>
parents:
diff changeset
    54
typedef QList<SmfSubtitle> SmfSubtitleList;
4102c67b6e56 Restoring the missing activity related and music headers
cgandhi <chandradeep.gandhi@sasken.com>
parents:
diff changeset
    55
/**
4102c67b6e56 Restoring the missing activity related and music headers
cgandhi <chandradeep.gandhi@sasken.com>
parents:
diff changeset
    56
 * @ingroup smf_client_group
4102c67b6e56 Restoring the missing activity related and music headers
cgandhi <chandradeep.gandhi@sasken.com>
parents:
diff changeset
    57
  * Basic music service ("org.symbian.smf.client.music.service")
4102c67b6e56 Restoring the missing activity related and music headers
cgandhi <chandradeep.gandhi@sasken.com>
parents:
diff changeset
    58
  */
4102c67b6e56 Restoring the missing activity related and music headers
cgandhi <chandradeep.gandhi@sasken.com>
parents:
diff changeset
    59
class SMFCLIENT_EXPORT SmfMusicService : public QObject
4102c67b6e56 Restoring the missing activity related and music headers
cgandhi <chandradeep.gandhi@sasken.com>
parents:
diff changeset
    60
{
4102c67b6e56 Restoring the missing activity related and music headers
cgandhi <chandradeep.gandhi@sasken.com>
parents:
diff changeset
    61
  Q_OBJECT
4102c67b6e56 Restoring the missing activity related and music headers
cgandhi <chandradeep.gandhi@sasken.com>
parents:
diff changeset
    62
4102c67b6e56 Restoring the missing activity related and music headers
cgandhi <chandradeep.gandhi@sasken.com>
parents:
diff changeset
    63
public:
4102c67b6e56 Restoring the missing activity related and music headers
cgandhi <chandradeep.gandhi@sasken.com>
parents:
diff changeset
    64
  /**
4102c67b6e56 Restoring the missing activity related and music headers
cgandhi <chandradeep.gandhi@sasken.com>
parents:
diff changeset
    65
   * Constructs SmfMusicService.
4102c67b6e56 Restoring the missing activity related and music headers
cgandhi <chandradeep.gandhi@sasken.com>
parents:
diff changeset
    66
   * @param baseProvider The base provider info
4102c67b6e56 Restoring the missing activity related and music headers
cgandhi <chandradeep.gandhi@sasken.com>
parents:
diff changeset
    67
   * Seeing as this is a plug-in implementation, these will realistically
14
a469c0e6e7fb changes for SmfPost, SmfCredentialMgr, PLuginManager, SmfServer. Adding Sample Plugins and Sample Client Applications.
cgandhi <chandradeep.gandhi@sasken.com>
parents: 8
diff changeset
    68
   *  be generated by SMF factory of some kind
8
4102c67b6e56 Restoring the missing activity related and music headers
cgandhi <chandradeep.gandhi@sasken.com>
parents:
diff changeset
    69
   */
4102c67b6e56 Restoring the missing activity related and music headers
cgandhi <chandradeep.gandhi@sasken.com>
parents:
diff changeset
    70
   SmfMusicService(SmfProvider* baseProvider = 0);
4102c67b6e56 Restoring the missing activity related and music headers
cgandhi <chandradeep.gandhi@sasken.com>
parents:
diff changeset
    71
  ~SmfMusicService();
4102c67b6e56 Restoring the missing activity related and music headers
cgandhi <chandradeep.gandhi@sasken.com>
parents:
diff changeset
    72
14
a469c0e6e7fb changes for SmfPost, SmfCredentialMgr, PLuginManager, SmfServer. Adding Sample Plugins and Sample Client Applications.
cgandhi <chandradeep.gandhi@sasken.com>
parents: 8
diff changeset
    73
public slots:
8
4102c67b6e56 Restoring the missing activity related and music headers
cgandhi <chandradeep.gandhi@sasken.com>
parents:
diff changeset
    74
4102c67b6e56 Restoring the missing activity related and music headers
cgandhi <chandradeep.gandhi@sasken.com>
parents:
diff changeset
    75
  /**
4102c67b6e56 Restoring the missing activity related and music headers
cgandhi <chandradeep.gandhi@sasken.com>
parents:
diff changeset
    76
   * Gets self profile information asynchronously.
14
a469c0e6e7fb changes for SmfPost, SmfCredentialMgr, PLuginManager, SmfServer. Adding Sample Plugins and Sample Client Applications.
cgandhi <chandradeep.gandhi@sasken.com>
parents: 8
diff changeset
    77
   * userInfoAvailable() signal is emitted with SmfMusicProfile when the info is arrived
8
4102c67b6e56 Restoring the missing activity related and music headers
cgandhi <chandradeep.gandhi@sasken.com>
parents:
diff changeset
    78
   */
4102c67b6e56 Restoring the missing activity related and music headers
cgandhi <chandradeep.gandhi@sasken.com>
parents:
diff changeset
    79
  void userinfo() ;
4102c67b6e56 Restoring the missing activity related and music headers
cgandhi <chandradeep.gandhi@sasken.com>
parents:
diff changeset
    80
4102c67b6e56 Restoring the missing activity related and music headers
cgandhi <chandradeep.gandhi@sasken.com>
parents:
diff changeset
    81
  /**
4102c67b6e56 Restoring the missing activity related and music headers
cgandhi <chandradeep.gandhi@sasken.com>
parents:
diff changeset
    82
   * Asynchronously searches information about other service users for a particular venue
4102c67b6e56 Restoring the missing activity related and music headers
cgandhi <chandradeep.gandhi@sasken.com>
parents:
diff changeset
    83
   * searchInfoAvailable() signal is emitted with SmfMusicProfileList when the info is arrived.
4102c67b6e56 Restoring the missing activity related and music headers
cgandhi <chandradeep.gandhi@sasken.com>
parents:
diff changeset
    84
   * When the list is big user can specify the page number and per page item data.
4102c67b6e56 Restoring the missing activity related and music headers
cgandhi <chandradeep.gandhi@sasken.com>
parents:
diff changeset
    85
   * If not supplied by the user default values are used.
4102c67b6e56 Restoring the missing activity related and music headers
cgandhi <chandradeep.gandhi@sasken.com>
parents:
diff changeset
    86
   * @param pageNum Page number to download, SMF_FIRST_PAGE denotes fresh query.
14
a469c0e6e7fb changes for SmfPost, SmfCredentialMgr, PLuginManager, SmfServer. Adding Sample Plugins and Sample Client Applications.
cgandhi <chandradeep.gandhi@sasken.com>
parents: 8
diff changeset
    87
   * @param perPage Item per page, default is SMF_ITEMS_PER_PAGE
8
4102c67b6e56 Restoring the missing activity related and music headers
cgandhi <chandradeep.gandhi@sasken.com>
parents:
diff changeset
    88
   */
14
a469c0e6e7fb changes for SmfPost, SmfCredentialMgr, PLuginManager, SmfServer. Adding Sample Plugins and Sample Client Applications.
cgandhi <chandradeep.gandhi@sasken.com>
parents: 8
diff changeset
    89
  void searchUser(SmfLocation venue,int pageNum=SMF_FIRST_PAGE,int perPage=SMF_ITEMS_PER_PAGE) ;
8
4102c67b6e56 Restoring the missing activity related and music headers
cgandhi <chandradeep.gandhi@sasken.com>
parents:
diff changeset
    90
4102c67b6e56 Restoring the missing activity related and music headers
cgandhi <chandradeep.gandhi@sasken.com>
parents:
diff changeset
    91
  /**
4102c67b6e56 Restoring the missing activity related and music headers
cgandhi <chandradeep.gandhi@sasken.com>
parents:
diff changeset
    92
   * Gets the base provider info
4102c67b6e56 Restoring the missing activity related and music headers
cgandhi <chandradeep.gandhi@sasken.com>
parents:
diff changeset
    93
   */
4102c67b6e56 Restoring the missing activity related and music headers
cgandhi <chandradeep.gandhi@sasken.com>
parents:
diff changeset
    94
  SmfProvider* getProvider() ;
4102c67b6e56 Restoring the missing activity related and music headers
cgandhi <chandradeep.gandhi@sasken.com>
parents:
diff changeset
    95
4102c67b6e56 Restoring the missing activity related and music headers
cgandhi <chandradeep.gandhi@sasken.com>
parents:
diff changeset
    96
4102c67b6e56 Restoring the missing activity related and music headers
cgandhi <chandradeep.gandhi@sasken.com>
parents:
diff changeset
    97
signals:
4102c67b6e56 Restoring the missing activity related and music headers
cgandhi <chandradeep.gandhi@sasken.com>
parents:
diff changeset
    98
	/**
4102c67b6e56 Restoring the missing activity related and music headers
cgandhi <chandradeep.gandhi@sasken.com>
parents:
diff changeset
    99
	 * Notification on arrival of the self profile as result of userinfo().
14
a469c0e6e7fb changes for SmfPost, SmfCredentialMgr, PLuginManager, SmfServer. Adding Sample Plugins and Sample Client Applications.
cgandhi <chandradeep.gandhi@sasken.com>
parents: 8
diff changeset
   100
	 * @param profile The self profile
8
4102c67b6e56 Restoring the missing activity related and music headers
cgandhi <chandradeep.gandhi@sasken.com>
parents:
diff changeset
   101
	 */
14
a469c0e6e7fb changes for SmfPost, SmfCredentialMgr, PLuginManager, SmfServer. Adding Sample Plugins and Sample Client Applications.
cgandhi <chandradeep.gandhi@sasken.com>
parents: 8
diff changeset
   102
	void userInfoAvailable(SmfMusicProfile* profile, SmfError error);
a469c0e6e7fb changes for SmfPost, SmfCredentialMgr, PLuginManager, SmfServer. Adding Sample Plugins and Sample Client Applications.
cgandhi <chandradeep.gandhi@sasken.com>
parents: 8
diff changeset
   103
	/**
a469c0e6e7fb changes for SmfPost, SmfCredentialMgr, PLuginManager, SmfServer. Adding Sample Plugins and Sample Client Applications.
cgandhi <chandradeep.gandhi@sasken.com>
parents: 8
diff changeset
   104
	 * Notification on arrival of search info
a469c0e6e7fb changes for SmfPost, SmfCredentialMgr, PLuginManager, SmfServer. Adding Sample Plugins and Sample Client Applications.
cgandhi <chandradeep.gandhi@sasken.com>
parents: 8
diff changeset
   105
	 * @param profileList List of music profiles
a469c0e6e7fb changes for SmfPost, SmfCredentialMgr, PLuginManager, SmfServer. Adding Sample Plugins and Sample Client Applications.
cgandhi <chandradeep.gandhi@sasken.com>
parents: 8
diff changeset
   106
	 */
a469c0e6e7fb changes for SmfPost, SmfCredentialMgr, PLuginManager, SmfServer. Adding Sample Plugins and Sample Client Applications.
cgandhi <chandradeep.gandhi@sasken.com>
parents: 8
diff changeset
   107
	void searchInfoAvailable(SmfMusicProfileList& profileList, SmfError error,SmfResultPage resultPage);
8
4102c67b6e56 Restoring the missing activity related and music headers
cgandhi <chandradeep.gandhi@sasken.com>
parents:
diff changeset
   108
private:
4102c67b6e56 Restoring the missing activity related and music headers
cgandhi <chandradeep.gandhi@sasken.com>
parents:
diff changeset
   109
  SmfProvider* m_baseProvider;
14
a469c0e6e7fb changes for SmfPost, SmfCredentialMgr, PLuginManager, SmfServer. Adding Sample Plugins and Sample Client Applications.
cgandhi <chandradeep.gandhi@sasken.com>
parents: 8
diff changeset
   110
  SmfMusicServicePrivate* m_private;
a469c0e6e7fb changes for SmfPost, SmfCredentialMgr, PLuginManager, SmfServer. Adding Sample Plugins and Sample Client Applications.
cgandhi <chandradeep.gandhi@sasken.com>
parents: 8
diff changeset
   111
  friend class SmfMusicServicePrivate;
8
4102c67b6e56 Restoring the missing activity related and music headers
cgandhi <chandradeep.gandhi@sasken.com>
parents:
diff changeset
   112
};
4102c67b6e56 Restoring the missing activity related and music headers
cgandhi <chandradeep.gandhi@sasken.com>
parents:
diff changeset
   113
SMF_SERVICE_NAME(SmfMusicService, "org.symbian.smf.client.music.service\0.2")
4102c67b6e56 Restoring the missing activity related and music headers
cgandhi <chandradeep.gandhi@sasken.com>
parents:
diff changeset
   114
4102c67b6e56 Restoring the missing activity related and music headers
cgandhi <chandradeep.gandhi@sasken.com>
parents:
diff changeset
   115
4102c67b6e56 Restoring the missing activity related and music headers
cgandhi <chandradeep.gandhi@sasken.com>
parents:
diff changeset
   116
/**
4102c67b6e56 Restoring the missing activity related and music headers
cgandhi <chandradeep.gandhi@sasken.com>
parents:
diff changeset
   117
* Provides service ("org.symbian.smf.client.music.search") for music search
4102c67b6e56 Restoring the missing activity related and music headers
cgandhi <chandradeep.gandhi@sasken.com>
parents:
diff changeset
   118
*/
4102c67b6e56 Restoring the missing activity related and music headers
cgandhi <chandradeep.gandhi@sasken.com>
parents:
diff changeset
   119
class SMFCLIENT_EXPORT SmfMusicSearch : public QObject
4102c67b6e56 Restoring the missing activity related and music headers
cgandhi <chandradeep.gandhi@sasken.com>
parents:
diff changeset
   120
{
4102c67b6e56 Restoring the missing activity related and music headers
cgandhi <chandradeep.gandhi@sasken.com>
parents:
diff changeset
   121
  Q_OBJECT
4102c67b6e56 Restoring the missing activity related and music headers
cgandhi <chandradeep.gandhi@sasken.com>
parents:
diff changeset
   122
4102c67b6e56 Restoring the missing activity related and music headers
cgandhi <chandradeep.gandhi@sasken.com>
parents:
diff changeset
   123
public:
4102c67b6e56 Restoring the missing activity related and music headers
cgandhi <chandradeep.gandhi@sasken.com>
parents:
diff changeset
   124
  /**
4102c67b6e56 Restoring the missing activity related and music headers
cgandhi <chandradeep.gandhi@sasken.com>
parents:
diff changeset
   125
   * Constructs SmfMusicSearch with base provider as arguement.
4102c67b6e56 Restoring the missing activity related and music headers
cgandhi <chandradeep.gandhi@sasken.com>
parents:
diff changeset
   126
   * Seeing as this is a plug-in implementation, these will realistically
14
a469c0e6e7fb changes for SmfPost, SmfCredentialMgr, PLuginManager, SmfServer. Adding Sample Plugins and Sample Client Applications.
cgandhi <chandradeep.gandhi@sasken.com>
parents: 8
diff changeset
   127
   * be generated by SMF factory of some kind
8
4102c67b6e56 Restoring the missing activity related and music headers
cgandhi <chandradeep.gandhi@sasken.com>
parents:
diff changeset
   128
   */
4102c67b6e56 Restoring the missing activity related and music headers
cgandhi <chandradeep.gandhi@sasken.com>
parents:
diff changeset
   129
4102c67b6e56 Restoring the missing activity related and music headers
cgandhi <chandradeep.gandhi@sasken.com>
parents:
diff changeset
   130
  SmfMusicSearch(SmfProvider* baseProvider = 0);
4102c67b6e56 Restoring the missing activity related and music headers
cgandhi <chandradeep.gandhi@sasken.com>
parents:
diff changeset
   131
  ~SmfMusicSearch();
4102c67b6e56 Restoring the missing activity related and music headers
cgandhi <chandradeep.gandhi@sasken.com>
parents:
diff changeset
   132
4102c67b6e56 Restoring the missing activity related and music headers
cgandhi <chandradeep.gandhi@sasken.com>
parents:
diff changeset
   133
public:
4102c67b6e56 Restoring the missing activity related and music headers
cgandhi <chandradeep.gandhi@sasken.com>
parents:
diff changeset
   134
  /**
4102c67b6e56 Restoring the missing activity related and music headers
cgandhi <chandradeep.gandhi@sasken.com>
parents:
diff changeset
   135
   * Searches for music recommendations similar to a particulartrack asynchronously.
4102c67b6e56 Restoring the missing activity related and music headers
cgandhi <chandradeep.gandhi@sasken.com>
parents:
diff changeset
   136
   * The signal trackSearchAvailable() is emitted with SmfTrackInfoList
4102c67b6e56 Restoring the missing activity related and music headers
cgandhi <chandradeep.gandhi@sasken.com>
parents:
diff changeset
   137
   * once its arrived.
4102c67b6e56 Restoring the missing activity related and music headers
cgandhi <chandradeep.gandhi@sasken.com>
parents:
diff changeset
   138
   * When the list is big user can specify the page number and per page item data.
4102c67b6e56 Restoring the missing activity related and music headers
cgandhi <chandradeep.gandhi@sasken.com>
parents:
diff changeset
   139
   * If not supplied by the user default values are used.
4102c67b6e56 Restoring the missing activity related and music headers
cgandhi <chandradeep.gandhi@sasken.com>
parents:
diff changeset
   140
   * @param track The track for which similar recommendations need to be fetched.
4102c67b6e56 Restoring the missing activity related and music headers
cgandhi <chandradeep.gandhi@sasken.com>
parents:
diff changeset
   141
   * @param pageNum Page number to download, SMF_FIRST_PAGE denotes fresh query.
14
a469c0e6e7fb changes for SmfPost, SmfCredentialMgr, PLuginManager, SmfServer. Adding Sample Plugins and Sample Client Applications.
cgandhi <chandradeep.gandhi@sasken.com>
parents: 8
diff changeset
   142
   * @param perPage Item per page, default is SMF_ITEMS_PER_PAGE
8
4102c67b6e56 Restoring the missing activity related and music headers
cgandhi <chandradeep.gandhi@sasken.com>
parents:
diff changeset
   143
   */
4102c67b6e56 Restoring the missing activity related and music headers
cgandhi <chandradeep.gandhi@sasken.com>
parents:
diff changeset
   144
  void recommendations(SmfTrackInfo track,int pageNum=SMF_FIRST_PAGE,int perPage=SMF_ITEMS_PER_PAGE)  ; // basic list of track objects
4102c67b6e56 Restoring the missing activity related and music headers
cgandhi <chandradeep.gandhi@sasken.com>
parents:
diff changeset
   145
4102c67b6e56 Restoring the missing activity related and music headers
cgandhi <chandradeep.gandhi@sasken.com>
parents:
diff changeset
   146
  /**
4102c67b6e56 Restoring the missing activity related and music headers
cgandhi <chandradeep.gandhi@sasken.com>
parents:
diff changeset
   147
   * Searches for tracks similar to a given track asynchronously.
4102c67b6e56 Restoring the missing activity related and music headers
cgandhi <chandradeep.gandhi@sasken.com>
parents:
diff changeset
   148
   * The signal trackSearchAvailable() is emitted with SmfTrackInfoList
4102c67b6e56 Restoring the missing activity related and music headers
cgandhi <chandradeep.gandhi@sasken.com>
parents:
diff changeset
   149
   * once its arrived.
4102c67b6e56 Restoring the missing activity related and music headers
cgandhi <chandradeep.gandhi@sasken.com>
parents:
diff changeset
   150
   * When the list is big user can specify the page number and per page item data.
4102c67b6e56 Restoring the missing activity related and music headers
cgandhi <chandradeep.gandhi@sasken.com>
parents:
diff changeset
   151
   * If not supplied by the user default values are used.
4102c67b6e56 Restoring the missing activity related and music headers
cgandhi <chandradeep.gandhi@sasken.com>
parents:
diff changeset
   152
   * @param track The search criteria, similar tracks are searched
4102c67b6e56 Restoring the missing activity related and music headers
cgandhi <chandradeep.gandhi@sasken.com>
parents:
diff changeset
   153
   * @param pageNum Page number to download, SMF_FIRST_PAGE denotes fresh query.
14
a469c0e6e7fb changes for SmfPost, SmfCredentialMgr, PLuginManager, SmfServer. Adding Sample Plugins and Sample Client Applications.
cgandhi <chandradeep.gandhi@sasken.com>
parents: 8
diff changeset
   154
   * @param perPage Item per page, default is SMF_ITEMS_PER_PAGE
8
4102c67b6e56 Restoring the missing activity related and music headers
cgandhi <chandradeep.gandhi@sasken.com>
parents:
diff changeset
   155
   */
4102c67b6e56 Restoring the missing activity related and music headers
cgandhi <chandradeep.gandhi@sasken.com>
parents:
diff changeset
   156
  void tracks(SmfTrackInfo track,int pageNum=SMF_FIRST_PAGE,int perPage=SMF_ITEMS_PER_PAGE)  ; // basic list of track objects
4102c67b6e56 Restoring the missing activity related and music headers
cgandhi <chandradeep.gandhi@sasken.com>
parents:
diff changeset
   157
4102c67b6e56 Restoring the missing activity related and music headers
cgandhi <chandradeep.gandhi@sasken.com>
parents:
diff changeset
   158
  /**
4102c67b6e56 Restoring the missing activity related and music headers
cgandhi <chandradeep.gandhi@sasken.com>
parents:
diff changeset
   159
   * Searches for a track having similar finger print asynchronously.
4102c67b6e56 Restoring the missing activity related and music headers
cgandhi <chandradeep.gandhi@sasken.com>
parents:
diff changeset
   160
   * The signal trackSearchAvailable() is emitted with SmfTrackInfoList
4102c67b6e56 Restoring the missing activity related and music headers
cgandhi <chandradeep.gandhi@sasken.com>
parents:
diff changeset
   161
   * once its arrived.
4102c67b6e56 Restoring the missing activity related and music headers
cgandhi <chandradeep.gandhi@sasken.com>
parents:
diff changeset
   162
   * @param signature The search criteria,signature to be searched for
4102c67b6e56 Restoring the missing activity related and music headers
cgandhi <chandradeep.gandhi@sasken.com>
parents:
diff changeset
   163
   * @param pageNum Page number to download, SMF_FIRST_PAGE denotes fresh query.
14
a469c0e6e7fb changes for SmfPost, SmfCredentialMgr, PLuginManager, SmfServer. Adding Sample Plugins and Sample Client Applications.
cgandhi <chandradeep.gandhi@sasken.com>
parents: 8
diff changeset
   164
   * @param perPage Item per page, default is SMF_ITEMS_PER_PAGE
8
4102c67b6e56 Restoring the missing activity related and music headers
cgandhi <chandradeep.gandhi@sasken.com>
parents:
diff changeset
   165
   */
4102c67b6e56 Restoring the missing activity related and music headers
cgandhi <chandradeep.gandhi@sasken.com>
parents:
diff changeset
   166
  void trackInfo(SmfMusicFingerPrint signature,int pageNum=SMF_FIRST_PAGE,int perPage=SMF_ITEMS_PER_PAGE)  ; // search by fingerprint object
4102c67b6e56 Restoring the missing activity related and music headers
cgandhi <chandradeep.gandhi@sasken.com>
parents:
diff changeset
   167
4102c67b6e56 Restoring the missing activity related and music headers
cgandhi <chandradeep.gandhi@sasken.com>
parents:
diff changeset
   168
  /**
4102c67b6e56 Restoring the missing activity related and music headers
cgandhi <chandradeep.gandhi@sasken.com>
parents:
diff changeset
   169
   * Search information about where to buy this song from asynchronously.
4102c67b6e56 Restoring the missing activity related and music headers
cgandhi <chandradeep.gandhi@sasken.com>
parents:
diff changeset
   170
   * The signal storeSearchAvailable() is emitted with SmfProviderList once its arrived.
4102c67b6e56 Restoring the missing activity related and music headers
cgandhi <chandradeep.gandhi@sasken.com>
parents:
diff changeset
   171
   * @param track The search criteria for stores
4102c67b6e56 Restoring the missing activity related and music headers
cgandhi <chandradeep.gandhi@sasken.com>
parents:
diff changeset
   172
   * @param pageNum Page number to download, SMF_FIRST_PAGE denotes fresh query.
14
a469c0e6e7fb changes for SmfPost, SmfCredentialMgr, PLuginManager, SmfServer. Adding Sample Plugins and Sample Client Applications.
cgandhi <chandradeep.gandhi@sasken.com>
parents: 8
diff changeset
   173
   * @param perPage Item per page, default is SMF_ITEMS_PER_PAGE
8
4102c67b6e56 Restoring the missing activity related and music headers
cgandhi <chandradeep.gandhi@sasken.com>
parents:
diff changeset
   174
   */
4102c67b6e56 Restoring the missing activity related and music headers
cgandhi <chandradeep.gandhi@sasken.com>
parents:
diff changeset
   175
  void stores(SmfTrackInfo track,int pageNum=SMF_FIRST_PAGE,int perPage=SMF_ITEMS_PER_PAGE)  ;
4102c67b6e56 Restoring the missing activity related and music headers
cgandhi <chandradeep.gandhi@sasken.com>
parents:
diff changeset
   176
4102c67b6e56 Restoring the missing activity related and music headers
cgandhi <chandradeep.gandhi@sasken.com>
parents:
diff changeset
   177
  //APIs to get/set base provider info (SmfProvider)
4102c67b6e56 Restoring the missing activity related and music headers
cgandhi <chandradeep.gandhi@sasken.com>
parents:
diff changeset
   178
4102c67b6e56 Restoring the missing activity related and music headers
cgandhi <chandradeep.gandhi@sasken.com>
parents:
diff changeset
   179
  /**
4102c67b6e56 Restoring the missing activity related and music headers
cgandhi <chandradeep.gandhi@sasken.com>
parents:
diff changeset
   180
   * Gets the base provider info
4102c67b6e56 Restoring the missing activity related and music headers
cgandhi <chandradeep.gandhi@sasken.com>
parents:
diff changeset
   181
   */
4102c67b6e56 Restoring the missing activity related and music headers
cgandhi <chandradeep.gandhi@sasken.com>
parents:
diff changeset
   182
  SmfProvider* getProvider()  ;
4102c67b6e56 Restoring the missing activity related and music headers
cgandhi <chandradeep.gandhi@sasken.com>
parents:
diff changeset
   183
4102c67b6e56 Restoring the missing activity related and music headers
cgandhi <chandradeep.gandhi@sasken.com>
parents:
diff changeset
   184
4102c67b6e56 Restoring the missing activity related and music headers
cgandhi <chandradeep.gandhi@sasken.com>
parents:
diff changeset
   185
public slots:
4102c67b6e56 Restoring the missing activity related and music headers
cgandhi <chandradeep.gandhi@sasken.com>
parents:
diff changeset
   186
4102c67b6e56 Restoring the missing activity related and music headers
cgandhi <chandradeep.gandhi@sasken.com>
parents:
diff changeset
   187
	/**
4102c67b6e56 Restoring the missing activity related and music headers
cgandhi <chandradeep.gandhi@sasken.com>
parents:
diff changeset
   188
	 * Posts currently playing track.
4102c67b6e56 Restoring the missing activity related and music headers
cgandhi <chandradeep.gandhi@sasken.com>
parents:
diff changeset
   189
	 * Success can be checked by checking the signal postFinished()
14
a469c0e6e7fb changes for SmfPost, SmfCredentialMgr, PLuginManager, SmfServer. Adding Sample Plugins and Sample Client Applications.
cgandhi <chandradeep.gandhi@sasken.com>
parents: 8
diff changeset
   190
	 * @param track Track to post
8
4102c67b6e56 Restoring the missing activity related and music headers
cgandhi <chandradeep.gandhi@sasken.com>
parents:
diff changeset
   191
	 */
4102c67b6e56 Restoring the missing activity related and music headers
cgandhi <chandradeep.gandhi@sasken.com>
parents:
diff changeset
   192
  void postCurrentPlaying(SmfTrackInfo track)  ;
14
a469c0e6e7fb changes for SmfPost, SmfCredentialMgr, PLuginManager, SmfServer. Adding Sample Plugins and Sample Client Applications.
cgandhi <chandradeep.gandhi@sasken.com>
parents: 8
diff changeset
   193
  void postRating(SmfTrackInfo track, SmfMusicRating rate)  ;
a469c0e6e7fb changes for SmfPost, SmfCredentialMgr, PLuginManager, SmfServer. Adding Sample Plugins and Sample Client Applications.
cgandhi <chandradeep.gandhi@sasken.com>
parents: 8
diff changeset
   194
  void postComments(SmfTrackInfo track, SmfComment comment)  ;
8
4102c67b6e56 Restoring the missing activity related and music headers
cgandhi <chandradeep.gandhi@sasken.com>
parents:
diff changeset
   195
4102c67b6e56 Restoring the missing activity related and music headers
cgandhi <chandradeep.gandhi@sasken.com>
parents:
diff changeset
   196
signals:
4102c67b6e56 Restoring the missing activity related and music headers
cgandhi <chandradeep.gandhi@sasken.com>
parents:
diff changeset
   197
	/**
4102c67b6e56 Restoring the missing activity related and music headers
cgandhi <chandradeep.gandhi@sasken.com>
parents:
diff changeset
   198
	 * Emitted when the search result for a track is available.
4102c67b6e56 Restoring the missing activity related and music headers
cgandhi <chandradeep.gandhi@sasken.com>
parents:
diff changeset
   199
	 * Note if number of tacks in the search is large, then it can download the list page by page.
4102c67b6e56 Restoring the missing activity related and music headers
cgandhi <chandradeep.gandhi@sasken.com>
parents:
diff changeset
   200
	 * In that case this signal is emitted multiple times.
14
a469c0e6e7fb changes for SmfPost, SmfCredentialMgr, PLuginManager, SmfServer. Adding Sample Plugins and Sample Client Applications.
cgandhi <chandradeep.gandhi@sasken.com>
parents: 8
diff changeset
   201
	 * @param resultPage Page number info
8
4102c67b6e56 Restoring the missing activity related and music headers
cgandhi <chandradeep.gandhi@sasken.com>
parents:
diff changeset
   202
	 */
14
a469c0e6e7fb changes for SmfPost, SmfCredentialMgr, PLuginManager, SmfServer. Adding Sample Plugins and Sample Client Applications.
cgandhi <chandradeep.gandhi@sasken.com>
parents: 8
diff changeset
   203
	void trackSearchAvailable(SmfTrackInfoList* result, SmfError error,SmfResultPage resultPage);
8
4102c67b6e56 Restoring the missing activity related and music headers
cgandhi <chandradeep.gandhi@sasken.com>
parents:
diff changeset
   204
4102c67b6e56 Restoring the missing activity related and music headers
cgandhi <chandradeep.gandhi@sasken.com>
parents:
diff changeset
   205
	/**
4102c67b6e56 Restoring the missing activity related and music headers
cgandhi <chandradeep.gandhi@sasken.com>
parents:
diff changeset
   206
	 *  Emitted when the search result for a store is available.
4102c67b6e56 Restoring the missing activity related and music headers
cgandhi <chandradeep.gandhi@sasken.com>
parents:
diff changeset
   207
	 *  Note if number of tacks in the search is large, then it can download the list page by page.
4102c67b6e56 Restoring the missing activity related and music headers
cgandhi <chandradeep.gandhi@sasken.com>
parents:
diff changeset
   208
	 *  In that case this signal is emitted multiple times.
14
a469c0e6e7fb changes for SmfPost, SmfCredentialMgr, PLuginManager, SmfServer. Adding Sample Plugins and Sample Client Applications.
cgandhi <chandradeep.gandhi@sasken.com>
parents: 8
diff changeset
   209
	 *  @param resultPage Page number info
8
4102c67b6e56 Restoring the missing activity related and music headers
cgandhi <chandradeep.gandhi@sasken.com>
parents:
diff changeset
   210
	 */
14
a469c0e6e7fb changes for SmfPost, SmfCredentialMgr, PLuginManager, SmfServer. Adding Sample Plugins and Sample Client Applications.
cgandhi <chandradeep.gandhi@sasken.com>
parents: 8
diff changeset
   211
	void storeSearchAvailable(SmfProviderList* result, SmfError error, SmfResultPage resultPage);
a469c0e6e7fb changes for SmfPost, SmfCredentialMgr, PLuginManager, SmfServer. Adding Sample Plugins and Sample Client Applications.
cgandhi <chandradeep.gandhi@sasken.com>
parents: 8
diff changeset
   212
	void postfinished(SmfError error);
8
4102c67b6e56 Restoring the missing activity related and music headers
cgandhi <chandradeep.gandhi@sasken.com>
parents:
diff changeset
   213
private:
4102c67b6e56 Restoring the missing activity related and music headers
cgandhi <chandradeep.gandhi@sasken.com>
parents:
diff changeset
   214
  SmfProvider* m_baseProvider;
14
a469c0e6e7fb changes for SmfPost, SmfCredentialMgr, PLuginManager, SmfServer. Adding Sample Plugins and Sample Client Applications.
cgandhi <chandradeep.gandhi@sasken.com>
parents: 8
diff changeset
   215
  SmfMusicSearchPrivate* m_private;
a469c0e6e7fb changes for SmfPost, SmfCredentialMgr, PLuginManager, SmfServer. Adding Sample Plugins and Sample Client Applications.
cgandhi <chandradeep.gandhi@sasken.com>
parents: 8
diff changeset
   216
  friend class SmfMusicSearchPrivate;
8
4102c67b6e56 Restoring the missing activity related and music headers
cgandhi <chandradeep.gandhi@sasken.com>
parents:
diff changeset
   217
};
4102c67b6e56 Restoring the missing activity related and music headers
cgandhi <chandradeep.gandhi@sasken.com>
parents:
diff changeset
   218
SMF_SERVICE_NAME(SmfMusicSearch, "org.symbian.smf.client.music.search\0.2")
4102c67b6e56 Restoring the missing activity related and music headers
cgandhi <chandradeep.gandhi@sasken.com>
parents:
diff changeset
   219
4102c67b6e56 Restoring the missing activity related and music headers
cgandhi <chandradeep.gandhi@sasken.com>
parents:
diff changeset
   220
4102c67b6e56 Restoring the missing activity related and music headers
cgandhi <chandradeep.gandhi@sasken.com>
parents:
diff changeset
   221
/**
4102c67b6e56 Restoring the missing activity related and music headers
cgandhi <chandradeep.gandhi@sasken.com>
parents:
diff changeset
   222
 * provides service ("org.symbian.smf.client.music.playlist")
4102c67b6e56 Restoring the missing activity related and music headers
cgandhi <chandradeep.gandhi@sasken.com>
parents:
diff changeset
   223
 *
4102c67b6e56 Restoring the missing activity related and music headers
cgandhi <chandradeep.gandhi@sasken.com>
parents:
diff changeset
   224
 * Interface to a remote playlist service. This class
4102c67b6e56 Restoring the missing activity related and music headers
cgandhi <chandradeep.gandhi@sasken.com>
parents:
diff changeset
   225
 * provides some basic functionality to allow applications
4102c67b6e56 Restoring the missing activity related and music headers
cgandhi <chandradeep.gandhi@sasken.com>
parents:
diff changeset
   226
 * to interact with playlists in some music related service provider (e.g. last.fm).
4102c67b6e56 Restoring the missing activity related and music headers
cgandhi <chandradeep.gandhi@sasken.com>
parents:
diff changeset
   227
 *
4102c67b6e56 Restoring the missing activity related and music headers
cgandhi <chandradeep.gandhi@sasken.com>
parents:
diff changeset
   228
 * Note that branding information for the particular service implementation
4102c67b6e56 Restoring the missing activity related and music headers
cgandhi <chandradeep.gandhi@sasken.com>
parents:
diff changeset
   229
 * is available from getProvider() API. See also:
4102c67b6e56 Restoring the missing activity related and music headers
cgandhi <chandradeep.gandhi@sasken.com>
parents:
diff changeset
   230
 * SmfProvider::serviceName(), SmfProvider::serviceIcon()
4102c67b6e56 Restoring the missing activity related and music headers
cgandhi <chandradeep.gandhi@sasken.com>
parents:
diff changeset
   231
 *
4102c67b6e56 Restoring the missing activity related and music headers
cgandhi <chandradeep.gandhi@sasken.com>
parents:
diff changeset
   232
 * All of the functionality described here should be implemented by a service
4102c67b6e56 Restoring the missing activity related and music headers
cgandhi <chandradeep.gandhi@sasken.com>
parents:
diff changeset
   233
 * specific plug-in object.
4102c67b6e56 Restoring the missing activity related and music headers
cgandhi <chandradeep.gandhi@sasken.com>
parents:
diff changeset
   234
 *
4102c67b6e56 Restoring the missing activity related and music headers
cgandhi <chandradeep.gandhi@sasken.com>
parents:
diff changeset
   235
 */
4102c67b6e56 Restoring the missing activity related and music headers
cgandhi <chandradeep.gandhi@sasken.com>
parents:
diff changeset
   236
class SMFCLIENT_EXPORT SmfPlaylistService : public QObject
4102c67b6e56 Restoring the missing activity related and music headers
cgandhi <chandradeep.gandhi@sasken.com>
parents:
diff changeset
   237
{
4102c67b6e56 Restoring the missing activity related and music headers
cgandhi <chandradeep.gandhi@sasken.com>
parents:
diff changeset
   238
  Q_OBJECT
4102c67b6e56 Restoring the missing activity related and music headers
cgandhi <chandradeep.gandhi@sasken.com>
parents:
diff changeset
   239
4102c67b6e56 Restoring the missing activity related and music headers
cgandhi <chandradeep.gandhi@sasken.com>
parents:
diff changeset
   240
public:
4102c67b6e56 Restoring the missing activity related and music headers
cgandhi <chandradeep.gandhi@sasken.com>
parents:
diff changeset
   241
  /**
4102c67b6e56 Restoring the missing activity related and music headers
cgandhi <chandradeep.gandhi@sasken.com>
parents:
diff changeset
   242
   * Constructs SmfPlaylistService with base provider info
4102c67b6e56 Restoring the missing activity related and music headers
cgandhi <chandradeep.gandhi@sasken.com>
parents:
diff changeset
   243
   * Seeing as this is a plug-in implementation, these will realistically
14
a469c0e6e7fb changes for SmfPost, SmfCredentialMgr, PLuginManager, SmfServer. Adding Sample Plugins and Sample Client Applications.
cgandhi <chandradeep.gandhi@sasken.com>
parents: 8
diff changeset
   244
   * be generated by SMF factory of some kind
8
4102c67b6e56 Restoring the missing activity related and music headers
cgandhi <chandradeep.gandhi@sasken.com>
parents:
diff changeset
   245
   */
4102c67b6e56 Restoring the missing activity related and music headers
cgandhi <chandradeep.gandhi@sasken.com>
parents:
diff changeset
   246
  SmfPlaylistService(SmfProvider* baseProvider = 0);
4102c67b6e56 Restoring the missing activity related and music headers
cgandhi <chandradeep.gandhi@sasken.com>
parents:
diff changeset
   247
  ~SmfPlaylistService();
4102c67b6e56 Restoring the missing activity related and music headers
cgandhi <chandradeep.gandhi@sasken.com>
parents:
diff changeset
   248
4102c67b6e56 Restoring the missing activity related and music headers
cgandhi <chandradeep.gandhi@sasken.com>
parents:
diff changeset
   249
public:
4102c67b6e56 Restoring the missing activity related and music headers
cgandhi <chandradeep.gandhi@sasken.com>
parents:
diff changeset
   250
4102c67b6e56 Restoring the missing activity related and music headers
cgandhi <chandradeep.gandhi@sasken.com>
parents:
diff changeset
   251
  /**
4102c67b6e56 Restoring the missing activity related and music headers
cgandhi <chandradeep.gandhi@sasken.com>
parents:
diff changeset
   252
   * Gets the list playlists for the logged-in user asynchronously.
4102c67b6e56 Restoring the missing activity related and music headers
cgandhi <chandradeep.gandhi@sasken.com>
parents:
diff changeset
   253
   * The signal playlistsListAvailable() signal is emitted with
4102c67b6e56 Restoring the missing activity related and music headers
cgandhi <chandradeep.gandhi@sasken.com>
parents:
diff changeset
   254
   * SmfPlaylistList once its arrived .
4102c67b6e56 Restoring the missing activity related and music headers
cgandhi <chandradeep.gandhi@sasken.com>
parents:
diff changeset
   255
   * When the list is big user can specify the page number and per page item data.
4102c67b6e56 Restoring the missing activity related and music headers
cgandhi <chandradeep.gandhi@sasken.com>
parents:
diff changeset
   256
   * If not supplied by the user default values are used.
4102c67b6e56 Restoring the missing activity related and music headers
cgandhi <chandradeep.gandhi@sasken.com>
parents:
diff changeset
   257
   * @param pageNum Page number to download, SMF_FIRST_PAGE denotes fresh query.
14
a469c0e6e7fb changes for SmfPost, SmfCredentialMgr, PLuginManager, SmfServer. Adding Sample Plugins and Sample Client Applications.
cgandhi <chandradeep.gandhi@sasken.com>
parents: 8
diff changeset
   258
   * @param perPage Item per page, default is SMF_ITEMS_PER_PAGE
8
4102c67b6e56 Restoring the missing activity related and music headers
cgandhi <chandradeep.gandhi@sasken.com>
parents:
diff changeset
   259
   */
4102c67b6e56 Restoring the missing activity related and music headers
cgandhi <chandradeep.gandhi@sasken.com>
parents:
diff changeset
   260
  void playlists(int pageNum=SMF_FIRST_PAGE,int perPage=SMF_ITEMS_PER_PAGE)  ; // basic list of playlist objects
4102c67b6e56 Restoring the missing activity related and music headers
cgandhi <chandradeep.gandhi@sasken.com>
parents:
diff changeset
   261
4102c67b6e56 Restoring the missing activity related and music headers
cgandhi <chandradeep.gandhi@sasken.com>
parents:
diff changeset
   262
  /**
4102c67b6e56 Restoring the missing activity related and music headers
cgandhi <chandradeep.gandhi@sasken.com>
parents:
diff changeset
   263
   * Gets the list playlists for the given user asynchronously.
4102c67b6e56 Restoring the missing activity related and music headers
cgandhi <chandradeep.gandhi@sasken.com>
parents:
diff changeset
   264
   * The signal playlistsListAvailable() signal is emitted with
4102c67b6e56 Restoring the missing activity related and music headers
cgandhi <chandradeep.gandhi@sasken.com>
parents:
diff changeset
   265
   * SmfPlaylistList once its arrived.
4102c67b6e56 Restoring the missing activity related and music headers
cgandhi <chandradeep.gandhi@sasken.com>
parents:
diff changeset
   266
   * When the list is big user can specify the page number and per page item data.
4102c67b6e56 Restoring the missing activity related and music headers
cgandhi <chandradeep.gandhi@sasken.com>
parents:
diff changeset
   267
   * If not supplied by the user default values are used.
4102c67b6e56 Restoring the missing activity related and music headers
cgandhi <chandradeep.gandhi@sasken.com>
parents:
diff changeset
   268
   * @param user User for which to get the playlists
4102c67b6e56 Restoring the missing activity related and music headers
cgandhi <chandradeep.gandhi@sasken.com>
parents:
diff changeset
   269
   * @param pageNum Page number to download, SMF_FIRST_PAGE denotes fresh query.
4102c67b6e56 Restoring the missing activity related and music headers
cgandhi <chandradeep.gandhi@sasken.com>
parents:
diff changeset
   270
   * @param perPage Item per page, default is SMF_ITEMS_PER_PAGE
4102c67b6e56 Restoring the missing activity related and music headers
cgandhi <chandradeep.gandhi@sasken.com>
parents:
diff changeset
   271
   */
4102c67b6e56 Restoring the missing activity related and music headers
cgandhi <chandradeep.gandhi@sasken.com>
parents:
diff changeset
   272
  void playlistsOf(SmfMusicProfile* user,int pageNum=SMF_FIRST_PAGE,int perPage=SMF_ITEMS_PER_PAGE)  ;
4102c67b6e56 Restoring the missing activity related and music headers
cgandhi <chandradeep.gandhi@sasken.com>
parents:
diff changeset
   273
4102c67b6e56 Restoring the missing activity related and music headers
cgandhi <chandradeep.gandhi@sasken.com>
parents:
diff changeset
   274
  //APIs to get/set base provider info (SmfProvider)
4102c67b6e56 Restoring the missing activity related and music headers
cgandhi <chandradeep.gandhi@sasken.com>
parents:
diff changeset
   275
4102c67b6e56 Restoring the missing activity related and music headers
cgandhi <chandradeep.gandhi@sasken.com>
parents:
diff changeset
   276
  /**
4102c67b6e56 Restoring the missing activity related and music headers
cgandhi <chandradeep.gandhi@sasken.com>
parents:
diff changeset
   277
   * Gets the base provider info
4102c67b6e56 Restoring the missing activity related and music headers
cgandhi <chandradeep.gandhi@sasken.com>
parents:
diff changeset
   278
   */
4102c67b6e56 Restoring the missing activity related and music headers
cgandhi <chandradeep.gandhi@sasken.com>
parents:
diff changeset
   279
  SmfProvider* getProvider()  ;
4102c67b6e56 Restoring the missing activity related and music headers
cgandhi <chandradeep.gandhi@sasken.com>
parents:
diff changeset
   280
4102c67b6e56 Restoring the missing activity related and music headers
cgandhi <chandradeep.gandhi@sasken.com>
parents:
diff changeset
   281
4102c67b6e56 Restoring the missing activity related and music headers
cgandhi <chandradeep.gandhi@sasken.com>
parents:
diff changeset
   282
public slots:
4102c67b6e56 Restoring the missing activity related and music headers
cgandhi <chandradeep.gandhi@sasken.com>
parents:
diff changeset
   283
4102c67b6e56 Restoring the missing activity related and music headers
cgandhi <chandradeep.gandhi@sasken.com>
parents:
diff changeset
   284
	/**
4102c67b6e56 Restoring the missing activity related and music headers
cgandhi <chandradeep.gandhi@sasken.com>
parents:
diff changeset
   285
	 * Upload currently playing track to a playlist. Signal
4102c67b6e56 Restoring the missing activity related and music headers
cgandhi <chandradeep.gandhi@sasken.com>
parents:
diff changeset
   286
	 * playlistUpdated() can be checked for success value
4102c67b6e56 Restoring the missing activity related and music headers
cgandhi <chandradeep.gandhi@sasken.com>
parents:
diff changeset
   287
	 * @param plst The playlist to be added in
14
a469c0e6e7fb changes for SmfPost, SmfCredentialMgr, PLuginManager, SmfServer. Adding Sample Plugins and Sample Client Applications.
cgandhi <chandradeep.gandhi@sasken.com>
parents: 8
diff changeset
   288
	 * @param tracks The list of tracks to uploaded
8
4102c67b6e56 Restoring the missing activity related and music headers
cgandhi <chandradeep.gandhi@sasken.com>
parents:
diff changeset
   289
	 */
4102c67b6e56 Restoring the missing activity related and music headers
cgandhi <chandradeep.gandhi@sasken.com>
parents:
diff changeset
   290
  int addToPlaylist(SmfPlaylist plst, SmfTrackInfoList* tracks)  ;
4102c67b6e56 Restoring the missing activity related and music headers
cgandhi <chandradeep.gandhi@sasken.com>
parents:
diff changeset
   291
4102c67b6e56 Restoring the missing activity related and music headers
cgandhi <chandradeep.gandhi@sasken.com>
parents:
diff changeset
   292
	/**
4102c67b6e56 Restoring the missing activity related and music headers
cgandhi <chandradeep.gandhi@sasken.com>
parents:
diff changeset
   293
	 * Upload currently playing playlist . Signal
4102c67b6e56 Restoring the missing activity related and music headers
cgandhi <chandradeep.gandhi@sasken.com>
parents:
diff changeset
   294
	 * playlistUpdated() can be checked for success value
4102c67b6e56 Restoring the missing activity related and music headers
cgandhi <chandradeep.gandhi@sasken.com>
parents:
diff changeset
   295
	 * @param plst The playlist to be uploaded
4102c67b6e56 Restoring the missing activity related and music headers
cgandhi <chandradeep.gandhi@sasken.com>
parents:
diff changeset
   296
	 */
4102c67b6e56 Restoring the missing activity related and music headers
cgandhi <chandradeep.gandhi@sasken.com>
parents:
diff changeset
   297
  int postCurrentPlayingPlaylist(SmfPlaylist plst)  ;
4102c67b6e56 Restoring the missing activity related and music headers
cgandhi <chandradeep.gandhi@sasken.com>
parents:
diff changeset
   298
4102c67b6e56 Restoring the missing activity related and music headers
cgandhi <chandradeep.gandhi@sasken.com>
parents:
diff changeset
   299
4102c67b6e56 Restoring the missing activity related and music headers
cgandhi <chandradeep.gandhi@sasken.com>
parents:
diff changeset
   300
signals:
4102c67b6e56 Restoring the missing activity related and music headers
cgandhi <chandradeep.gandhi@sasken.com>
parents:
diff changeset
   301
	/**
4102c67b6e56 Restoring the missing activity related and music headers
cgandhi <chandradeep.gandhi@sasken.com>
parents:
diff changeset
   302
	 * Notification of availability of list of playlists requested.
4102c67b6e56 Restoring the missing activity related and music headers
cgandhi <chandradeep.gandhi@sasken.com>
parents:
diff changeset
   303
	 * Note if number of list is large, then it can download the list page by page.
4102c67b6e56 Restoring the missing activity related and music headers
cgandhi <chandradeep.gandhi@sasken.com>
parents:
diff changeset
   304
	 * In that case this signal is emitted multiple times.
14
a469c0e6e7fb changes for SmfPost, SmfCredentialMgr, PLuginManager, SmfServer. Adding Sample Plugins and Sample Client Applications.
cgandhi <chandradeep.gandhi@sasken.com>
parents: 8
diff changeset
   305
	 * @param resultPage Page number info
8
4102c67b6e56 Restoring the missing activity related and music headers
cgandhi <chandradeep.gandhi@sasken.com>
parents:
diff changeset
   306
	 */
14
a469c0e6e7fb changes for SmfPost, SmfCredentialMgr, PLuginManager, SmfServer. Adding Sample Plugins and Sample Client Applications.
cgandhi <chandradeep.gandhi@sasken.com>
parents: 8
diff changeset
   307
	void playlistsListAvailable(SmfPlaylistList*, SmfError error, SmfResultPage resultPage);
8
4102c67b6e56 Restoring the missing activity related and music headers
cgandhi <chandradeep.gandhi@sasken.com>
parents:
diff changeset
   308
	/**
14
a469c0e6e7fb changes for SmfPost, SmfCredentialMgr, PLuginManager, SmfServer. Adding Sample Plugins and Sample Client Applications.
cgandhi <chandradeep.gandhi@sasken.com>
parents: 8
diff changeset
   309
	 * Signals remote updation of playlist with success value
8
4102c67b6e56 Restoring the missing activity related and music headers
cgandhi <chandradeep.gandhi@sasken.com>
parents:
diff changeset
   310
	 */
14
a469c0e6e7fb changes for SmfPost, SmfCredentialMgr, PLuginManager, SmfServer. Adding Sample Plugins and Sample Client Applications.
cgandhi <chandradeep.gandhi@sasken.com>
parents: 8
diff changeset
   311
    void playlistUpdated(SmfError success) ;
8
4102c67b6e56 Restoring the missing activity related and music headers
cgandhi <chandradeep.gandhi@sasken.com>
parents:
diff changeset
   312
private:
4102c67b6e56 Restoring the missing activity related and music headers
cgandhi <chandradeep.gandhi@sasken.com>
parents:
diff changeset
   313
  SmfProvider* m_baseProvider;
14
a469c0e6e7fb changes for SmfPost, SmfCredentialMgr, PLuginManager, SmfServer. Adding Sample Plugins and Sample Client Applications.
cgandhi <chandradeep.gandhi@sasken.com>
parents: 8
diff changeset
   314
  SmfPlaylistServicePrivate* m_private;
a469c0e6e7fb changes for SmfPost, SmfCredentialMgr, PLuginManager, SmfServer. Adding Sample Plugins and Sample Client Applications.
cgandhi <chandradeep.gandhi@sasken.com>
parents: 8
diff changeset
   315
  friend class SmfPlaylistServicePrivate;
8
4102c67b6e56 Restoring the missing activity related and music headers
cgandhi <chandradeep.gandhi@sasken.com>
parents:
diff changeset
   316
};
4102c67b6e56 Restoring the missing activity related and music headers
cgandhi <chandradeep.gandhi@sasken.com>
parents:
diff changeset
   317
SMF_SERVICE_NAME(SmfPlaylistService, "org.symbian.smf.client.music.playlist\0.2")
4102c67b6e56 Restoring the missing activity related and music headers
cgandhi <chandradeep.gandhi@sasken.com>
parents:
diff changeset
   318
4102c67b6e56 Restoring the missing activity related and music headers
cgandhi <chandradeep.gandhi@sasken.com>
parents:
diff changeset
   319
4102c67b6e56 Restoring the missing activity related and music headers
cgandhi <chandradeep.gandhi@sasken.com>
parents:
diff changeset
   320
/**
4102c67b6e56 Restoring the missing activity related and music headers
cgandhi <chandradeep.gandhi@sasken.com>
parents:
diff changeset
   321
* provides service ("org.symbian.smf.client.music.events")
4102c67b6e56 Restoring the missing activity related and music headers
cgandhi <chandradeep.gandhi@sasken.com>
parents:
diff changeset
   322
*/
4102c67b6e56 Restoring the missing activity related and music headers
cgandhi <chandradeep.gandhi@sasken.com>
parents:
diff changeset
   323
class SMFCLIENT_EXPORT SmfMusicEvents : public QObject
4102c67b6e56 Restoring the missing activity related and music headers
cgandhi <chandradeep.gandhi@sasken.com>
parents:
diff changeset
   324
{
4102c67b6e56 Restoring the missing activity related and music headers
cgandhi <chandradeep.gandhi@sasken.com>
parents:
diff changeset
   325
  Q_OBJECT
4102c67b6e56 Restoring the missing activity related and music headers
cgandhi <chandradeep.gandhi@sasken.com>
parents:
diff changeset
   326
4102c67b6e56 Restoring the missing activity related and music headers
cgandhi <chandradeep.gandhi@sasken.com>
parents:
diff changeset
   327
public:
4102c67b6e56 Restoring the missing activity related and music headers
cgandhi <chandradeep.gandhi@sasken.com>
parents:
diff changeset
   328
  /**
4102c67b6e56 Restoring the missing activity related and music headers
cgandhi <chandradeep.gandhi@sasken.com>
parents:
diff changeset
   329
   * Constructs SmfMusicEvents with base provider info
4102c67b6e56 Restoring the missing activity related and music headers
cgandhi <chandradeep.gandhi@sasken.com>
parents:
diff changeset
   330
   * Seeing as this is a plug-in implementation, these will realistically
14
a469c0e6e7fb changes for SmfPost, SmfCredentialMgr, PLuginManager, SmfServer. Adding Sample Plugins and Sample Client Applications.
cgandhi <chandradeep.gandhi@sasken.com>
parents: 8
diff changeset
   331
   *  be generated by SMF factory of some kind
8
4102c67b6e56 Restoring the missing activity related and music headers
cgandhi <chandradeep.gandhi@sasken.com>
parents:
diff changeset
   332
   */
4102c67b6e56 Restoring the missing activity related and music headers
cgandhi <chandradeep.gandhi@sasken.com>
parents:
diff changeset
   333
  SmfMusicEvents(SmfProvider* baseProvider = 0);
4102c67b6e56 Restoring the missing activity related and music headers
cgandhi <chandradeep.gandhi@sasken.com>
parents:
diff changeset
   334
  ~SmfMusicEvents();
4102c67b6e56 Restoring the missing activity related and music headers
cgandhi <chandradeep.gandhi@sasken.com>
parents:
diff changeset
   335
4102c67b6e56 Restoring the missing activity related and music headers
cgandhi <chandradeep.gandhi@sasken.com>
parents:
diff changeset
   336
public:
4102c67b6e56 Restoring the missing activity related and music headers
cgandhi <chandradeep.gandhi@sasken.com>
parents:
diff changeset
   337
4102c67b6e56 Restoring the missing activity related and music headers
cgandhi <chandradeep.gandhi@sasken.com>
parents:
diff changeset
   338
  /**
4102c67b6e56 Restoring the missing activity related and music headers
cgandhi <chandradeep.gandhi@sasken.com>
parents:
diff changeset
   339
   * Gets list of events in a particular location asynchronously.
4102c67b6e56 Restoring the missing activity related and music headers
cgandhi <chandradeep.gandhi@sasken.com>
parents:
diff changeset
   340
   * eventsAvailable() signal is emitted with SmfEventsList once its arrived.
4102c67b6e56 Restoring the missing activity related and music headers
cgandhi <chandradeep.gandhi@sasken.com>
parents:
diff changeset
   341
   * When the list is big user can specify the page number and per page item data.
4102c67b6e56 Restoring the missing activity related and music headers
cgandhi <chandradeep.gandhi@sasken.com>
parents:
diff changeset
   342
   * If not supplied by the user default values are used.
4102c67b6e56 Restoring the missing activity related and music headers
cgandhi <chandradeep.gandhi@sasken.com>
parents:
diff changeset
   343
   * @param pageNum Page number to download, SMF_FIRST_PAGE denotes fresh query.
14
a469c0e6e7fb changes for SmfPost, SmfCredentialMgr, PLuginManager, SmfServer. Adding Sample Plugins and Sample Client Applications.
cgandhi <chandradeep.gandhi@sasken.com>
parents: 8
diff changeset
   344
   * @param perPage Item per page, default is SMF_ITEMS_PER_PAGE
8
4102c67b6e56 Restoring the missing activity related and music headers
cgandhi <chandradeep.gandhi@sasken.com>
parents:
diff changeset
   345
   */
14
a469c0e6e7fb changes for SmfPost, SmfCredentialMgr, PLuginManager, SmfServer. Adding Sample Plugins and Sample Client Applications.
cgandhi <chandradeep.gandhi@sasken.com>
parents: 8
diff changeset
   346
  void events(QContactGeoLocation location,int pageNum=SMF_FIRST_PAGE,int perPage=SMF_ITEMS_PER_PAGE)  ;
8
4102c67b6e56 Restoring the missing activity related and music headers
cgandhi <chandradeep.gandhi@sasken.com>
parents:
diff changeset
   347
4102c67b6e56 Restoring the missing activity related and music headers
cgandhi <chandradeep.gandhi@sasken.com>
parents:
diff changeset
   348
  /**
4102c67b6e56 Restoring the missing activity related and music headers
cgandhi <chandradeep.gandhi@sasken.com>
parents:
diff changeset
   349
   * Gets list of venues of a particular location asynchronously.
14
a469c0e6e7fb changes for SmfPost, SmfCredentialMgr, PLuginManager, SmfServer. Adding Sample Plugins and Sample Client Applications.
cgandhi <chandradeep.gandhi@sasken.com>
parents: 8
diff changeset
   350
   * venuesAvailable() signal is emitted with SmfLocationList once its arrived.
8
4102c67b6e56 Restoring the missing activity related and music headers
cgandhi <chandradeep.gandhi@sasken.com>
parents:
diff changeset
   351
   * When the list is big user can specify the page number and per page item data.
4102c67b6e56 Restoring the missing activity related and music headers
cgandhi <chandradeep.gandhi@sasken.com>
parents:
diff changeset
   352
   * If not supplied by the user default values are used.
4102c67b6e56 Restoring the missing activity related and music headers
cgandhi <chandradeep.gandhi@sasken.com>
parents:
diff changeset
   353
   * @param pageNum Page number to download, SMF_FIRST_PAGE denotes fresh query.
14
a469c0e6e7fb changes for SmfPost, SmfCredentialMgr, PLuginManager, SmfServer. Adding Sample Plugins and Sample Client Applications.
cgandhi <chandradeep.gandhi@sasken.com>
parents: 8
diff changeset
   354
   * @param perPage Item per page, default is SMF_ITEMS_PER_PAGE
8
4102c67b6e56 Restoring the missing activity related and music headers
cgandhi <chandradeep.gandhi@sasken.com>
parents:
diff changeset
   355
   */
14
a469c0e6e7fb changes for SmfPost, SmfCredentialMgr, PLuginManager, SmfServer. Adding Sample Plugins and Sample Client Applications.
cgandhi <chandradeep.gandhi@sasken.com>
parents: 8
diff changeset
   356
  void venues(QContactGeoLocation location,int pageNum=SMF_FIRST_PAGE,int perPage=SMF_ITEMS_PER_PAGE)  ; // basic list of venue objects
8
4102c67b6e56 Restoring the missing activity related and music headers
cgandhi <chandradeep.gandhi@sasken.com>
parents:
diff changeset
   357
4102c67b6e56 Restoring the missing activity related and music headers
cgandhi <chandradeep.gandhi@sasken.com>
parents:
diff changeset
   358
  /**
4102c67b6e56 Restoring the missing activity related and music headers
cgandhi <chandradeep.gandhi@sasken.com>
parents:
diff changeset
   359
   * Gets list of events in a particular venue asynchronously.
4102c67b6e56 Restoring the missing activity related and music headers
cgandhi <chandradeep.gandhi@sasken.com>
parents:
diff changeset
   360
   * eventsAvailable() signal is emitted with SmfEventsList once its arrived.
4102c67b6e56 Restoring the missing activity related and music headers
cgandhi <chandradeep.gandhi@sasken.com>
parents:
diff changeset
   361
   * When the list is big user can specify the page number and per page item data.
4102c67b6e56 Restoring the missing activity related and music headers
cgandhi <chandradeep.gandhi@sasken.com>
parents:
diff changeset
   362
   * If not supplied by the user default values are used.
4102c67b6e56 Restoring the missing activity related and music headers
cgandhi <chandradeep.gandhi@sasken.com>
parents:
diff changeset
   363
   * @param pageNum Page number to download, SMF_FIRST_PAGE denotes fresh query.
4102c67b6e56 Restoring the missing activity related and music headers
cgandhi <chandradeep.gandhi@sasken.com>
parents:
diff changeset
   364
   * @param perPage Item per page, default is SMF_ITEMS_PER_PAGE
4102c67b6e56 Restoring the missing activity related and music headers
cgandhi <chandradeep.gandhi@sasken.com>
parents:
diff changeset
   365
   */
14
a469c0e6e7fb changes for SmfPost, SmfCredentialMgr, PLuginManager, SmfServer. Adding Sample Plugins and Sample Client Applications.
cgandhi <chandradeep.gandhi@sasken.com>
parents: 8
diff changeset
   366
  void events(SmfLocation venue,int pageNum=SMF_FIRST_PAGE,int perPage=SMF_ITEMS_PER_PAGE)  ; // basic list of events objects
8
4102c67b6e56 Restoring the missing activity related and music headers
cgandhi <chandradeep.gandhi@sasken.com>
parents:
diff changeset
   367
4102c67b6e56 Restoring the missing activity related and music headers
cgandhi <chandradeep.gandhi@sasken.com>
parents:
diff changeset
   368
4102c67b6e56 Restoring the missing activity related and music headers
cgandhi <chandradeep.gandhi@sasken.com>
parents:
diff changeset
   369
  //APIs to get/set base provider info (SmfProvider)
4102c67b6e56 Restoring the missing activity related and music headers
cgandhi <chandradeep.gandhi@sasken.com>
parents:
diff changeset
   370
4102c67b6e56 Restoring the missing activity related and music headers
cgandhi <chandradeep.gandhi@sasken.com>
parents:
diff changeset
   371
  /**
4102c67b6e56 Restoring the missing activity related and music headers
cgandhi <chandradeep.gandhi@sasken.com>
parents:
diff changeset
   372
   * Gets the base provider info
4102c67b6e56 Restoring the missing activity related and music headers
cgandhi <chandradeep.gandhi@sasken.com>
parents:
diff changeset
   373
   */
4102c67b6e56 Restoring the missing activity related and music headers
cgandhi <chandradeep.gandhi@sasken.com>
parents:
diff changeset
   374
  SmfProvider* getProvider()  ;
4102c67b6e56 Restoring the missing activity related and music headers
cgandhi <chandradeep.gandhi@sasken.com>
parents:
diff changeset
   375
4102c67b6e56 Restoring the missing activity related and music headers
cgandhi <chandradeep.gandhi@sasken.com>
parents:
diff changeset
   376
4102c67b6e56 Restoring the missing activity related and music headers
cgandhi <chandradeep.gandhi@sasken.com>
parents:
diff changeset
   377
public slots:
4102c67b6e56 Restoring the missing activity related and music headers
cgandhi <chandradeep.gandhi@sasken.com>
parents:
diff changeset
   378
4102c67b6e56 Restoring the missing activity related and music headers
cgandhi <chandradeep.gandhi@sasken.com>
parents:
diff changeset
   379
	/**
4102c67b6e56 Restoring the missing activity related and music headers
cgandhi <chandradeep.gandhi@sasken.com>
parents:
diff changeset
   380
	 * Updates events. Might not be supported by all service provider.
4102c67b6e56 Restoring the missing activity related and music headers
cgandhi <chandradeep.gandhi@sasken.com>
parents:
diff changeset
   381
	 * eventsUpdated() signal can be checked for success value.
14
a469c0e6e7fb changes for SmfPost, SmfCredentialMgr, PLuginManager, SmfServer. Adding Sample Plugins and Sample Client Applications.
cgandhi <chandradeep.gandhi@sasken.com>
parents: 8
diff changeset
   382
	 * @param SmfEventsList List of events to be posted
8
4102c67b6e56 Restoring the missing activity related and music headers
cgandhi <chandradeep.gandhi@sasken.com>
parents:
diff changeset
   383
	 */
14
a469c0e6e7fb changes for SmfPost, SmfCredentialMgr, PLuginManager, SmfServer. Adding Sample Plugins and Sample Client Applications.
cgandhi <chandradeep.gandhi@sasken.com>
parents: 8
diff changeset
   384
	 void postEvents(SmfEventList events);
8
4102c67b6e56 Restoring the missing activity related and music headers
cgandhi <chandradeep.gandhi@sasken.com>
parents:
diff changeset
   385
4102c67b6e56 Restoring the missing activity related and music headers
cgandhi <chandradeep.gandhi@sasken.com>
parents:
diff changeset
   386
signals:
4102c67b6e56 Restoring the missing activity related and music headers
cgandhi <chandradeep.gandhi@sasken.com>
parents:
diff changeset
   387
4102c67b6e56 Restoring the missing activity related and music headers
cgandhi <chandradeep.gandhi@sasken.com>
parents:
diff changeset
   388
	/**
14
a469c0e6e7fb changes for SmfPost, SmfCredentialMgr, PLuginManager, SmfServer. Adding Sample Plugins and Sample Client Applications.
cgandhi <chandradeep.gandhi@sasken.com>
parents: 8
diff changeset
   389
	 * Notification of the success of request to post an event
8
4102c67b6e56 Restoring the missing activity related and music headers
cgandhi <chandradeep.gandhi@sasken.com>
parents:
diff changeset
   390
	 */
14
a469c0e6e7fb changes for SmfPost, SmfCredentialMgr, PLuginManager, SmfServer. Adding Sample Plugins and Sample Client Applications.
cgandhi <chandradeep.gandhi@sasken.com>
parents: 8
diff changeset
   391
	void eventsUpdated(SmfError success);
8
4102c67b6e56 Restoring the missing activity related and music headers
cgandhi <chandradeep.gandhi@sasken.com>
parents:
diff changeset
   392
4102c67b6e56 Restoring the missing activity related and music headers
cgandhi <chandradeep.gandhi@sasken.com>
parents:
diff changeset
   393
	/**
4102c67b6e56 Restoring the missing activity related and music headers
cgandhi <chandradeep.gandhi@sasken.com>
parents:
diff changeset
   394
	 * Notification on arrival of event lists
4102c67b6e56 Restoring the missing activity related and music headers
cgandhi <chandradeep.gandhi@sasken.com>
parents:
diff changeset
   395
	 * Note if number of list is large, then it can download the list page by page.
4102c67b6e56 Restoring the missing activity related and music headers
cgandhi <chandradeep.gandhi@sasken.com>
parents:
diff changeset
   396
	 * In that case this signal is emitted multiple times.
14
a469c0e6e7fb changes for SmfPost, SmfCredentialMgr, PLuginManager, SmfServer. Adding Sample Plugins and Sample Client Applications.
cgandhi <chandradeep.gandhi@sasken.com>
parents: 8
diff changeset
   397
	 * @param resultPage Page number info
8
4102c67b6e56 Restoring the missing activity related and music headers
cgandhi <chandradeep.gandhi@sasken.com>
parents:
diff changeset
   398
	 */
14
a469c0e6e7fb changes for SmfPost, SmfCredentialMgr, PLuginManager, SmfServer. Adding Sample Plugins and Sample Client Applications.
cgandhi <chandradeep.gandhi@sasken.com>
parents: 8
diff changeset
   399
	void eventsAvailable(SmfEventList* list, SmfError error, SmfResultPage resultPage);
8
4102c67b6e56 Restoring the missing activity related and music headers
cgandhi <chandradeep.gandhi@sasken.com>
parents:
diff changeset
   400
4102c67b6e56 Restoring the missing activity related and music headers
cgandhi <chandradeep.gandhi@sasken.com>
parents:
diff changeset
   401
	/**
4102c67b6e56 Restoring the missing activity related and music headers
cgandhi <chandradeep.gandhi@sasken.com>
parents:
diff changeset
   402
	 *  Notification on arrival of venues lists
4102c67b6e56 Restoring the missing activity related and music headers
cgandhi <chandradeep.gandhi@sasken.com>
parents:
diff changeset
   403
	 * Note if number of list is large, then it can download the list page by page.
4102c67b6e56 Restoring the missing activity related and music headers
cgandhi <chandradeep.gandhi@sasken.com>
parents:
diff changeset
   404
	 * In that case this signal is emitted multiple times.
14
a469c0e6e7fb changes for SmfPost, SmfCredentialMgr, PLuginManager, SmfServer. Adding Sample Plugins and Sample Client Applications.
cgandhi <chandradeep.gandhi@sasken.com>
parents: 8
diff changeset
   405
	 * @param resultPage Page number info
8
4102c67b6e56 Restoring the missing activity related and music headers
cgandhi <chandradeep.gandhi@sasken.com>
parents:
diff changeset
   406
	 */
14
a469c0e6e7fb changes for SmfPost, SmfCredentialMgr, PLuginManager, SmfServer. Adding Sample Plugins and Sample Client Applications.
cgandhi <chandradeep.gandhi@sasken.com>
parents: 8
diff changeset
   407
	void venuesAvailable(SmfLocationList* list, SmfError error, SmfResultPage resultPage);
8
4102c67b6e56 Restoring the missing activity related and music headers
cgandhi <chandradeep.gandhi@sasken.com>
parents:
diff changeset
   408
private:
4102c67b6e56 Restoring the missing activity related and music headers
cgandhi <chandradeep.gandhi@sasken.com>
parents:
diff changeset
   409
  SmfProvider* m_baseProvider;
14
a469c0e6e7fb changes for SmfPost, SmfCredentialMgr, PLuginManager, SmfServer. Adding Sample Plugins and Sample Client Applications.
cgandhi <chandradeep.gandhi@sasken.com>
parents: 8
diff changeset
   410
  SmfMusicEventsPrivate* m_private;
a469c0e6e7fb changes for SmfPost, SmfCredentialMgr, PLuginManager, SmfServer. Adding Sample Plugins and Sample Client Applications.
cgandhi <chandradeep.gandhi@sasken.com>
parents: 8
diff changeset
   411
  friend class SmfMusicEventsPrivate;
8
4102c67b6e56 Restoring the missing activity related and music headers
cgandhi <chandradeep.gandhi@sasken.com>
parents:
diff changeset
   412
};
4102c67b6e56 Restoring the missing activity related and music headers
cgandhi <chandradeep.gandhi@sasken.com>
parents:
diff changeset
   413
SMF_SERVICE_NAME(SmfMusicEvents, "org.symbian.smf.client.music.events\0.2")
4102c67b6e56 Restoring the missing activity related and music headers
cgandhi <chandradeep.gandhi@sasken.com>
parents:
diff changeset
   414
4102c67b6e56 Restoring the missing activity related and music headers
cgandhi <chandradeep.gandhi@sasken.com>
parents:
diff changeset
   415
4102c67b6e56 Restoring the missing activity related and music headers
cgandhi <chandradeep.gandhi@sasken.com>
parents:
diff changeset
   416
/**
4102c67b6e56 Restoring the missing activity related and music headers
cgandhi <chandradeep.gandhi@sasken.com>
parents:
diff changeset
   417
* provides service ("org.symbian.smf.client.music.lyrics")
4102c67b6e56 Restoring the missing activity related and music headers
cgandhi <chandradeep.gandhi@sasken.com>
parents:
diff changeset
   418
*/
4102c67b6e56 Restoring the missing activity related and music headers
cgandhi <chandradeep.gandhi@sasken.com>
parents:
diff changeset
   419
class SMFCLIENT_EXPORT SmfLyricsService : public QObject
4102c67b6e56 Restoring the missing activity related and music headers
cgandhi <chandradeep.gandhi@sasken.com>
parents:
diff changeset
   420
{
4102c67b6e56 Restoring the missing activity related and music headers
cgandhi <chandradeep.gandhi@sasken.com>
parents:
diff changeset
   421
  Q_OBJECT
4102c67b6e56 Restoring the missing activity related and music headers
cgandhi <chandradeep.gandhi@sasken.com>
parents:
diff changeset
   422
4102c67b6e56 Restoring the missing activity related and music headers
cgandhi <chandradeep.gandhi@sasken.com>
parents:
diff changeset
   423
public:
4102c67b6e56 Restoring the missing activity related and music headers
cgandhi <chandradeep.gandhi@sasken.com>
parents:
diff changeset
   424
  /**
4102c67b6e56 Restoring the missing activity related and music headers
cgandhi <chandradeep.gandhi@sasken.com>
parents:
diff changeset
   425
   * Constructs SmfLyricsService with base provider info.
4102c67b6e56 Restoring the missing activity related and music headers
cgandhi <chandradeep.gandhi@sasken.com>
parents:
diff changeset
   426
   * Seeing as this is a plug-in implementation, these will realistically
14
a469c0e6e7fb changes for SmfPost, SmfCredentialMgr, PLuginManager, SmfServer. Adding Sample Plugins and Sample Client Applications.
cgandhi <chandradeep.gandhi@sasken.com>
parents: 8
diff changeset
   427
   * be generated by SMF factory of some kind
8
4102c67b6e56 Restoring the missing activity related and music headers
cgandhi <chandradeep.gandhi@sasken.com>
parents:
diff changeset
   428
   */
4102c67b6e56 Restoring the missing activity related and music headers
cgandhi <chandradeep.gandhi@sasken.com>
parents:
diff changeset
   429
4102c67b6e56 Restoring the missing activity related and music headers
cgandhi <chandradeep.gandhi@sasken.com>
parents:
diff changeset
   430
  SmfLyricsService(SmfProvider* baseProvider = 0);
4102c67b6e56 Restoring the missing activity related and music headers
cgandhi <chandradeep.gandhi@sasken.com>
parents:
diff changeset
   431
  ~SmfLyricsService();
4102c67b6e56 Restoring the missing activity related and music headers
cgandhi <chandradeep.gandhi@sasken.com>
parents:
diff changeset
   432
4102c67b6e56 Restoring the missing activity related and music headers
cgandhi <chandradeep.gandhi@sasken.com>
parents:
diff changeset
   433
public:
4102c67b6e56 Restoring the missing activity related and music headers
cgandhi <chandradeep.gandhi@sasken.com>
parents:
diff changeset
   434
4102c67b6e56 Restoring the missing activity related and music headers
cgandhi <chandradeep.gandhi@sasken.com>
parents:
diff changeset
   435
  /**
4102c67b6e56 Restoring the missing activity related and music headers
cgandhi <chandradeep.gandhi@sasken.com>
parents:
diff changeset
   436
   * Get the lyrics lists asynchrnously, it fetches texts without time info.
4102c67b6e56 Restoring the missing activity related and music headers
cgandhi <chandradeep.gandhi@sasken.com>
parents:
diff changeset
   437
   * lyricsAvailable() notification comes SmfLyricsList with when the data is available
4102c67b6e56 Restoring the missing activity related and music headers
cgandhi <chandradeep.gandhi@sasken.com>
parents:
diff changeset
   438
   * @param track Track for which lyrics needs to be fetched.
4102c67b6e56 Restoring the missing activity related and music headers
cgandhi <chandradeep.gandhi@sasken.com>
parents:
diff changeset
   439
   * @param pageNum Page number to download, SMF_FIRST_PAGE denotes fresh query.
14
a469c0e6e7fb changes for SmfPost, SmfCredentialMgr, PLuginManager, SmfServer. Adding Sample Plugins and Sample Client Applications.
cgandhi <chandradeep.gandhi@sasken.com>
parents: 8
diff changeset
   440
   * @param perPage Item per page, default is SMF_ITEMS_PER_PAGE
8
4102c67b6e56 Restoring the missing activity related and music headers
cgandhi <chandradeep.gandhi@sasken.com>
parents:
diff changeset
   441
   */
4102c67b6e56 Restoring the missing activity related and music headers
cgandhi <chandradeep.gandhi@sasken.com>
parents:
diff changeset
   442
  void lyrics(SmfTrackInfo track,int pageNum=SMF_FIRST_PAGE,int perPage=SMF_ITEMS_PER_PAGE)  ;
4102c67b6e56 Restoring the missing activity related and music headers
cgandhi <chandradeep.gandhi@sasken.com>
parents:
diff changeset
   443
4102c67b6e56 Restoring the missing activity related and music headers
cgandhi <chandradeep.gandhi@sasken.com>
parents:
diff changeset
   444
  /**
4102c67b6e56 Restoring the missing activity related and music headers
cgandhi <chandradeep.gandhi@sasken.com>
parents:
diff changeset
   445
   * Get the lyrics lists asynchrnously, it fetches texts with time info.
4102c67b6e56 Restoring the missing activity related and music headers
cgandhi <chandradeep.gandhi@sasken.com>
parents:
diff changeset
   446
   * Subtitle search filter can be applied
4102c67b6e56 Restoring the missing activity related and music headers
cgandhi <chandradeep.gandhi@sasken.com>
parents:
diff changeset
   447
   * subtitleAvailable() notification comes SmfSubtitleList with when the data is available
4102c67b6e56 Restoring the missing activity related and music headers
cgandhi <chandradeep.gandhi@sasken.com>
parents:
diff changeset
   448
   * @param track Track for which subtitle needs to be fetched.
4102c67b6e56 Restoring the missing activity related and music headers
cgandhi <chandradeep.gandhi@sasken.com>
parents:
diff changeset
   449
   * @param filter Subtitle search filter
4102c67b6e56 Restoring the missing activity related and music headers
cgandhi <chandradeep.gandhi@sasken.com>
parents:
diff changeset
   450
   * @param pageNum Page number to download, SMF_FIRST_PAGE denotes fresh query.
4102c67b6e56 Restoring the missing activity related and music headers
cgandhi <chandradeep.gandhi@sasken.com>
parents:
diff changeset
   451
   * @param perPage Item per page, default is SMF_ITEMS_PER_PAGE
4102c67b6e56 Restoring the missing activity related and music headers
cgandhi <chandradeep.gandhi@sasken.com>
parents:
diff changeset
   452
   */
4102c67b6e56 Restoring the missing activity related and music headers
cgandhi <chandradeep.gandhi@sasken.com>
parents:
diff changeset
   453
  void subtitles(SmfTrackInfo track, SmfSubtitleSearchFilter filter,int pageNum=SMF_FIRST_PAGE,int perPage=SMF_ITEMS_PER_PAGE)  ; // texts with time information
4102c67b6e56 Restoring the missing activity related and music headers
cgandhi <chandradeep.gandhi@sasken.com>
parents:
diff changeset
   454
  //APIs to get/set base provider info (SmfProvider)
4102c67b6e56 Restoring the missing activity related and music headers
cgandhi <chandradeep.gandhi@sasken.com>
parents:
diff changeset
   455
4102c67b6e56 Restoring the missing activity related and music headers
cgandhi <chandradeep.gandhi@sasken.com>
parents:
diff changeset
   456
  /**
4102c67b6e56 Restoring the missing activity related and music headers
cgandhi <chandradeep.gandhi@sasken.com>
parents:
diff changeset
   457
   * Gets the base provider info
4102c67b6e56 Restoring the missing activity related and music headers
cgandhi <chandradeep.gandhi@sasken.com>
parents:
diff changeset
   458
   */
4102c67b6e56 Restoring the missing activity related and music headers
cgandhi <chandradeep.gandhi@sasken.com>
parents:
diff changeset
   459
  SmfProvider* getProvider()  ;
4102c67b6e56 Restoring the missing activity related and music headers
cgandhi <chandradeep.gandhi@sasken.com>
parents:
diff changeset
   460
signals:
4102c67b6e56 Restoring the missing activity related and music headers
cgandhi <chandradeep.gandhi@sasken.com>
parents:
diff changeset
   461
4102c67b6e56 Restoring the missing activity related and music headers
cgandhi <chandradeep.gandhi@sasken.com>
parents:
diff changeset
   462
	/**
4102c67b6e56 Restoring the missing activity related and music headers
cgandhi <chandradeep.gandhi@sasken.com>
parents:
diff changeset
   463
	 * Notification on arrival of lyrics
4102c67b6e56 Restoring the missing activity related and music headers
cgandhi <chandradeep.gandhi@sasken.com>
parents:
diff changeset
   464
	 * Note if the list is large, then it can download the list page by page.
4102c67b6e56 Restoring the missing activity related and music headers
cgandhi <chandradeep.gandhi@sasken.com>
parents:
diff changeset
   465
	 * In that case this signal is emitted multiple times.
14
a469c0e6e7fb changes for SmfPost, SmfCredentialMgr, PLuginManager, SmfServer. Adding Sample Plugins and Sample Client Applications.
cgandhi <chandradeep.gandhi@sasken.com>
parents: 8
diff changeset
   466
	 * @param resultPage Page number info
8
4102c67b6e56 Restoring the missing activity related and music headers
cgandhi <chandradeep.gandhi@sasken.com>
parents:
diff changeset
   467
	 */
14
a469c0e6e7fb changes for SmfPost, SmfCredentialMgr, PLuginManager, SmfServer. Adding Sample Plugins and Sample Client Applications.
cgandhi <chandradeep.gandhi@sasken.com>
parents: 8
diff changeset
   468
	void lyricsAvailable(SmfLyricsList* list, SmfError error, SmfResultPage resultPage);
8
4102c67b6e56 Restoring the missing activity related and music headers
cgandhi <chandradeep.gandhi@sasken.com>
parents:
diff changeset
   469
4102c67b6e56 Restoring the missing activity related and music headers
cgandhi <chandradeep.gandhi@sasken.com>
parents:
diff changeset
   470
	/**
4102c67b6e56 Restoring the missing activity related and music headers
cgandhi <chandradeep.gandhi@sasken.com>
parents:
diff changeset
   471
	 * Notification on arrival of subtitle based on filter.
4102c67b6e56 Restoring the missing activity related and music headers
cgandhi <chandradeep.gandhi@sasken.com>
parents:
diff changeset
   472
	 * Note if the list is large, then it can download the list page by page.
4102c67b6e56 Restoring the missing activity related and music headers
cgandhi <chandradeep.gandhi@sasken.com>
parents:
diff changeset
   473
	 * In that case this signal is emitted multiple times.
14
a469c0e6e7fb changes for SmfPost, SmfCredentialMgr, PLuginManager, SmfServer. Adding Sample Plugins and Sample Client Applications.
cgandhi <chandradeep.gandhi@sasken.com>
parents: 8
diff changeset
   474
	 * @param resultPage Page number info
8
4102c67b6e56 Restoring the missing activity related and music headers
cgandhi <chandradeep.gandhi@sasken.com>
parents:
diff changeset
   475
	 */
14
a469c0e6e7fb changes for SmfPost, SmfCredentialMgr, PLuginManager, SmfServer. Adding Sample Plugins and Sample Client Applications.
cgandhi <chandradeep.gandhi@sasken.com>
parents: 8
diff changeset
   476
	void subtitleAvailable(SmfSubtitleList* list, SmfError error, SmfResultPage resultPage);
8
4102c67b6e56 Restoring the missing activity related and music headers
cgandhi <chandradeep.gandhi@sasken.com>
parents:
diff changeset
   477
private:
4102c67b6e56 Restoring the missing activity related and music headers
cgandhi <chandradeep.gandhi@sasken.com>
parents:
diff changeset
   478
  SmfProvider* m_baseProvider;
14
a469c0e6e7fb changes for SmfPost, SmfCredentialMgr, PLuginManager, SmfServer. Adding Sample Plugins and Sample Client Applications.
cgandhi <chandradeep.gandhi@sasken.com>
parents: 8
diff changeset
   479
  SmfLyricsServicePrivate* m_private;
a469c0e6e7fb changes for SmfPost, SmfCredentialMgr, PLuginManager, SmfServer. Adding Sample Plugins and Sample Client Applications.
cgandhi <chandradeep.gandhi@sasken.com>
parents: 8
diff changeset
   480
  friend class SmfLyricsServicePrivate;
8
4102c67b6e56 Restoring the missing activity related and music headers
cgandhi <chandradeep.gandhi@sasken.com>
parents:
diff changeset
   481
};
4102c67b6e56 Restoring the missing activity related and music headers
cgandhi <chandradeep.gandhi@sasken.com>
parents:
diff changeset
   482
SMF_SERVICE_NAME(SmfLyricsService, "org.symbian.smf.client.music.lyrics\0.2")
4102c67b6e56 Restoring the missing activity related and music headers
cgandhi <chandradeep.gandhi@sasken.com>
parents:
diff changeset
   483
4102c67b6e56 Restoring the missing activity related and music headers
cgandhi <chandradeep.gandhi@sasken.com>
parents:
diff changeset
   484
#endif // SMFMUSIC_H
4102c67b6e56 Restoring the missing activity related and music headers
cgandhi <chandradeep.gandhi@sasken.com>
parents:
diff changeset
   485