epoc32/include/mmf/common/mmfdurationinfocustomcommands.h
branchSymbian3
changeset 4 837f303aceeb
parent 2 2fe1408b6811
equal deleted inserted replaced
3:e1b950c65cb4 4:837f303aceeb
     1 // Copyright (c) 2004-2009 Nokia Corporation and/or its subsidiary(-ies).
     1 // Copyright (c) 2004-2009 Nokia Corporation and/or its subsidiary(-ies).
     2 // All rights reserved.
     2 // All rights reserved.
     3 // This component and the accompanying materials are made available
     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
     4 // under the terms of "Eclipse Public License v1.0"
     5 // which accompanies this distribution, and is available
     5 // which accompanies this distribution, and is available
     6 // at the URL "http://www.symbianfoundation.org/legal/licencesv10.html".
     6 // at the URL "http://www.eclipse.org/legal/epl-v10.html".
     7 //
     7 //
     8 // Initial Contributors:
     8 // Initial Contributors:
     9 // Nokia Corporation - initial contribution.
     9 // Nokia Corporation - initial contribution.
    10 //
    10 //
    11 // Contributors:
    11 // Contributors:
    17 #define __MMF_DURATION_INFO_CUSTOM_COMMANDS_H__
    17 #define __MMF_DURATION_INFO_CUSTOM_COMMANDS_H__
    18 
    18 
    19 #ifdef SYMBIAN_CAF_V2
    19 #ifdef SYMBIAN_CAF_V2
    20 
    20 
    21 #include <e32base.h>
    21 #include <e32base.h>
    22 #include <mmf/common/mmcaf.h>
    22 #include "mmf/common/mmcaf.h"
    23 #include <mmf/common/mmfstandardcustomcommands.h>
    23 #include <mmf/common/mmfstandardcustomcommands.h>
    24 
    24 
    25 
    25 
    26 /**
    26 /**
    27 @publishedAll
    27 @publishedAll
    29 */
    29 */
    30 
    30 
    31 const TUid KUidInterfaceMMFDurationInfoControl = {0x102737C8};
    31 const TUid KUidInterfaceMMFDurationInfoControl = {0x102737C8};
    32 
    32 
    33 /**
    33 /**
    34 @publishedPartner
    34 @publishedAll
    35 @released
       
    36 */
       
    37 
       
    38 const TUid KUidInterfaceMMFDurationInfoControl2 = {0x10273812};
       
    39 
       
    40 /**
       
    41 @internalComponent
       
    42 */
       
    43 enum TMMFDurationInfoMessages
       
    44 	{
       
    45 	EMMFGetDurationInfo
       
    46 	};
       
    47 	
       
    48 	
       
    49 /**
       
    50 @publishedPartner
       
    51 @released
    35 @released
    52 
    36 
    53 The duration state of the controller.
    37 The duration state of the controller.
    54 */
    38 */
    55 enum TMMFDurationInfo
    39 enum TMMFDurationInfo
    56 	{
    40 	{
    57 	EMMFDurationInfoValid, 		// Duration is known
    41 	EMMFDurationInfoValid, 		// Duration is known
    58 	EMMFDurationInfoUnknown,	// Invalid response from controller
    42 	EMMFDurationInfoUnknown,	// Invalid response from controller
    59 	EMMFDurationInfoInfinite,	// Clip is of infinite length
    43 	EMMFDurationInfoInfinite,	// Clip is of infinite length
    60 	};
    44 	};
       
    45 
       
    46 #ifndef SYMBIAN_ENABLE_SPLIT_HEADERS
       
    47 #include <mmf/common/mmfdurationinfocustomcommandsimpl.h>
       
    48 #include <mmf/common/mmfdurationinfocustomcommandsenums.h>
       
    49 #endif
    61 
    50 
    62 /**
    51 /**
    63 @publishedAll
    52 @publishedAll
    64 @deprecated 9.2 - Replaced by MMMFDurationInfoCustomCommandImplementor2
    53 @deprecated 9.2 - Replaced by MMMFDurationInfoCustomCommandImplementor2
    65 
    54 
   139 private:
   128 private:
   140 
   129 
   141 	MMMFDurationInfoCustomCommandImplementor& iImplementor;
   130 	MMMFDurationInfoCustomCommandImplementor& iImplementor;
   142 	
   131 	
   143 	};
   132 	};
   144 	
       
   145 /**
       
   146 @publishedPartner
       
   147 @released
       
   148 
       
   149 Mixin class to be derived from by controller plugins wishing to support the Duration information 
       
   150 custom commands
       
   151 */
       
   152 class MMMFDurationInfoCustomCommandImplementor2
       
   153 	{
       
   154 public:
       
   155 
       
   156 	/**
       
   157 	Is the duration of the clip known? i.e. is the stream infinite?
       
   158 	
       
   159 	@param aDurationInfo
       
   160 		   Controller duration information
       
   161 		   
       
   162 	@return KErrNone or System wide error code
       
   163 	*/
       
   164 	virtual TInt GetDurationInfo(TMMFDurationInfo& aDurationInfo)=0;
       
   165 	};
       
   166 	
       
   167 /**
       
   168 @publishedPartner
       
   169 @released
       
   170 
       
   171 Custom command parser capable of processing duration information controller commands
       
   172 */
       
   173 class CMMFDurationInfoCustomCommandParser2 : public CMMFCustomCommandParserBase
       
   174 	{
       
   175 public:
       
   176 
       
   177 	/**
       
   178 	Creates a new custom command parser capable of processing duration information controller commands.
       
   179 
       
   180 	@param  aImplementor
       
   181 	        A reference to the controller plugin that owns this new object.
       
   182 
       
   183 	@return A pointer to the object created.
       
   184 
       
   185 	@since  9.2
       
   186 	*/
       
   187 	IMPORT_C static CMMFDurationInfoCustomCommandParser2* NewL(MMMFDurationInfoCustomCommandImplementor2& aImplementor);
       
   188 
       
   189 	/**
       
   190 	Destructor.
       
   191 
       
   192 	@since  9.2
       
   193 	*/
       
   194 	IMPORT_C ~CMMFDurationInfoCustomCommandParser2();
       
   195 
       
   196 	/**
       
   197 	Handles a request from the client. Called by the controller framework.
       
   198 
       
   199 	@param  aMessage
       
   200 	        The message to be handled.
       
   201 
       
   202 	@since  9.2
       
   203 	*/
       
   204 	void HandleRequest(TMMFMessage& aMessage);
       
   205 
       
   206 private:
       
   207 	/**
       
   208 	Constructor.
       
   209 
       
   210 	@param  aImplementor
       
   211 	        A reference to the controller plugin that owns this new object.
       
   212 	@since  9.2
       
   213 	*/
       
   214 	CMMFDurationInfoCustomCommandParser2(MMMFDurationInfoCustomCommandImplementor2& aImplementor);
       
   215 	
       
   216 	/**
       
   217 	Request duration information from the implementor
       
   218 
       
   219 	@param  aMessage
       
   220 	        Message for writing results to the client.
       
   221 	*/
       
   222 	TInt GetDurationInfo(TMMFMessage& aMessage);
       
   223 
       
   224 private:
       
   225 	MMMFDurationInfoCustomCommandImplementor2& iImplementor;
       
   226 	};
       
   227 
   133 
   228 #endif // SYMBIAN_CAF_V2
   134 #endif // SYMBIAN_CAF_V2
   229 
   135 
   230 #endif // __MMF_DURATION_INFO_CUSTOM_COMMANDS_H__
   136 #endif // __MMF_DURATION_INFO_CUSTOM_COMMANDS_H__
       
   137