phonebookengines/contactsmodel/cntplsql/inc/predictivesearchlog.h
changeset 46 efe85016a067
equal deleted inserted replaced
40:b46a585f6909 46:efe85016a067
       
     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: Macros for performing logging 
       
    15 */
       
    16 
       
    17 #ifndef __PREDICTIVESEARCHLOG_H__
       
    18 #define __PREDICTIVESEARCHLOG_H__
       
    19 
       
    20 
       
    21 // To avoid logging in debug builds, define NO_PRED_SEARCH_LOGS macro in the
       
    22 // file that includes this header file
       
    23 #if !defined(NO_PRED_SEARCH_LOGS) && defined(_DEBUG)
       
    24 #define WRITE_PRED_SEARCH_LOGS
       
    25 #endif
       
    26 
       
    27 
       
    28 #if defined(WRITE_PRED_SEARCH_LOGS)
       
    29 
       
    30 #include <e32debug.h> // RDebug
       
    31 
       
    32 #define PRINT(x)					RDebug::Print(x)
       
    33 #define PRINT1(x, y)				RDebug::Print(x, y)
       
    34 #define PRINT2(x, y, z)				RDebug::Print(x, y, z)
       
    35 #define PRINT3(w, x, y, z)			RDebug::Print(w, x, y, z)
       
    36 #define PRINT4(v, w, x, y, z)		RDebug::Print(v, w, x, y, z)
       
    37 #define PRINT5(u, v, w, x, y, z)	RDebug::Print(u, v, w, x, y, z)
       
    38 
       
    39 #else // #if defined(WRITE_PRED_SEARCH_LOGS)
       
    40 
       
    41 #define PRINT(x)
       
    42 #define PRINT1(x, y)
       
    43 #define PRINT2(x, y, z)
       
    44 #define PRINT3(w, x, y, z)
       
    45 #define PRINT4(v, w, x, y, z)
       
    46 #define PRINT5(u, v, w, x, y, z)
       
    47 
       
    48 #endif // #if defined(WRITE_PRED_SEARCH_LOGS)
       
    49 
       
    50 
       
    51 #endif // __PREDICTIVESEARCHLOG_H__
       
    52 
       
    53 // End of file