TransporterPluginPrivate.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_TRANSPORTER_PLUGIN_PRIVATE_HH_
18 #define _GAZEBO_TRANSPORTER_PLUGIN_PRIVATE_HH_
19 
20 #include <map>
21 #include <string>
22 #include <mutex>
23 #include <memory>
24 
25 #include <gazebo/transport/Node.hh>
27 
28 namespace gazebo
29 {
31  {
33  public: class Pad
34  {
36  public: std::string name;
37 
39  public: std::string dest;
40 
44 
47 
51  public: bool autoActivation;
52 
56  public: bool activated = false;
57  };
58 
61 
63  public: std::map<std::string, std::shared_ptr<Pad> > pads;
64 
67 
70 
73 
75  public: std::mutex padMutex;
76  };
77 }
78 #endif
boost::shared_ptr< Connection > ConnectionPtr
Definition: CommonTypes.hh:153
Encapsulates a position and rotation in three space.
Definition: Pose.hh:37
Mathematical representation of a box and related functions.
Definition: Box.hh:35
boost::shared_ptr< Subscriber > SubscriberPtr
Definition: TransportTypes.hh:53
std::mutex padMutex
Mutex to protect pad data.
Definition: TransporterPluginPrivate.hh:75
std::string dest
Name of the destination pad.
Definition: TransporterPluginPrivate.hh:39
transport::NodePtr node
Node for communication.
Definition: TransporterPluginPrivate.hh:69
transport::SubscriberPtr activationSub
Subscriber to the activation topic.
Definition: TransporterPluginPrivate.hh:72
bool activated
This flag is used for manual activation of a pad.
Definition: TransporterPluginPrivate.hh:56
math::Pose incomingPose
Pose of the incoming pad.
Definition: TransporterPluginPrivate.hh:43
event::ConnectionPtr updateConnection
Pointer to the update event connection.
Definition: TransporterPluginPrivate.hh:66
bool autoActivation
True if the pad should automatically teleport.
Definition: TransporterPluginPrivate.hh:51
Definition of a transported pad.
Definition: TransporterPluginPrivate.hh:33
Definition: TransporterPluginPrivate.hh:30
std::string name
Name of the pad.
Definition: TransporterPluginPrivate.hh:36
physics::WorldPtr world
World pointer.
Definition: TransporterPluginPrivate.hh:60
boost::shared_ptr< World > WorldPtr
Definition: PhysicsTypes.hh:84
boost::shared_ptr< Node > NodePtr
Definition: TransportTypes.hh:57
std::map< std::string, std::shared_ptr< Pad > > pads
Map of all the transporter pads.
Definition: TransporterPluginPrivate.hh:63
math::Box outgoingBox
Box that defines the activation region of the transporter.
Definition: TransporterPluginPrivate.hh:46