ros2_control - rolling
Loading...
Searching...
No Matches
gz_ros2_control_plugin.hpp
1// Copyright 2021 Open Source Robotics Foundation, Inc.
2//
3// Licensed under the Apache License, Version 2.0 (the "License");
4// you may not use this file except in compliance with the License.
5// You may obtain a copy of the License at
6//
7// http://www.apache.org/licenses/LICENSE-2.0
8//
9// Unless required by applicable law or agreed to in writing, software
10// distributed under the License is distributed on an "AS IS" BASIS,
11// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
12// See the License for the specific language governing permissions and
13// limitations under the License.
14
15#ifndef GZ_ROS2_CONTROL__GZ_ROS2_CONTROL_PLUGIN_HPP_
16#define GZ_ROS2_CONTROL__GZ_ROS2_CONTROL_PLUGIN_HPP_
17
18#include <memory>
19
20#include <gz/sim/System.hh>
21namespace sim = gz::sim;
22
23namespace gz_ros2_control
24{
25// Forward declarations.
26class GazeboSimROS2ControlPluginPrivate;
27
29 : public sim::System,
30 public sim::ISystemConfigure,
31 public sim::ISystemPreUpdate,
32 public sim::ISystemPostUpdate
33{
34public:
37
40
41 // Documentation inherited
42 void Configure(
43 const sim::Entity & _entity,
44 const std::shared_ptr<const sdf::Element> & _sdf,
45 sim::EntityComponentManager & _ecm,
46 sim::EventManager & _eventMgr) override;
47
48 // Documentation inherited
49 void PreUpdate(
50 const sim::UpdateInfo & _info,
51 sim::EntityComponentManager & _ecm) override;
52
53 void PostUpdate(
54 const sim::UpdateInfo & _info,
55 const sim::EntityComponentManager & _ecm) override;
56
57private:
59 std::unique_ptr<GazeboSimROS2ControlPluginPrivate> dataPtr;
60};
61} // namespace gz_ros2_control
62
63#endif // GZ_ROS2_CONTROL__GZ_ROS2_CONTROL_PLUGIN_HPP_
Definition gz_ros2_control_plugin.hpp:33
GazeboSimROS2ControlPlugin()
Constructor.
Definition gz_ros2_control_plugin.cpp:244
~GazeboSimROS2ControlPlugin() override
Destructor.
Definition gz_ros2_control_plugin.cpp:250