9519719c2fec22c2573e4bb3edfbd543238bd755
[platform/core/uifw/inputdelegator.git] / inc / Debug.h
1 /*
2  * Copyright (c) 2016 Samsung Electronics Co., Ltd All Rights Reserved
3  *
4  * Licensed under the Apache License, Version 2.0 (the License);
5  * you may not use this file except in compliance with the License.
6  * You may obtain a copy of the License at
7  *
8  * http://www.apache.org/licenses/LICENSE-2.0
9  *
10  * Unless required by applicable law or agreed to in writing, software
11  * distributed under the License is distributed on an AS IS BASIS,
12  * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13  * See the License for the specific language governing permissions and
14  * limitations under the License.
15  */
16
17 #ifndef __DEBUG_HEAD__
18 #define __DEBUG_HEAD__
19
20 #define LOG_TAG "INPUT_DELEGATOR"
21
22 #include <dlog.h>
23
24
25
26 /***************************************************************************************************
27  * There are 9 log levels.
28  *
29  * DLOG_ERROR - LOGE
30  * DLOG_WRAN  - LOGW
31  * DLOG_INFO  - LOGI
32  * DLOG_DEBUG - LOGD
33  *
34  * SECURE_ERROR - SECURE_LOGE
35  * SECURE_WRAN  - SECURE_LOGW
36  * SECURE_INFO  - SECURE_LOGI
37  * SECURE_DEBUG - SECURE_LOGD
38  *
39  * NO_PRINT - If you want to see a log which has a NO_PRINT option, you can modify a log level.
40  *
41  *************************************************************************************************** */
42
43 #define PRINTFUNC_DLOG_ERROR(fmt, arg...) LOGE(fmt, ##arg)
44 #define PRINTFUNC_DLOG_WARN(fmt, arg...)  LOGW(fmt, ##arg)
45 #define PRINTFUNC_DLOG_INFO(fmt, arg...)  LOGI(fmt, ##arg)
46 #define PRINTFUNC_DLOG_DEBUG(fmt, arg...) LOGD(fmt, ##arg) //LOGD(fmt, ##arg)
47
48 #define PRINTFUNC_SECURE_ERROR(fmt, arg...) SECURE_LOGE(fmt, ##arg)
49 #define PRINTFUNC_SECURE_WARN(fmt, arg...)  SECURE_LOGW(fmt, ##arg)
50 #define PRINTFUNC_SECURE_INFO(fmt, arg...)  SECURE_LOGI(fmt, ##arg)
51 #define PRINTFUNC_SECURE_DEBUG(fmt, arg...) SECURE_LOGD(fmt, ##arg)
52
53 #define PRINTFUNC_NO_PRINT(fmt, arg...) LOGE(fmt, ##arg)
54
55 #define PRINTFUNC(level,fmt, arg...) PRINTFUNC_##level (fmt, ##arg)
56
57 /*****************************************************************************************************/
58
59
60 #endif