2 * Copyright (c) 2006-2009 Nokia Corporation and/or its subsidiary(-ies).
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".
9 * Initial Contributors:
10 * Nokia Corporation - initial contribution.
20 #ifndef FINDITEMENGINE_H
21 #define FINDITEMENGINE_H
24 #include <tuladdressstringtokenizer.h>
26 class CFindItemEngine : public CBase
29 @see CTulAddressStringTokenizer
30 @note For compatibility with S60 only
34 enum TFindItemSearchCase
36 EFindItemSearchPhoneNumberBin = CTulAddressStringTokenizer::EFindItemSearchPhoneNumberBin,
37 EFindItemSearchMailAddressBin = CTulAddressStringTokenizer::EFindItemSearchMailAddressBin,
38 EFindItemSearchURLBin = CTulAddressStringTokenizer::EFindItemSearchURLBin,
39 EFindItemSearchScheme = CTulAddressStringTokenizer::EFindItemSearchScheme
42 // Struct to contain a found item.
47 TFindItemSearchCase iItemType;
50 IMPORT_C static CFindItemEngine* NewL( const TDesC& aText, CFindItemEngine::TFindItemSearchCase aSearchCase );
51 IMPORT_C static CFindItemEngine* NewL( const TDesC& aText, CFindItemEngine::TFindItemSearchCase aSearchCase, TInt aMinNumbers );
52 IMPORT_C ~CFindItemEngine();
53 IMPORT_C TBool Item( CFindItemEngine::SFoundItem& aItem );
54 IMPORT_C TBool NextItem( CFindItemEngine::SFoundItem& aItem );
55 IMPORT_C TBool PrevItem( CFindItemEngine::SFoundItem& aItem );
56 IMPORT_C const CArrayFixFlat<CFindItemEngine::SFoundItem>* ItemArray() const;
57 IMPORT_C TInt Position() const;
58 IMPORT_C void ResetPosition();
59 IMPORT_C TInt ItemCount() const;
60 IMPORT_C TInt DoNewSearchL( const TDesC& aText, CFindItemEngine::TFindItemSearchCase aSearchCase);
61 IMPORT_C TInt DoNewSearchL( const TDesC& aText, CFindItemEngine::TFindItemSearchCase aSearchCase, TInt aMinNumbers );
66 #endif // FINDITEMENGINE_H