24
|
1 |
/**
|
|
2 |
* Copyright (c) 2010 Nokia Corporation and/or its subsidiary(-ies).
|
|
3 |
* All rights reserved.
|
|
4 |
* This component and the accompanying materials are made available
|
|
5 |
* under the terms of "Eclipse Public License v1.0"
|
|
6 |
* which accompanies this distribution, and is available
|
|
7 |
* at the URL "http://www.eclipse.org/legal/epl-v10.html".
|
|
8 |
*
|
|
9 |
* Initial Contributors:
|
|
10 |
* Nokia Corporation - initial contribution.
|
|
11 |
*
|
|
12 |
* Contributors:
|
|
13 |
*
|
|
14 |
* Description: CUpnpTmInfoElement class declaration
|
|
15 |
*
|
|
16 |
*/
|
|
17 |
|
|
18 |
#ifndef __UPNPTMINFOELEMENT_H__
|
|
19 |
#define __UPNPTMINFOELEMENT_H__
|
|
20 |
|
|
21 |
#include <e32base.h>
|
|
22 |
#include <badesca.h>
|
|
23 |
|
|
24 |
//Literals
|
|
25 |
_LIT8(KRemotingInfo, "remotingInfo" );
|
|
26 |
_LIT8(KAppInfo, "appInfo" );
|
|
27 |
_LIT8(KDisplayInfo, "displayInfo" );
|
|
28 |
_LIT8(KAudioInfo, "audioInfo" );
|
|
29 |
|
|
30 |
/**
|
|
31 |
* Class represents the list of key-value pairs for each terminal mode info type.
|
|
32 |
* Used by the AutomotiveServer to provide name-value pairs for the associated application
|
|
33 |
*/
|
|
34 |
class CUpnpTmInfoElement : public CBase
|
|
35 |
{
|
|
36 |
public:
|
|
37 |
enum TTerminalModeInfoType
|
|
38 |
{
|
|
39 |
ERemotingInfo,
|
|
40 |
EAppInfo,
|
|
41 |
EDisplayInfo,
|
|
42 |
EAudioInfo
|
|
43 |
};
|
|
44 |
/**
|
|
45 |
* Standard Symbian Two-phased constructor.
|
|
46 |
*/
|
|
47 |
static CUpnpTmInfoElement* NewL( TTerminalModeInfoType aTerminalModeInfoType );
|
|
48 |
// Destructor
|
|
49 |
~CUpnpTmInfoElement();
|
|
50 |
/**
|
|
51 |
* Method is used to set terminal mode info key-value pair
|
|
52 |
*/
|
|
53 |
IMPORT_C void AddTmInfoElementL( const TDesC8& aName,const TDesC8& aValue );
|
|
54 |
// Unexported getter method
|
|
55 |
void GetTmInfoElementL( RBuf8& aInfoElementName,
|
|
56 |
RBuf8& aInfoElementValue, TInt aIndex )const;
|
|
57 |
// inlined getter methods
|
|
58 |
inline const TDesC8& TerminalModeInfoType( )const;
|
|
59 |
inline TInt TmInfoElementCount()const;
|
|
60 |
|
|
61 |
private:
|
|
62 |
CUpnpTmInfoElement();
|
|
63 |
void ConstructL( TTerminalModeInfoType aTerminalModeInfoType );
|
|
64 |
|
|
65 |
private:
|
|
66 |
HBufC8* iInfoTypeBuffer;
|
|
67 |
RArray<RBuf8> iInfoElementNameArray;
|
|
68 |
RArray<RBuf8> iInfoElementValueArray;
|
|
69 |
RBuf8 iElementName;
|
|
70 |
RBuf8 iElementValue;
|
|
71 |
};
|
|
72 |
|
|
73 |
#include <upnptminfoelement.inl>
|
|
74 |
|
|
75 |
#endif //__UPNPTMINFOELEMENT_H__
|