|
1 /** |
|
2 * Copyright (c) 2004-2009 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: |
|
15 * |
|
16 */ |
|
17 |
|
18 |
|
19 |
|
20 /** |
|
21 @file |
|
22 @internalComponent |
|
23 @released |
|
24 */ |
|
25 |
|
26 |
|
27 #ifndef __PLPLUGINS_H__ |
|
28 #define __PLPLUGINS_H__ |
|
29 |
|
30 #include "persistencelayer.h" |
|
31 |
|
32 //Forward declarations |
|
33 class CContactPhoneNumberParser; |
|
34 |
|
35 /** |
|
36 Base class for Contacts Model plugins. |
|
37 */ |
|
38 class NONSHARED CContactPlugin : public CBase |
|
39 { |
|
40 public: |
|
41 ~CContactPlugin(); |
|
42 |
|
43 protected: |
|
44 virtual void SetPluginL(TLibraryFunction aGateFunction) = 0; |
|
45 TUid LoadEComPluginFromInterface(TUid aInterfaceUid); |
|
46 CContactPlugin(); |
|
47 |
|
48 private: |
|
49 RLibrary iDll; |
|
50 }; |
|
51 |
|
52 |
|
53 /** |
|
54 Contact phone number parser plugin. |
|
55 */ |
|
56 class NONSHARED CContactPhoneParser : public CContactPlugin |
|
57 { |
|
58 public: |
|
59 static CContactPhoneParser* NewL(); |
|
60 ~CContactPhoneParser(); |
|
61 |
|
62 inline CContactPhoneNumberParser* Parser() const; |
|
63 |
|
64 // From CContactPlugin. |
|
65 virtual void SetPluginL(TLibraryFunction aGateFunction); |
|
66 |
|
67 private: |
|
68 void LoadEComPluginL(); |
|
69 |
|
70 private: |
|
71 CContactPhoneNumberParser* iParser; |
|
72 }; |
|
73 |
|
74 |
|
75 inline CContactPhoneNumberParser* CContactPhoneParser::Parser() const |
|
76 { return iParser; } |
|
77 |
|
78 |
|
79 #endif // __PLPLUGINS_H__ |