WPILibC++ 2023.4.3
frc::SendableChooserBase Class Reference

This class is a non-template base class for SendableChooser. More...

#include <frc/smartdashboard/SendableChooserBase.h>

Inheritance diagram for frc::SendableChooserBase:
nt::NTSendable wpi::SendableHelper< SendableChooserBase > wpi::Sendable frc::SendableChooser< T >

Public Member Functions

 SendableChooserBase ()
 
 ~SendableChooserBase () override=default
 
 SendableChooserBase (SendableChooserBase &&oth)
 
SendableChooserBaseoperator= (SendableChooserBase &&oth)
 
- Public Member Functions inherited from nt::NTSendable
virtual void InitSendable (NTSendableBuilder &builder)=0
 Initializes this Sendable object. More...
 
void InitSendable (wpi::SendableBuilder &builder) override
 Initializes this Sendable object. More...
 
- Public Member Functions inherited from wpi::Sendable
virtual ~Sendable ()=default
 
virtual void InitSendable (SendableBuilder &builder)=0
 Initializes this Sendable object. More...
 
- Public Member Functions inherited from wpi::SendableHelper< SendableChooserBase >
 SendableHelper (const SendableHelper &rhs)=default
 
 SendableHelper (SendableHelper &&rhs)
 
SendableHelperoperator= (const SendableHelper &rhs)=default
 
SendableHelperoperator= (SendableHelper &&rhs)
 

Protected Attributes

std::string m_defaultChoice
 
std::string m_selected
 
bool m_haveSelected = false
 
wpi::SmallVector< nt::IntegerPublisher, 2 > m_instancePubs
 
wpi::SmallVector< nt::StringPublisher, 2 > m_activePubs
 
wpi::mutex m_mutex
 
int m_instance
 

Static Protected Attributes

static constexpr const char * kDefault = "default"
 
static constexpr const char * kOptions = "options"
 
static constexpr const char * kSelected = "selected"
 
static constexpr const char * kActive = "active"
 
static constexpr const char * kInstance = ".instance"
 
static std::atomic_int s_instances
 

Additional Inherited Members

- Protected Member Functions inherited from wpi::SendableHelper< SendableChooserBase >
 SendableHelper ()=default
 
 ~SendableHelper ()
 

Detailed Description

This class is a non-template base class for SendableChooser.

It contains static, non-templated variables to avoid their duplication in the template class.

Constructor & Destructor Documentation

◆ SendableChooserBase() [1/2]

frc::SendableChooserBase::SendableChooserBase ( )

◆ ~SendableChooserBase()

frc::SendableChooserBase::~SendableChooserBase ( )
overridedefault

◆ SendableChooserBase() [2/2]

frc::SendableChooserBase::SendableChooserBase ( SendableChooserBase &&  oth)

Member Function Documentation

◆ operator=()

SendableChooserBase & frc::SendableChooserBase::operator= ( SendableChooserBase &&  oth)

Member Data Documentation

◆ kActive

constexpr const char* frc::SendableChooserBase::kActive = "active"
staticconstexprprotected

◆ kDefault

constexpr const char* frc::SendableChooserBase::kDefault = "default"
staticconstexprprotected

◆ kInstance

constexpr const char* frc::SendableChooserBase::kInstance = ".instance"
staticconstexprprotected

◆ kOptions

constexpr const char* frc::SendableChooserBase::kOptions = "options"
staticconstexprprotected

◆ kSelected

constexpr const char* frc::SendableChooserBase::kSelected = "selected"
staticconstexprprotected

◆ m_activePubs

wpi::SmallVector<nt::StringPublisher, 2> frc::SendableChooserBase::m_activePubs
protected

◆ m_defaultChoice

std::string frc::SendableChooserBase::m_defaultChoice
protected

◆ m_haveSelected

bool frc::SendableChooserBase::m_haveSelected = false
protected

◆ m_instance

int frc::SendableChooserBase::m_instance
protected

◆ m_instancePubs

wpi::SmallVector<nt::IntegerPublisher, 2> frc::SendableChooserBase::m_instancePubs
protected

◆ m_mutex

wpi::mutex frc::SendableChooserBase::m_mutex
protected

◆ m_selected

std::string frc::SendableChooserBase::m_selected
protected

◆ s_instances

std::atomic_int frc::SendableChooserBase::s_instances
staticprotected

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