|
1 /* |
|
2 * Copyright (c) 2009 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: Header Information for MTP Logger |
|
15 * |
|
16 */ |
|
17 |
|
18 |
|
19 #ifndef MMMTPDPLOGGER_H |
|
20 #define MMMTPDPLOGGER_H |
|
21 |
|
22 #include <e32debug.h> |
|
23 |
|
24 // --------------------------------------------------------------------------- |
|
25 #if !defined( PRINT3 ) |
|
26 #ifdef _DEBUG |
|
27 #define PRINT( txt ) RDebug::Print( txt ); |
|
28 #define PRINT1( txt, arg1 ) RDebug::Print( txt, arg1 ); |
|
29 #define PRINT2( txt, arg1, arg2 ) RDebug::Print( txt, arg1, arg2 ); |
|
30 #define PRINT3( txt, arg1, arg2, arg3 ) RDebug::Print( txt, arg1, arg2, arg3 ); |
|
31 #define PRINT4( txt, arg1, arg2, arg3, arg4 ) RDebug::Print( txt, arg1, arg2, arg3, arg4 ); |
|
32 |
|
33 // PRINT_FRQ macros are used for logging of frequently occurring events, |
|
34 // for example draws done every time a viewfinder frame arrives. |
|
35 // By default, logging these is disabled. |
|
36 #undef LOG_FREQUENT |
|
37 |
|
38 #ifdef LOG_FREQUENT |
|
39 #define PRINT_FRQ( txt ) RDebug::Print( txt ); |
|
40 #define PRINT_FRQ1( txt, arg1 ) RDebug::Print( txt, arg1 ); |
|
41 #define PRINT_FRQ2( txt, arg1, arg2 ) RDebug::Print( txt, arg1, arg2 ); |
|
42 #define PRINT_FRQ3( txt, arg1, arg2, arg3 ) RDebug::Print( txt, arg1, arg2, arg3 ); |
|
43 #define PRINT_FRQ4( txt, arg1, arg2, arg3, arg4 ) RDebug::Print( txt, arg1, arg2, arg3, arg4 ); |
|
44 #else |
|
45 #define PRINT_FRQ( txt ) |
|
46 #define PRINT_FRQ1( txt, arg1 ) |
|
47 #define PRINT_FRQ2( txt, arg1, arg2 ) |
|
48 #define PRINT_FRQ3( txt, arg1, arg2, arg3 ) |
|
49 #define PRINT_FRQ4( txt, arg1, arg2, arg3, arg4 ) |
|
50 #endif // LOG_FREQUENT |
|
51 |
|
52 #else |
|
53 #define PRINT( txt ) |
|
54 #define PRINT1( txt, arg1 ) |
|
55 #define PRINT2( txt, arg1, arg2 ) |
|
56 #define PRINT3( txt, arg1, arg2, arg3 ) |
|
57 #define PRINT4( txt, arg1, arg2, arg3, arg4 ) |
|
58 |
|
59 #define PRINT_FRQ( txt ) |
|
60 #define PRINT_FRQ1( txt, arg1 ) |
|
61 #define PRINT_FRQ2( txt, arg1, arg2 ) |
|
62 #define PRINT_FRQ3( txt, arg1, arg2, arg3 ) |
|
63 #define PRINT_FRQ4( txt, arg1, arg2, arg3, arg4 ) |
|
64 |
|
65 #endif |
|
66 #endif |
|
67 // --------------------------------------------------------------------------- |
|
68 #endif // MMMTPDPLOGGER_H |