2 // Copyright (c) 2012 Samsung Electronics Co., Ltd.
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
8 // http://www.apache.org/licenses/LICENSE-2.0
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.
19 * @brief This file is internal header for Log.
21 #ifndef _FBASE_INTERNAL_LOG_H_
22 #define _FBASE_INTERNAL_LOG_H_
25 #include <FOspConfig.h>
26 #include <FBaseDataType.h>
27 #include <FIoRegistry.h>
33 #define LOG_MODULE_NAME_LEN_MAX 30
34 #define LOG_TAG_LEN_MAX 50
35 #define LOG_LEN_MAX 1024
36 #define PROPAGATION_LEN_MAX 512
44 typedef struct LogEntry
47 char logIDName[LOG_MODULE_NAME_LEN_MAX];
48 char logModuleName[LOG_MODULE_NAME_LEN_MAX];
55 typedef struct LogInfo
57 LogEntry logTable[NID_MAX];
62 bool platformInfoEnabled;
63 bool platformExceptionEnabled;
65 bool applicationInfoEnabled;
66 bool applicationDebugEnabled;
67 bool applicationExceptionEnabled;
81 void __PrintLog(_LogType type, const char* pFunction, int lineNumber, const char* pFormat, va_list args);
82 void __PrintLogTag(const char* pTag, _LogType type, const char* pFunction, int lineNumber, const char* pFormat, va_list args);
83 void __PrintSysLog(_LogType type, LogID id, const char* pFunction, int lineNumber, const char* pFormat, va_list args);
84 void __PrintSysLogTag(const char* pTag, _LogType type, LogID id, const char* pFunction, int lineNumber, const char* pFormat, va_list args);
86 char* __GetModuleName(LogID id);
87 bool __GetEnableInfo(LogID id);
89 void __InitializeLogInfo(void);
90 void __InitializeLogLevel(const Tizen::Io::Registry& reg);
91 void __InitializePlatformModule(const Tizen::Io::Registry& reg);
96 #endif // _FBASE_INTERNAL_LOG_H_