RDK Documentation (Open Sourced RDK Components)
rdk_utils.h
Go to the documentation of this file.
1 /*
2  * If not stated otherwise in this file or this component's Licenses.txt file the
3  * following copyright and licenses apply:
4  *
5  * Copyright 2016 RDK Management
6  *
7  * Licensed under the Apache License, Version 2.0 (the "License");
8  * you may not use this file except in compliance with the License.
9  * You may obtain a copy of the License at
10  *
11  * http://www.apache.org/licenses/LICENSE-2.0
12  *
13  * Unless required by applicable law or agreed to in writing, software
14  * distributed under the License is distributed on an "AS IS" BASIS,
15  * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
16  * See the License for the specific language governing permissions and
17  * limitations under the License.
18 */
19 
20 /**
21  * @file rdk_utils.h
22  * The header file provides RDK Utils APIs.
23  */
24 
25 
26 /**
27 * @defgroup rdk_logger
28 * @{
29 * @defgroup include
30 * @{
31 **/
32 
33 
34 #ifndef _RDK_UTILS_H_
35 #define _RDK_UTILS_H_
36 
37 #include <stdio.h>
38 #include <rdk_error.h>
39 #include <rdk_utils.h>
40 #ifdef __cplusplus
41 extern "C"
42 {
43 #endif
44 
45 /**
46  * @ingroup RDKLOGGER_UTILS_API
47  * @{
48  */
49 
50 const char* rdk_logger_envGet(const char *name);
51 
52 int rdk_logger_envGetNum(const char * mod);
53 
54 const char* rdk_logger_envGetValueFromNum(int number);
55 
56 const char* rdk_logger_envGetModFromNum(int Num);
57 
58 rdk_Error rdk_logger_env_add_conf_file(const char * path);
59 
60 /** @} */ //end of Doxygen tag RDKLOGGER_UTILS_API
61 
62 #ifdef __cplusplus
63 }
64 #endif
65 
66 #endif /* _RDK_DEBUG_H_ */
67 
rdk_logger_envGetModFromNum
const char * rdk_logger_envGetModFromNum(int Num)
This function is used to get the name of the specified environment variable based on its registered n...
Definition: rdk_logger_util.c:285
rdk_utils.h
rdk_logger_envGetNum
int rdk_logger_envGetNum(const char *mod)
Function will give the registered number of the specified environment variable.
Definition: rdk_logger_util.c:257
rdk_logger_envGetValueFromNum
const char * rdk_logger_envGetValueFromNum(int number)
This function is used to get the value of the specified environment variable based on its registered ...
Definition: rdk_logger_util.c:231
rdk_logger_envGet
const char * rdk_logger_envGet(const char *name)
This function will get value of the specified environment variable.
Definition: rdk_logger_util.c:203
rdk_logger_env_add_conf_file
rdk_Error rdk_logger_env_add_conf_file(const char *path)
This Function sets up the environment variable cache by parsing configuration file and adding each na...
Definition: rdk_logger_util.c:97