organizer_plat/searchfw_launcher_api/inc/searchcontentsearcher.h
changeset 0 f979ecb2b13e
equal deleted inserted replaced
-1:000000000000 0:f979ecb2b13e
       
     1 /*
       
     2 * Copyright (c) 2006-2006 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 #ifndef SEARCHCONTENTSEARCHER_H
       
    20 #define SEARCHCONTENTSEARCHER_H
       
    21 
       
    22 //  INCLUDES
       
    23 #include <e32std.h>
       
    24 # include <searchtextsearcherobserver.h>
       
    25 
       
    26 // FORWARD DECLARATIONS
       
    27 class MSearchPluginObserver;
       
    28 class CSearchResult;
       
    29 class CSearchDocumentId;
       
    30 
       
    31 /**
       
    32 * Parameters for search.
       
    33 * This class is used for content searcher
       
    34 *
       
    35 */
       
    36 class MSearchContentSearcher : public MSearchTextSearcherObserver
       
    37     {
       
    38 public:
       
    39     
       
    40     /**
       
    41     * Releses the object.
       
    42     */
       
    43     virtual void Destroy() = 0;
       
    44     
       
    45     /**
       
    46     * Starts the search. Progress of the search is notified through aObserver. Notice that
       
    47     * this call must be asynchronous.
       
    48     * @param aObserver Observer for search progress.
       
    49     */
       
    50     virtual void SearchL( ) = 0;
       
    51     
       
    52     /**
       
    53     * Function returning ETrue when a search is ongoing.  EFalse otherwise.
       
    54     * 
       
    55     * @return ETrue when a search is ongoing.  EFalse otherwise.
       
    56     */
       
    57     //virtual TBool IsSearching() = 0;
       
    58     
       
    59     /**
       
    60     * Cancels the ongoing search. This call must complete synchronously and no calls for
       
    61     * observers must be made after this call.
       
    62     *
       
    63     */
       
    64     virtual void CancelSearch() = 0;
       
    65     
       
    66     /**
       
    67     * Gets the results indicated by the given document ids. Asynchronous. Results will be given
       
    68     * through callback in MSearchPlugInObserver given in Search request.
       
    69     * @param aResults Results of the search process. Ownership transfers to caller.
       
    70     */
       
    71     virtual void GetResultsL( const RPointerArray<CSearchDocumentId>& aDocumentIdArray ) = 0;
       
    72 
       
    73     /**
       
    74     * Cancels the result retrieval process.
       
    75     */
       
    76     virtual void CancelResultsRetrieve() = 0;
       
    77 
       
    78     /**
       
    79     * Gets the current search progress. 
       
    80     *
       
    81     * @param aContentClassId On return contains the content class id, which is currently searched.
       
    82     * @param aCurrentDocument On return contains the index document that is currently being searched.
       
    83     * @param aTotalDocuments On return contains the total count of documents to be searched.
       
    84     */         
       
    85     //virtual void GetSearchProgressL( TUid& aContentClassId, TInt& aCurrentDocument, TInt& aTotalDocuments ) = 0;
       
    86 
       
    87 		virtual HBufC8* LaunchInfoL( const CSearchDocumentId& aID ) = 0;
       
    88     /**
       
    89     * Returns the extension for this interface. If no extension is available, return NULL.
       
    90     *
       
    91     * @param aExtensionUid Uid of the extension.
       
    92     */ 
       
    93     virtual TAny* ContentSearcherExtensionL( TUid /*aExtensionUid*/ ) { return NULL; }
       
    94     
       
    95     
       
    96     };
       
    97 
       
    98 #endif		// SEARCHCONTENTSEARCHER_H
       
    99 
       
   100 // End of File
       
   101