epoc32/include/mw/epos_cposlmcatnamecriteria.h
author William Roberts <williamr@symbian.org>
Tue, 16 Mar 2010 16:12:26 +0000
branchSymbian2
changeset 2 2fe1408b6811
parent 1 666f914201fb
child 4 837f303aceeb
permissions -rw-r--r--
Final list of Symbian^2 public API header files
     1 /*
     2 * Copyright (c) 2005-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 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".
     8 *
     9 * Initial Contributors:
    10 * Nokia Corporation - initial contribution.
    11 *
    12 * Contributors:
    13 *
    14 * Description:  CPosLmCatNameCriteria class
    15 *
    16 */
    17 
    18 
    19 #ifndef CPOSLMCATNAMECRITERIA_H
    20 #define CPOSLMCATNAMECRITERIA_H
    21 
    22 #include <e32base.h>
    23 #include "EPos_CPosLmSearchCriteria.h"
    24 
    25 /**
    26 *  Criterion for searching landmark categories with a certain name.
    27 *
    28 *  Wild-card characters are supported.
    29 *
    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.
    33 *
    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.
    37 *
    38 *  @lib eposlmsearchlib.lib
    39 *  @since S60 3.0
    40 */
    41 class CPosLmCatNameCriteria : public CPosLmSearchCriteria
    42     {
    43     public:
    44 
    45         /**
    46         * Two-phased constructor.
    47         * @returns A new instance of this class.
    48         */
    49         IMPORT_C static CPosLmCatNameCriteria* NewLC();
    50 
    51         /**
    52         * Destructor.
    53         */
    54         virtual ~CPosLmCatNameCriteria();
    55 
    56     public:
    57 
    58         /**
    59         * Retrieves the search pattern.
    60         *
    61         * @return The category name search pattern.
    62         */
    63         IMPORT_C TPtrC SearchPattern() const;
    64 
    65         /**
    66         * Sets the search pattern.
    67         *
    68         * A non-empty search pattern must be set, otherwise
    69         * @ref CPosLandmarkSearch::StartCategorySearchL will leave with error
    70         * code @p KErrArgument.
    71         *
    72         * The search is case insensitive.
    73         *
    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.
    77         *
    78         * @param[in] aSearchPattern The pattern used to find categories.
    79         *
    80         * @leave KErrArgument The search pattern is longer than 
    81         *   @p KPosLmMaxCategoryNameLength.
    82         */
    83         IMPORT_C void SetSearchPatternL( const TDesC& aSearchPattern );
    84 
    85     private:
    86 
    87         CPosLmCatNameCriteria();
    88 
    89         void ConstructL();
    90 
    91         // Prohibit copy constructor
    92         CPosLmCatNameCriteria( const CPosLmCatNameCriteria& );
    93         // Prohibit assigment operator
    94         CPosLmCatNameCriteria& operator= ( const CPosLmCatNameCriteria& );
    95 
    96     private:
    97 
    98         HBufC* iSearchPattern;
    99 
   100     };
   101 
   102 #endif      // CPOSLMCATNAMECRITERIA_H
   103 
   104