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