epoc32/include/remconmediainformationtargetobserver.h
author William Roberts <williamr@symbian.org>
Tue, 16 Mar 2010 16:12:26 +0000
branchSymbian2
changeset 2 2fe1408b6811
permissions -rw-r--r--
Final list of Symbian^2 public API header files
     1 // Copyright (c) 2007-2009 Nokia Corporation and/or its subsidiary(-ies).
     2 // All rights reserved.
     3 // This component and the accompanying materials are made available
     4 // under the terms of the License "Symbian Foundation License v1.0" to Symbian Foundation members and "Symbian Foundation End User License Agreement v1.0" to non-members
     5 // which accompanies this distribution, and is available
     6 // at the URL "http://www.symbianfoundation.org/legal/licencesv10.html".
     7 //
     8 // Initial Contributors:
     9 // Nokia Corporation - initial contribution.
    10 //
    11 // Contributors:
    12 //
    13 // Description:
    14 //
    15 
    16 
    17 
    18 /**
    19  @file
    20  @publishedAll
    21  @released
    22 */
    23 
    24 #ifndef REMCONMEDIAINFORMATIONTARGETOBSERVER_H
    25 #define REMCONMEDIAINFORMATIONTARGETOBSERVER_H
    26 
    27 #include <e32base.h>
    28 
    29 enum TMediaAttributeId
    30 	{
    31 	ETitleOfMedia 			=0x1,
    32 	ENameOfArtist			=0x2,
    33 	ENameOfAlbum			=0x3,
    34 	ETrackNumber			=0x4,		/* for example the CD track number */
    35 	ENumberOfTracks			=0x5,		/* for example the total track number of the CD */
    36 	EGenre					=0x6,
    37 	EPlayingTime			=0x7
    38 	};
    39 
    40 /**
    41  * Provide an iterator wrapper class 
    42  */
    43 class TMediaAttributeIter
    44 	{
    45 public:
    46 	TMediaAttributeIter(RArray<TMediaAttributeId>& aMediaAttributeIDs);
    47 	IMPORT_C void Start();
    48 	IMPORT_C TBool Next(TMediaAttributeId& aId);
    49 	
    50 private:
    51 	RArray<TMediaAttributeId>& iMediaAttributeIDs;
    52 	TInt iterator;
    53 	};
    54 
    55 
    56 /**
    57 Clients must implement this interface in order to instantiate objects of type 
    58 CRemConMediaInformationTarget. This interface passes incoming commands from RemCon to 
    59 the client. 
    60 */
    61 NONSHARABLE_CLASS(MRemConMediaInformationTargetObserver)
    62 	{
    63 public:
    64 
    65 	/**
    66 	For each element in aAttributeList for which the requested Metadata is available,
    67 	the client shall respond by calling CRemConMediaInformationTarget::AttributeValue(). 
    68 	After all attributes have been supplied the client shall call CRemConMediaInformationTarget::Completed().
    69 	@param aAttributeList A CMediaAttributeIDs containing a list of TMediaAttributeIds requested by the controller
    70 	@see CRemConMediaInformationTarget::AttributeValue()
    71 	@see CRemConMediaInformationTarget::Completed()
    72 	*/
    73 	virtual void MrcmitoGetCurrentlyPlayingMetadata( TMediaAttributeIter& aAttributeIter ) = 0;
    74 
    75 	};
    76 
    77 #endif // REMCONMEDIAINFORMATIONTARGETOBSERVER_H