1 /*############################################################################
2   # Copyright 2016 Intel Corporation
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 /*!
18  * \file
19  * \brief Environment utilities interface.
20  */
21 #ifndef EXAMPLE_UTIL_ENVUTIL_H_
22 #define EXAMPLE_UTIL_ENVUTIL_H_
23 
24 /// set the program name
25 void set_prog_name(char const* name);
26 
27 /// get the program name
28 char const* get_prog_name();
29 
30 /// log an error
31 /*!
32 This function may add or format the message before writing it out
33 
34 output is written to the error stream
35 */
36 int log_error(char const* msg, ...);
37 
38 /// log a message
39 /*!
40 This function may add or format the message before writing it out
41 
42 output is written to the standard output stream
43 */
44 int log_msg(char const* msg, ...);
45 
46 /// log a formatted message
47 /*!
48 This function will not add or format the message before writing it out
49 
50 output is written to the standard output stream
51 */
52 int log_fmt(char const* msg, ...);
53 
54 #endif  // EXAMPLE_UTIL_ENVUTIL_H_
55