util/DiagnosticsPrivate.hh
Go to the documentation of this file.
1 /*
2  * Copyright (C) 2015-2016 Open Source Robotics Foundation
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 #ifndef _GAZEBO_UTILS_DIAGNOSTICMANAGER_PRIVATE_HH_
18 #define _GAZEBO_UTILS_DIAGNOSTICMANAGER_PRIVATE_HH_
19 
20 #include <fstream>
21 #include <string>
22 #include <boost/filesystem.hpp>
23 
25 #include "gazebo/msgs/msgs.hh"
26 #include "gazebo/common/Time.hh"
27 #include "gazebo/common/Event.hh"
28 #include "gazebo/util/UtilTypes.hh"
29 
30 namespace gazebo
31 {
32  namespace util
33  {
36  {
38  public: TimerMap timers;
39 
41  public: boost::filesystem::path logPath;
42 
45 
48 
50  public: msgs::Diagnostics msg;
51 
54  };
55 
58  {
60  public: std::string name;
61 
63  public: std::ofstream log;
64 
67  };
68  }
69 }
70 #endif
boost::shared_ptr< Connection > ConnectionPtr
Definition: CommonTypes.hh:153
Forward declarations for transport.
common::Time prevLap
Time of the previous lap.
Definition: util/DiagnosticsPrivate.hh:66
msgs::Diagnostics msg
The message to output.
Definition: util/DiagnosticsPrivate.hh:50
Private data for the DiagnosticManager class.
Definition: util/DiagnosticsPrivate.hh:35
transport::NodePtr node
Node for publishing diagnostic data.
Definition: util/DiagnosticsPrivate.hh:44
TimerMap timers
dictionary of timers index by name
Definition: util/DiagnosticsPrivate.hh:38
Private data for the DiagnosticTimer class.
Definition: util/DiagnosticsPrivate.hh:57
event::ConnectionPtr updateConnection
Pointer to the update event connection.
Definition: util/DiagnosticsPrivate.hh:53
std::string name
Name of the timer.
Definition: util/DiagnosticsPrivate.hh:60
transport::PublisherPtr pub
Publisher of diagnostic data.
Definition: util/DiagnosticsPrivate.hh:47
boost::shared_ptr< Node > NodePtr
Definition: TransportTypes.hh:57
std::unordered_map< std::string, DiagnosticTimerPtr > TimerMap
Definition: UtilTypes.hh:52
boost::filesystem::path logPath
Path in which to store timing logs.
Definition: util/DiagnosticsPrivate.hh:41
boost::shared_ptr< Publisher > PublisherPtr
Definition: TransportTypes.hh:49
std::ofstream log
Log file.
Definition: util/DiagnosticsPrivate.hh:63
A Time class, can be used to hold wall- or sim-time.
Definition: Time.hh:44