searchengine/cpix/tsrc/cpixunittest/inc/suggestion.h
changeset 0 671dee74050a
child 14 8bd192d47aaa
equal deleted inserted replaced
-1:000000000000 0:671dee74050a
       
     1 /*
       
     2 * Copyright (c) 2010 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: 
       
    15 *
       
    16 */
       
    17 
       
    18 #ifndef SUGGESTION_H_
       
    19 #define SUGGESTION_H_
       
    20 
       
    21 #include <string>
       
    22 
       
    23 #include "itk.h"
       
    24 #include "cpixdoc.h"
       
    25 
       
    26 
       
    27 class Suggestion
       
    28 {
       
    29 private:
       
    30     std::wstring  term_;
       
    31     std::wstring  frequency_;
       
    32 
       
    33     friend bool operator<(const Suggestion & left,
       
    34                           const Suggestion & right);
       
    35 
       
    36 public:
       
    37     Suggestion(cpix_Document & doc,
       
    38                Itk::TestMgr  * testMgr);
       
    39 
       
    40         
       
    41     const std::wstring & term() const;
       
    42     const std::wstring & frequency() const;
       
    43 
       
    44 
       
    45     static void printSuggestions(cpix_Hits    * hits,
       
    46                                  Itk::TestMgr * testMgr);
       
    47     
       
    48 };
       
    49 
       
    50 
       
    51 bool operator<(const Suggestion & left,
       
    52                const Suggestion & right);
       
    53 
       
    54 
       
    55 #endif