2 * Copyright (c) 2005-2006 Nokia Corporation and/or its subsidiary(-ies).
4 * This component and the accompanying materials are made available
5 * under the terms of the License "Symbian Foundation License v1.0" to Symbian Foundation members and "Symbian Foundation End User License Agreement v1.0" to non-members
6 * which accompanies this distribution, and is available
7 * at the URL "http://www.symbianfoundation.org/legal/licencesv10.html".
9 * Initial Contributors:
10 * Nokia Corporation - initial contribution.
14 * Description: CPosLmCatNameCriteria class
19 #ifndef CPOSLMCATNAMECRITERIA_H
20 #define CPOSLMCATNAMECRITERIA_H
23 #include "EPos_CPosLmSearchCriteria.h"
26 * Criterion for searching landmark categories with a certain name.
28 * Wild-card characters are supported.
30 * The client specifies the search pattern and starts the search using
31 * @ref CPosLandmarkSearch. The search returns all categories which
32 * match the search pattern.
34 * This criterion is only valid when searching for landmark categories, i.e. if
35 * it is passed to @p CPosLandmarkSearch::StartLandmarkSearchL, the function
36 * will fail with error code @p KErrArgument.
38 * @lib eposlmsearchlib.lib
41 class CPosLmCatNameCriteria : public CPosLmSearchCriteria
46 * Two-phased constructor.
47 * @returns A new instance of this class.
49 IMPORT_C static CPosLmCatNameCriteria* NewLC();
54 virtual ~CPosLmCatNameCriteria();
59 * Retrieves the search pattern.
61 * @return The category name search pattern.
63 IMPORT_C TPtrC SearchPattern() const;
66 * Sets the search pattern.
68 * A non-empty search pattern must be set, otherwise
69 * @ref CPosLandmarkSearch::StartCategorySearchL will leave with error
70 * code @p KErrArgument.
72 * The search is case insensitive.
74 * Wild-card characters "?" and "*" are supported in the search string.
75 * "?" matches a single occurrence of any character and "*" matches
76 * zero or more consecutive occurrences of any characters.
78 * @param[in] aSearchPattern The pattern used to find categories.
80 * @leave KErrArgument The search pattern is longer than
81 * @p KPosLmMaxCategoryNameLength.
83 IMPORT_C void SetSearchPatternL( const TDesC& aSearchPattern );
87 CPosLmCatNameCriteria();
91 // Prohibit copy constructor
92 CPosLmCatNameCriteria( const CPosLmCatNameCriteria& );
93 // Prohibit assigment operator
94 CPosLmCatNameCriteria& operator= ( const CPosLmCatNameCriteria& );
98 HBufC* iSearchPattern;
102 #endif // CPOSLMCATNAMECRITERIA_H