|
1 /* |
|
2 * Copyright (c) 2002 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: See class description below. |
|
15 * |
|
16 */ |
|
17 |
|
18 |
|
19 #ifndef __CPENGPLUGINHOLDER_H__ |
|
20 #define __CPENGPLUGINHOLDER_H__ |
|
21 |
|
22 // INCLUDES |
|
23 #include <e32def.h> |
|
24 |
|
25 class CPEngPluginInterface2; |
|
26 |
|
27 // CLASS DEFINITION |
|
28 /** |
|
29 * |
|
30 * |
|
31 * |
|
32 * |
|
33 * @lib |
|
34 * @since 3.0 |
|
35 */ |
|
36 class CPEngPluginHolder : public CBase |
|
37 { |
|
38 public: // Constructors and destructors |
|
39 |
|
40 static CPEngPluginHolder* NewL(); // Static constructor |
|
41 static CPEngPluginHolder* NewLC(); // Static constructor |
|
42 virtual ~CPEngPluginHolder(); // Destructor (virtual) |
|
43 |
|
44 public: // New methods |
|
45 |
|
46 /** |
|
47 * Returns the uid of the held plugin. |
|
48 * |
|
49 * @since 3.0 |
|
50 * @return The uid |
|
51 */ |
|
52 TUid Uid() const; |
|
53 |
|
54 /** |
|
55 * Check if the plugin is currently loaded. |
|
56 * |
|
57 * @since 3.0 |
|
58 * @return ETrue if the plugin is loaded. |
|
59 */ |
|
60 TBool Loaded() const; |
|
61 |
|
62 void LoadPluginL( TUid aPluginUid ); |
|
63 |
|
64 const CPEngPluginInterface2* Interface() const; |
|
65 |
|
66 protected: // Constructors and destructors |
|
67 |
|
68 CPEngPluginHolder();// Default constructor, protected to allow derivation |
|
69 void ConstructL(); // Second phase construct |
|
70 |
|
71 private: // Data |
|
72 |
|
73 //Filename of the plugin |
|
74 TUid iUid; |
|
75 |
|
76 //Pointer to plugin's interface, OWNED |
|
77 CPEngPluginInterface2* iPlugin; |
|
78 |
|
79 }; |
|
80 |
|
81 #endif // __CPENGPLUGINHOLDER_H__ |