EasyFleet
A simple-by-default framework for multi-robot, multi-capability fleets built on ROS 2
Toggle main menu visibility
Loading...
Searching...
No Matches
finish.hpp
1
// Copyright 2026 Intelligent Robotics Lab
2
//
3
// This file is part of the project EasyFleet
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
#ifndef EASYFLEET_EASYNAV_DEPLOYMENT__BT_NODES__FINISH_HPP_
17
#define EASYFLEET_EASYNAV_DEPLOYMENT__BT_NODES__FINISH_HPP_
18
19
#include <chrono>
20
#include <string>
21
22
#include "behaviortree_cpp/action_node.h"
23
24
namespace
easyfleet_easynav_deployment
25
{
26
29
class
Finish
:
public
BT::StatefulActionNode
30
{
31
public
:
35
Finish
(
const
std::string & name,
const
BT::NodeConfig & config);
36
39
static
BT::PortsList
providedPorts
();
40
43
BT::NodeStatus
onStart
()
override
;
47
BT::NodeStatus
onRunning
()
override
;
49
void
onHalted
()
override
;
50
51
private
:
52
std::chrono::steady_clock::time_point start_time_;
53
};
54
55
}
// namespace easyfleet_easynav_deployment
56
57
#endif
// EASYFLEET_EASYNAV_DEPLOYMENT__BT_NODES__FINISH_HPP_
easyfleet_easynav_deployment::Finish::onHalted
void onHalted() override
No-op: this node has nothing to clean up on halt.
Definition
finish.cpp:56
easyfleet_easynav_deployment::Finish::Finish
Finish(const std::string &name, const BT::NodeConfig &config)
Constructs the BT node.
Definition
finish.cpp:30
easyfleet_easynav_deployment::Finish::onRunning
BT::NodeStatus onRunning() override
Waits out the fixed 2-second delay.
Definition
finish.cpp:47
easyfleet_easynav_deployment::Finish::onStart
BT::NodeStatus onStart() override
Records the start time and logs a finishing message.
Definition
finish.cpp:40
easyfleet_easynav_deployment::Finish::providedPorts
static BT::PortsList providedPorts()
This node's ports (none).
Definition
finish.cpp:35
easyfleet_example_deployments
easyfleet_easynav_deployment
include
easyfleet_easynav_deployment
bt_nodes
finish.hpp
Generated by
1.17.0