114
|
1 |
/*
|
|
2 |
* Copyright (c) 2008 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: Used by sessions for handling execute action requests
|
|
15 |
*
|
|
16 |
*/
|
|
17 |
|
|
18 |
|
|
19 |
#ifndef C_CPACTION_MANAGER_H
|
|
20 |
#define C_CPACTION_MANAGER_H
|
|
21 |
|
|
22 |
#include <e32base.h>
|
|
23 |
// FORWARD DECLARATIONS
|
|
24 |
#ifdef CONTENT_PUBLISHER_DEBUG
|
|
25 |
class CCPDebug;
|
|
26 |
#endif
|
|
27 |
class CLiwServiceHandler;
|
|
28 |
class MLiwInterface;
|
|
29 |
class CLiwMap;
|
|
30 |
|
|
31 |
/**
|
|
32 |
* Used to execute action using Action Handler Service
|
|
33 |
*
|
|
34 |
* @since S60 5.0
|
|
35 |
*/
|
|
36 |
class CCPActionManager : public CBase
|
|
37 |
{
|
|
38 |
public:
|
|
39 |
|
|
40 |
/**
|
|
41 |
* C++ destructor
|
|
42 |
*/
|
|
43 |
~CCPActionManager();
|
|
44 |
|
|
45 |
/**
|
|
46 |
* Two-phased constructor.
|
|
47 |
*/
|
|
48 |
static CCPActionManager* NewL();
|
|
49 |
|
|
50 |
/**
|
|
51 |
* Two-phased constructor.
|
|
52 |
*/
|
|
53 |
static CCPActionManager* NewLC();
|
|
54 |
|
|
55 |
/**
|
|
56 |
* Executes action
|
|
57 |
* @param Action to be executed
|
|
58 |
*/
|
|
59 |
void ExecuteL( const CLiwGenericParamList& aList );
|
|
60 |
|
|
61 |
private:
|
|
62 |
// methods
|
|
63 |
|
|
64 |
/**
|
|
65 |
* Standard C++ constructor.
|
|
66 |
*/
|
|
67 |
CCPActionManager();
|
|
68 |
|
|
69 |
/**
|
|
70 |
* Standard 2nd phase constructor.
|
|
71 |
*/
|
|
72 |
void ConstructL();
|
|
73 |
|
|
74 |
/**
|
|
75 |
* Loads interface
|
|
76 |
* @param interface loaded from service
|
|
77 |
*/
|
|
78 |
void PrepareServiceL( MLiwInterface*& aInterface );
|
|
79 |
|
|
80 |
/**
|
|
81 |
* Prepares data to execute command
|
|
82 |
* @param paramList from server
|
|
83 |
* @param target list to execute action
|
|
84 |
*/
|
|
85 |
void PrepareInputListL( const CLiwGenericParamList& aList,
|
|
86 |
CLiwGenericParamList& aTarget );
|
|
87 |
|
|
88 |
/**
|
|
89 |
* Extracts and adds attributes from aMap to aTarget.
|
|
90 |
* @since Series 60 3.2
|
|
91 |
* @param aMap CLiwMap with action.
|
|
92 |
* @param aTarget CLiwGenericParamList with Uid and Map.
|
|
93 |
*/
|
|
94 |
void ExtractUidAndMapL( const CLiwMap& aMap,
|
|
95 |
CLiwGenericParamList& aTarget );
|
|
96 |
|
|
97 |
private:
|
|
98 |
// data
|
|
99 |
|
|
100 |
/*
|
|
101 |
* Own.
|
|
102 |
* Handler to service
|
|
103 |
*/
|
|
104 |
CLiwServiceHandler* iServiceHandler;
|
|
105 |
|
|
106 |
/*
|
|
107 |
* Own.
|
|
108 |
* Interface to CPS service
|
|
109 |
*/
|
|
110 |
MLiwInterface* iInterface;
|
|
111 |
|
|
112 |
#ifdef CONTENT_PUBLISHER_DEBUG
|
|
113 |
CCPDebug* iDebug;
|
|
114 |
#endif
|
|
115 |
};
|
|
116 |
|
|
117 |
#endif // C_CPACTION_MANAGER_H
|
|
118 |
// end of file
|