os/mm/mmdevicefw/mdf/inc/codecapi/codecapiresolverdata.h
author sl
Tue, 10 Jun 2014 14:32:02 +0200
changeset 1 260cb5ec6c19
permissions -rw-r--r--
Update contrib.
     1 // Copyright (c) 2005-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 "Eclipse Public License v1.0"
     5 // which accompanies this distribution, and is available
     6 // at the URL "http://www.eclipse.org/legal/epl-v10.html".
     7 //
     8 // Initial Contributors:
     9 // Nokia Corporation - initial contribution.
    10 //
    11 // Contributors:
    12 //
    13 // Description:
    14 //
    15 
    16 /**
    17  @file
    18  @publishedPartner
    19  @released
    20 */
    21 
    22 #ifndef CODECAPIRESOLVERDATA_H
    23 #define CODECAPIRESOLVERDATA_H
    24 
    25 #include <e32std.h>
    26 
    27 /**
    28  Defines the type of matching that the resolver should perform 
    29 */
    30 enum TCodecApiResolverMatchType
    31 	{
    32 	/**
    33 	Resolver should match on input data format
    34 	 */
    35 	EMatchInputDataFormat,			
    36 	/**
    37 	Resolver should match on output data format
    38 	 */
    39 	EMatchOutputDataFormat,		
    40 	/**
    41 	Resolver should match on both input and output data format
    42 	 */
    43 	EMatchInputAndOutputDataFormat		
    44 	};
    45 
    46 /**
    47   Streaming class used to pass parameters from the Codec API to the resolver.
    48  */
    49 class CCodecApiResolverData : public CBase
    50 	{
    51 public:
    52 	IMPORT_C static CCodecApiResolverData* NewL();
    53 	IMPORT_C static CCodecApiResolverData* NewL(const TDesC8& aPackage);
    54 	IMPORT_C static CCodecApiResolverData* NewLC();
    55 	IMPORT_C static CCodecApiResolverData* NewLC(const TDesC8& aPackage);
    56 	IMPORT_C void SetMatchType(const TCodecApiResolverMatchType& aType);
    57 	IMPORT_C void SetImplementationType(const TUid& aImplementationType);
    58 	IMPORT_C void SetInputDataL(const TDesC8& aDataType);
    59 	IMPORT_C void SetOutputDataL(const TDesC8& aDataType);
    60 	IMPORT_C TCodecApiResolverMatchType MatchType() const;
    61 	IMPORT_C TUid ImplementationType() const;
    62 	IMPORT_C const TPtrC8 InputDataFormat() const;
    63 	IMPORT_C const TPtrC8 OutputDataFormat() const;
    64 	IMPORT_C HBufC8* NewPackLC() const;
    65 	IMPORT_C void UnPackL(const TDesC8& aPackage);
    66 	virtual ~CCodecApiResolverData();
    67 private:
    68 	void ConstructL(const TDesC8& aPackage);
    69 	void ExternalizeL(RWriteStream& aStream) const;
    70 	void InternalizeL(RReadStream& aStream);
    71 	CCodecApiResolverData();
    72 private:
    73 	TCodecApiResolverMatchType	iMatchType;
    74 	TUid 					iImplementationType;
    75 	HBufC8* 				iInputDataFormat;
    76 	HBufC8* 				iOutputDataFormat;
    77 	}; 
    78 
    79 #endif // CODECAPIRESOLVERDATA_H