YARP
Yet Another Robot Platform
LogComponent.h
Go to the documentation of this file.
1
/*
2
* SPDX-FileCopyrightText: 2006-2021 Istituto Italiano di Tecnologia (IIT)
3
* SPDX-License-Identifier: BSD-3-Clause
4
*/
5
6
#ifndef YARP_OS_IMPL_LOGCOMPONENT_H
7
#define YARP_OS_IMPL_LOGCOMPONENT_H
8
9
#include <
yarp/os/api.h
>
10
#include <
yarp/os/LogComponent.h
>
11
12
namespace
yarp::os::impl::LogComponent
{
13
14
void
print_callback
(
yarp::os::Log::LogType
type,
15
const
char
* msg,
16
const
char
* file,
17
const
unsigned
int
line,
18
const
char
* func,
19
double
systemtime,
20
double
networktime,
21
double
externaltime,
22
const
char
* comp_name);
23
24
yarp::os::Log::LogType
minimumLogType
();
25
void
setMinumumLogType
(
yarp::os::Log::LogType
minumumLogType);
26
27
}
// namespace yarp::os::impl::LogComponent
28
29
#define YARP_OS_LOG_COMPONENT(name, name_string) \
30
const yarp::os::LogComponent& name() \
31
{ \
32
static const yarp::os::LogComponent component(name_string, \
33
yarp::os::impl::LogComponent::minimumLogType(), \
34
yarp::os::Log::LogTypeReserved, \
35
yarp::os::Log::defaultPrintCallback(), \
36
nullptr); \
37
return component; \
38
}
39
40
#define YARP_OS_NON_CONST_LOG_COMPONENT(name, name_string) \
41
yarp::os::LogComponent& name() \
42
{ \
43
static yarp::os::LogComponent component(name_string, \
44
yarp::os::impl::LogComponent::minimumLogType(), \
45
yarp::os::Log::LogTypeReserved, \
46
yarp::os::Log::defaultPrintCallback(), \
47
nullptr); \
48
return component; \
49
}
50
51
#endif
// YARP_OS_IMPL_LOGCOMPONENT_H
yarp::os::Log::LogType
LogType
Definition:
Log.h:89
LogComponent.h
yarp::os::impl::LogComponent
Definition:
LogComponent.h:12
yarp::os::impl::LogComponent::print_callback
void print_callback(yarp::os::Log::LogType type, const char *msg, const char *file, const unsigned int line, const char *func, double systemtime, double networktime, double externaltime, const char *comp_name)
yarp::os::impl::LogComponent::minimumLogType
yarp::os::Log::LogType minimumLogType()
Definition:
LogComponent.cpp:25
yarp::os::impl::LogComponent::setMinumumLogType
void setMinumumLogType(yarp::os::Log::LogType minumumLogType)
Definition:
LogComponent.cpp:30
api.h
YARP
3.7.2+72-20221008.2+gitbb7fa68a9
src
libYARP_os
src
yarp
os
impl
LogComponent.h
Generated on Thu Oct 27 2022 02:58:50 for YARP by
1.9.4