MoveIt Pro API
Core Behaviors for MoveIt Pro
Loading...
Searching...
No Matches
moveit_studio::behaviors::SetupMTCAttachOrDetachObject Class Reference

This is the base class for SetupMTCAttachObject and SetupMTCDetachObject. More...

#include <setup_mtc_attach_object.hpp>

Inheritance diagram for moveit_studio::behaviors::SetupMTCAttachOrDetachObject:
Collaboration diagram for moveit_studio::behaviors::SetupMTCAttachOrDetachObject:

Public Types

enum class  Operation { ATTACH , DETACH }
 

Public Member Functions

 SetupMTCAttachOrDetachObject (const std::string &name, const BT::NodeConfiguration &config, const std::shared_ptr< BehaviorContext > &shared_resources, const Operation &operation)
 
BT::NodeStatus tick () override
 
- Public Member Functions inherited from moveit_studio::behaviors::SharedResourcesNode< BT::SyncActionNode >
 SharedResourcesNode (const std::string &name, const BT::NodeConfiguration &config, const std::shared_ptr< BehaviorContext > &shared_resources)
 Constructor for SharedResourcesNode. Called by BT::BehaviorTreeFactory when creating a new behavior tree containing this node.
 

Protected Attributes

const Operation operation_
 
- Protected Attributes inherited from moveit_studio::behaviors::SharedResourcesNode< BT::SyncActionNode >
std::shared_ptr< BehaviorContextshared_resources_
 

Detailed Description

This is the base class for SetupMTCAttachObject and SetupMTCDetachObject.

The only internal difference between these Behaviors is whether the ModifyPlanningScene stage is attaching or releasing the object, so it is efficient to reuse the elements that are in common.

Toggle between attaching or releasing by passing a different Operation enum in the constructor.

Member Enumeration Documentation

◆ Operation

Constructor & Destructor Documentation

◆ SetupMTCAttachOrDetachObject()

moveit_studio::behaviors::SetupMTCAttachOrDetachObject::SetupMTCAttachOrDetachObject ( const std::string &  name,
const BT::NodeConfiguration &  config,
const std::shared_ptr< BehaviorContext > &  shared_resources,
const Operation operation 
)

Member Function Documentation

◆ tick()

BT::NodeStatus moveit_studio::behaviors::SetupMTCAttachOrDetachObject::tick ( )
override

Member Data Documentation

◆ operation_

const Operation moveit_studio::behaviors::SetupMTCAttachOrDetachObject::operation_
protected

The documentation for this class was generated from the following files: