sl@0
|
1 |
// Copyright (c) 2002-2009 Nokia Corporation and/or its subsidiary(-ies).
|
sl@0
|
2 |
// All rights reserved.
|
sl@0
|
3 |
// This component and the accompanying materials are made available
|
sl@0
|
4 |
// under the terms of "Eclipse Public License v1.0"
|
sl@0
|
5 |
// which accompanies this distribution, and is available
|
sl@0
|
6 |
// at the URL "http://www.eclipse.org/legal/epl-v10.html".
|
sl@0
|
7 |
//
|
sl@0
|
8 |
// Initial Contributors:
|
sl@0
|
9 |
// Nokia Corporation - initial contribution.
|
sl@0
|
10 |
//
|
sl@0
|
11 |
// Contributors:
|
sl@0
|
12 |
//
|
sl@0
|
13 |
// Description:
|
sl@0
|
14 |
//
|
sl@0
|
15 |
|
sl@0
|
16 |
|
sl@0
|
17 |
#ifndef __MMFCUSTOMCOMMANDPARSERMANAGER_H__
|
sl@0
|
18 |
#define __MMFCUSTOMCOMMANDPARSERMANAGER_H__
|
sl@0
|
19 |
|
sl@0
|
20 |
/**
|
sl@0
|
21 |
@publishedPartner
|
sl@0
|
22 |
@released
|
sl@0
|
23 |
|
sl@0
|
24 |
Class to manage custom command parsers.
|
sl@0
|
25 |
|
sl@0
|
26 |
An object of this type is owned by the controller framework to contain all the custom command
|
sl@0
|
27 |
parsers for the controller plugin.
|
sl@0
|
28 |
|
sl@0
|
29 |
@since 7.0s
|
sl@0
|
30 |
*/
|
sl@0
|
31 |
class CMMFCustomCommandParserManager : public CBase
|
sl@0
|
32 |
{
|
sl@0
|
33 |
public:
|
sl@0
|
34 |
/**
|
sl@0
|
35 |
Factory constructor.
|
sl@0
|
36 |
|
sl@0
|
37 |
@return A pointer to the newly created object.
|
sl@0
|
38 |
|
sl@0
|
39 |
@since 7.0s
|
sl@0
|
40 |
*/
|
sl@0
|
41 |
IMPORT_C static CMMFCustomCommandParserManager* NewL();
|
sl@0
|
42 |
|
sl@0
|
43 |
/**
|
sl@0
|
44 |
Destructor.
|
sl@0
|
45 |
|
sl@0
|
46 |
Deletes all custom command parsers added to the manager.
|
sl@0
|
47 |
|
sl@0
|
48 |
@since 7.0s
|
sl@0
|
49 |
*/
|
sl@0
|
50 |
IMPORT_C ~CMMFCustomCommandParserManager();
|
sl@0
|
51 |
|
sl@0
|
52 |
/**
|
sl@0
|
53 |
Attempts to find a custom command parser capable of handling the message.
|
sl@0
|
54 |
|
sl@0
|
55 |
@param aMessage
|
sl@0
|
56 |
The message to be handled.
|
sl@0
|
57 |
|
sl@0
|
58 |
@return A boolean indicating in the message has been handled. ETrue if the message has been handled, EFalse
|
sl@0
|
59 |
if it has not.
|
sl@0
|
60 |
|
sl@0
|
61 |
@since 7.0s
|
sl@0
|
62 |
*/
|
sl@0
|
63 |
IMPORT_C TBool HandleRequest(TMMFMessage& aMessage);
|
sl@0
|
64 |
|
sl@0
|
65 |
/**
|
sl@0
|
66 |
Adds a custom command parser to the manager. The manager takes ownership of the parser.
|
sl@0
|
67 |
|
sl@0
|
68 |
Note:
|
sl@0
|
69 |
This method will leave if it fails to add the parser. If it does leave, ownership
|
sl@0
|
70 |
of the parser will remain with the caller.
|
sl@0
|
71 |
|
sl@0
|
72 |
@param aParser
|
sl@0
|
73 |
A reference to the parser to be added to the manager.
|
sl@0
|
74 |
|
sl@0
|
75 |
@since 7.0s
|
sl@0
|
76 |
*/
|
sl@0
|
77 |
IMPORT_C void AddCustomCommandParserL(CMMFCustomCommandParserBase& aParser);
|
sl@0
|
78 |
private:
|
sl@0
|
79 |
CMMFCustomCommandParserManager();
|
sl@0
|
80 |
private:
|
sl@0
|
81 |
/**
|
sl@0
|
82 |
The array of custom command parsers.
|
sl@0
|
83 |
*/
|
sl@0
|
84 |
RPointerArray<CMMFCustomCommandParserBase> iParsers;
|
sl@0
|
85 |
};
|
sl@0
|
86 |
|
sl@0
|
87 |
#endif __MMFCUSTOMCOMMANDPARSERMANAGER_H__
|