sl@0
|
1 |
// Copyright (c) 2005-2009 Nokia Corporation and/or its subsidiary(-ies).
|
sl@0
|
2 |
// All rights reserved.
|
sl@0
|
3 |
// This component and the accompanying materials are made available
|
sl@0
|
4 |
// under the terms of "Eclipse Public License v1.0"
|
sl@0
|
5 |
// which accompanies this distribution, and is available
|
sl@0
|
6 |
// at the URL "http://www.eclipse.org/legal/epl-v10.html".
|
sl@0
|
7 |
//
|
sl@0
|
8 |
// Initial Contributors:
|
sl@0
|
9 |
// Nokia Corporation - initial contribution.
|
sl@0
|
10 |
//
|
sl@0
|
11 |
// Contributors:
|
sl@0
|
12 |
//
|
sl@0
|
13 |
// Description:
|
sl@0
|
14 |
//
|
sl@0
|
15 |
|
sl@0
|
16 |
#ifndef ECOM_DEBUG_H
|
sl@0
|
17 |
#define ECOM_DEBUG_H
|
sl@0
|
18 |
|
sl@0
|
19 |
#include <e32debug.h>
|
sl@0
|
20 |
#include <ecom/ecompanics.h>
|
sl@0
|
21 |
|
sl@0
|
22 |
// Make sure release builds get a warning if
|
sl@0
|
23 |
#ifndef _DEBUG
|
sl@0
|
24 |
#if (defined ECOM_TRACE)
|
sl@0
|
25 |
#warning "Use of RDebug::Print tracing in a release build, check MMP files"
|
sl@0
|
26 |
#endif
|
sl@0
|
27 |
#endif
|
sl@0
|
28 |
|
sl@0
|
29 |
// Panic category string for client DLL panics, see ecompanic.h
|
sl@0
|
30 |
_LIT(KEComClientDLLPanicCategory, "ECOMClientDLL");
|
sl@0
|
31 |
|
sl@0
|
32 |
// Panic category string for server panics, see ecompanic.h
|
sl@0
|
33 |
_LIT(KEComServerPanicCategory, "ECOMServer");
|
sl@0
|
34 |
|
sl@0
|
35 |
//
|
sl@0
|
36 |
// MACROs for log statements in client/server code.
|
sl@0
|
37 |
//
|
sl@0
|
38 |
|
sl@0
|
39 |
#define __ECOM_LOG(_text) RDebug::Print(_L(_text))
|
sl@0
|
40 |
#define __ECOM_LOG1(_text, _a1) RDebug::Print(_L(_text), (_a1))
|
sl@0
|
41 |
|
sl@0
|
42 |
//
|
sl@0
|
43 |
// MACROs for trace statements in client/server code.
|
sl@0
|
44 |
//
|
sl@0
|
45 |
|
sl@0
|
46 |
#ifdef ECOM_TRACE
|
sl@0
|
47 |
|
sl@0
|
48 |
#define __ECOM_TRACE(_text) RDebug::Print(_L(_text))
|
sl@0
|
49 |
#define __ECOM_TRACE1(_text, _a1) RDebug::Print(_L(_text), (_a1))
|
sl@0
|
50 |
#define __ECOM_TRACE2(_text, _a1, _a2) RDebug::Print(_L(_text), (_a1), (_a2))
|
sl@0
|
51 |
#define __ECOM_TRACE3(_text, _a1, _a2, _a3) RDebug::Print(_L(_text), (_a1), (_a2), (_a3))
|
sl@0
|
52 |
#define __ECOM_TRACE4(_text, _a1, _a2, _a3, _a4) RDebug::Print(_L(_text), (_a1), (_a2), (_a3), (_a4))
|
sl@0
|
53 |
#define __ECOM_TRACE5(_text, _a1, _a2, _a3, _a4, _a5) RDebug::Print(_L(_text), (_a1), (_a2), (_a3), (_a4), (_a5))
|
sl@0
|
54 |
#define __ECOM_TRACE6(_text, _a1, _a2, _a3, _a4, _a5, _a6) RDebug::Print(_L(_text), (_a1), (_a2), (_a3), (_a4), (_a5), (_a6))
|
sl@0
|
55 |
|
sl@0
|
56 |
#else
|
sl@0
|
57 |
|
sl@0
|
58 |
#define __ECOM_TRACE(_text)
|
sl@0
|
59 |
#define __ECOM_TRACE1(_text, _a1)
|
sl@0
|
60 |
#define __ECOM_TRACE2(_text, _a1, _a2)
|
sl@0
|
61 |
#define __ECOM_TRACE3(_text, _a1, _a2, _a3)
|
sl@0
|
62 |
#define __ECOM_TRACE4(_text, _a1, _a2, _a3, _a4)
|
sl@0
|
63 |
#define __ECOM_TRACE5(_text, _a1, _a2, _a3, _a4, _a5)
|
sl@0
|
64 |
#define __ECOM_TRACE6(_text, _a1, _a2, _a3, _a4, _a5, _a6)
|
sl@0
|
65 |
|
sl@0
|
66 |
#endif
|
sl@0
|
67 |
|
sl@0
|
68 |
|
sl@0
|
69 |
|
sl@0
|
70 |
|
sl@0
|
71 |
#endif // ECOM_DEBUG_H
|
sl@0
|
72 |
|