src
publishers
publishers/log.hpp
Go to the documentation of this file.
1
/*
2
* Copyright 2015 Aldebaran
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
#ifndef PUBLISHER_LOG_HPP
19
#define PUBLISHER_LOG_HPP
20
21
/*
22
* LOCAL includes
23
*/
24
#include "
basic.hpp
"
25
26
/*
27
* ROS includes
28
*/
29
#include <
ros/ros.h
>
30
#include <rosgraph_msgs/Log.h>
31
#include <
ros/serialization.h
>
32
#include <std_msgs/String.h>
33
34
/*
35
* BOOST includes
36
*/
37
#include <boost/algorithm/string.hpp>
38
#include <boost/thread/mutex.hpp>
39
40
/*
41
* ALDEBARAN includes
42
*/
43
#include <qi/anyobject.hpp>
44
#include <
qicore/logmessage.hpp
>
45
#include <
qicore/logmanager.hpp
>
46
#include <
qicore/loglistener.hpp
>
47
48
namespace
naoqi
49
{
50
namespace
publisher
51
{
52
53
class
LogPublisher
:
public
BasicPublisher
<rosgraph_msgs::Log>
54
{
55
public
:
56
LogPublisher
(
const
std::string&
topic
);
57
58
// check whether a real copy of the log message should be more safe
59
// remove const ref here
60
61
inline
bool
isSubscribed
()
const
62
{
63
// We assume it is essential
64
return
true
;
65
}
66
67
private
:
68
ros::Publisher
pub_
;
69
70
};
71
72
}
//publisher
73
}
//naoqi
74
75
#endif
ros::Publisher
ros.h
loglistener.hpp
basic.hpp
logmessage.hpp
naoqi
Definition:
converter.hpp:29
naoqi::publisher::LogPublisher::isSubscribed
bool isSubscribed() const
Definition:
publishers/log.hpp:61
naoqi::publisher::LogPublisher::LogPublisher
LogPublisher(const std::string &topic)
Definition:
publishers/log.cpp:28
serialization.h
naoqi::publisher::BasicPublisher< rosgraph_msgs::Log >::topic
std::string topic() const
Definition:
publishers/basic.hpp:45
naoqi::publisher::BasicPublisher
Definition:
publishers/basic.hpp:34
logmanager.hpp
naoqi::publisher::LogPublisher
Definition:
publishers/log.hpp:53
naoqi::publisher::LogPublisher::pub_
ros::Publisher pub_
Definition:
publishers/log.hpp:68
naoqi_driver
Author(s): Karsten Knese
autogenerated on Sat Feb 3 2024 03:50:06