WPILibC++ 2024.3.1
frc2::CommandHelper< Base, CRTP > Class Template Reference

CRTP implementation to allow polymorphic decorator functions in Command. More...

#include <frc2/command/CommandHelper.h>

Inheritance diagram for frc2::CommandHelper< Base, CRTP >:

Public Member Functions

 CommandHelper ()=default
 
CommandPtr ToPtr () &&override
 

Protected Member Functions

std::unique_ptr< CommandTransferOwnership () &&override
 

Detailed Description

template<std::derived_from< Command > Base, typename CRTP>
class frc2::CommandHelper< Base, CRTP >

CRTP implementation to allow polymorphic decorator functions in Command.

Note: ALWAYS create a subclass by extending CommandHelper<Base, Subclass>, or decorators will not function!

This class is provided by the NewCommands VendorDep

Constructor & Destructor Documentation

◆ CommandHelper()

template<std::derived_from< Command > Base, typename CRTP >
frc2::CommandHelper< Base, CRTP >::CommandHelper ( )
default

Member Function Documentation

◆ ToPtr()

template<std::derived_from< Command > Base, typename CRTP >
CommandPtr frc2::CommandHelper< Base, CRTP >::ToPtr ( ) &&
inlineoverride

◆ TransferOwnership()

template<std::derived_from< Command > Base, typename CRTP >
std::unique_ptr< Command > frc2::CommandHelper< Base, CRTP >::TransferOwnership ( ) &&
inlineoverrideprotected

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