|
1 /* |
|
2 * Copyright (c) 2006-2007 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: ECom search interface definition |
|
15 * |
|
16 */ |
|
17 |
|
18 |
|
19 |
|
20 |
|
21 #ifndef C_CNOTESSEARCHPLUGIN_H |
|
22 #define C_CNOTESSEARCHPLUGIN_H |
|
23 |
|
24 //SYSTEM INCLUDES |
|
25 #include <searchplugin.h> |
|
26 |
|
27 |
|
28 |
|
29 //Forwared declarations |
|
30 class MSearchContentSearcher; |
|
31 class CNotesSearcher; |
|
32 |
|
33 /** |
|
34 * This class is the plugin interface class for the notes pluging |
|
35 * |
|
36 * This class searches the phonebook notes |
|
37 * |
|
38 * @lib notessearchplugin.lib |
|
39 */ |
|
40 class CNotesSearchPlugin : public CSearchPlugin |
|
41 { |
|
42 |
|
43 public: |
|
44 /** |
|
45 * |
|
46 * First phase construction |
|
47 * |
|
48 * |
|
49 * @return constructed CNotesSearchPlugin object. |
|
50 */ |
|
51 static CNotesSearchPlugin* NewL(); |
|
52 |
|
53 /** |
|
54 * |
|
55 * First phase construction |
|
56 * returned value is also kept on the CleanupStack. |
|
57 * |
|
58 * |
|
59 * @return constructed CNotesSearchPlugin object. |
|
60 */ |
|
61 static CNotesSearchPlugin* NewLC(); |
|
62 |
|
63 /** |
|
64 * Destructor. |
|
65 */ |
|
66 virtual ~CNotesSearchPlugin(); |
|
67 |
|
68 |
|
69 public: // from the base class CSearchPlugin |
|
70 |
|
71 /** |
|
72 * From CSearchPlugin |
|
73 * Returns the supported content of this plugin. |
|
74 * |
|
75 * @param aContent The content that this plugin can search. |
|
76 */ |
|
77 void GetSupportedContentL( RPointerArray<CSearchContent>& aContent ); |
|
78 |
|
79 /** |
|
80 * Indicates if this plugin supports the searching of the given content. |
|
81 * |
|
82 * @param aContentId Id of the search content. Can be either class or a folder. |
|
83 * @return ETrue if search is supported, EFalse otherwise. |
|
84 */ |
|
85 TBool IsSupportedContent( TUid aContentId ); |
|
86 |
|
87 |
|
88 /** |
|
89 * Get a content searcher. |
|
90 * |
|
91 * @param aContentIdArray Content to be searched for. |
|
92 * @param aCondition The conditions that must be fullfilled. |
|
93 * @param aRealm The realm where the search should be limited to. |
|
94 * @return Pointer to the content searcher. |
|
95 */ |
|
96 MSearchContentSearcher* ContentSearcherL( const RArray<TUid>& aContentIdArray, |
|
97 const CSearchCondition& aCondition, |
|
98 MSearchPluginObserver& aObserver ); |
|
99 /** |
|
100 * Launches a viewer/editor application for the given document id. |
|
101 * |
|
102 * @param aDocumentId Id of the document. |
|
103 */ |
|
104 void LaunchApplicationL( const TDesC8& aLaunchInfo ); |
|
105 |
|
106 |
|
107 private: |
|
108 /** |
|
109 * Second phase construction |
|
110 */ |
|
111 void ConstructL(); |
|
112 |
|
113 /** |
|
114 * Constructor. |
|
115 */ |
|
116 CNotesSearchPlugin(); |
|
117 |
|
118 private: // data members |
|
119 |
|
120 /** |
|
121 * The content searcher |
|
122 * Not Own |
|
123 */ |
|
124 MSearchContentSearcher* iContentSearcher; |
|
125 |
|
126 /** |
|
127 * The content searcher |
|
128 * Not Own |
|
129 */ |
|
130 CNotesSearcher* iNotesSearcher; |
|
131 }; |
|
132 |
|
133 #endif //C_CNOTESSEARCHPLUGIN_H |
|
134 |