WPILibC++ 2024.3.2
nt::MultiSubscriber Class Referencefinal

Subscribe to multiple topics based on one or more topic name prefixes. More...

#include <networktables/MultiSubscriber.h>

Public Member Functions

 MultiSubscriber ()=default
 
 MultiSubscriber (NetworkTableInstance inst, std::span< const std::string_view > prefixes, const PubSubOptions &options=kDefaultPubSubOptions)
 Create a multiple subscriber. More...
 
 MultiSubscriber (const MultiSubscriber &)=delete
 
MultiSubscriberoperator= (const MultiSubscriber &)=delete
 
 MultiSubscriber (MultiSubscriber &&rhs)
 
MultiSubscriberoperator= (MultiSubscriber &&rhs)
 
 ~MultiSubscriber ()
 
 operator bool () const
 Determines if the native handle is valid. More...
 
NT_MultiSubscriber GetHandle () const
 Gets the native handle. More...
 

Detailed Description

Subscribe to multiple topics based on one or more topic name prefixes.

Can be used in combination with ValueListenerPoller to listen for value changes across all matching topics.

Constructor & Destructor Documentation

◆ MultiSubscriber() [1/4]

nt::MultiSubscriber::MultiSubscriber ( )
default

◆ MultiSubscriber() [2/4]

nt::MultiSubscriber::MultiSubscriber ( NetworkTableInstance  inst,
std::span< const std::string_view prefixes,
const PubSubOptions options = kDefaultPubSubOptions 
)
inline

Create a multiple subscriber.

Parameters
instinstance
prefixestopic name prefixes
optionssubscriber options

◆ MultiSubscriber() [3/4]

nt::MultiSubscriber::MultiSubscriber ( const MultiSubscriber )
delete

◆ MultiSubscriber() [4/4]

nt::MultiSubscriber::MultiSubscriber ( MultiSubscriber &&  rhs)
inline

◆ ~MultiSubscriber()

nt::MultiSubscriber::~MultiSubscriber ( )
inline

Member Function Documentation

◆ GetHandle()

NT_MultiSubscriber nt::MultiSubscriber::GetHandle ( ) const
inline

Gets the native handle.

Returns
Handle

◆ operator bool()

nt::MultiSubscriber::operator bool ( ) const
inlineexplicit

Determines if the native handle is valid.

Returns
True if the native handle is valid, false otherwise.

◆ operator=() [1/2]

MultiSubscriber & nt::MultiSubscriber::operator= ( const MultiSubscriber )
delete

◆ operator=() [2/2]

MultiSubscriber & nt::MultiSubscriber::operator= ( MultiSubscriber &&  rhs)
inline

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