|
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: |
|
15 * |
|
16 */ |
|
17 |
|
18 #ifndef PTIKOREANQWERTYCOREDEBUG_H_ |
|
19 #define PTIKOREANQWERTYCOREDEBUG_H_ |
|
20 |
|
21 #ifdef _DEBUG |
|
22 #include <e32svr.h> |
|
23 #if __WINS__ |
|
24 #define LOG_ASSERT(a) RDebug::Print(_L("PKQC: "a)); __ASSERT_DEBUG(EFalse,User::Panic(_L("PKQC: Not Implemented"),__LINE__)) |
|
25 #define LOG(a) RDebug::Print(_L("PKQC: "a)) |
|
26 #define LOG1(a,b) RDebug::Print(_L("PKQC: "a),b) |
|
27 #define LOG2(a,b,c) RDebug::Print(_L("PKQC: "a),b,c) |
|
28 #define LOG3(a,b,c,d) RDebug::Print(_L("PKQC: "a),b,c,d) |
|
29 #define LOG4(a,b,c,d,e) RDebug::Print(_L("PKQC: "a),b,c,d,e) |
|
30 #else |
|
31 #include <flogger.h> |
|
32 _LIT(KLogFile,"PKQC.txt"); |
|
33 _LIT(KLogFolder,"PKQC"); |
|
34 #define LOG_ASSERT(a) RFileLogger::Write(KLogFolder(),KLogFile(),EFileLoggingModeAppend,_L(a)); __ASSERT_DEBUG(EFalse,User::Panic(_L("PKQC: Not Implemented"),__LINE__)) |
|
35 #define LOG(a) RFileLogger::Write(KLogFolder(),KLogFile(),EFileLoggingModeAppend,_L(a)) |
|
36 #define LOG1(a,b) RFileLogger::WriteFormat(KLogFolder(),KLogFile(),EFileLoggingModeAppend,TRefByValue<const TDesC>(_L(a)),b) |
|
37 #define LOG2(a,b,c) RFileLogger::WriteFormat(KLogFolder(),KLogFile(),EFileLoggingModeAppend,TRefByValue<const TDesC>(_S16(a)),b,c) |
|
38 #define LOG3(a,b,c,d) RFileLogger::WriteFormat(KLogFolder(),KLogFile(),EFileLoggingModeAppend,TRefByValue<const TDesC>(_L(a)),b,c,d) |
|
39 #define LOG4(a,b,c,d,e) RFileLogger::WriteFormat(KLogFolder(),KLogFile(),EFileLoggingModeAppend,TRefByValue<const TDesC>(_L(a)),b,c,d,e) |
|
40 #endif |
|
41 #else |
|
42 #define LOG_ASSERT(a) |
|
43 #define LOG(a) |
|
44 #define LOG1(a,b) |
|
45 #define LOG2(a,b,c) |
|
46 #define LOG3(a,b,c,d) |
|
47 #define LOG4(a,b,c,d,e) |
|
48 #endif |
|
49 |
|
50 #endif /* PTIKOREANQWERTYCOREDEBUG_H_ */ |