CTRE Phoenix 6 C++ 26.70.0-alpha-2
Loading...
Searching...
No Matches
ctre::phoenix6::MultiAlertInfo Struct Referencefinal

Information about a multi-level alert. More...

#include <ctre/phoenix6/Alertable.hpp>

Static Public Member Functions

static MultiAlertInfo Inactive ()
 Creates new information for an inactive multi-level alert.
template<std::convertible_to< std::optional< std::string > > S = std::optional<std::string>>
static MultiAlertInfo Active (PhoenixMultiAlert::Level level, S &&text=std::nullopt)
 Creates new information for an active multi-level alert.

Public Attributes

bool isActive {}
 Whether the multi-level alert is active.
PhoenixMultiAlert::Level level {}
 The new alert urgency level.
std::optional< std::string > text {}
 The new text to report in the alert, or nullopt to leave the text unchanged.

Detailed Description

Information about a multi-level alert.

Member Function Documentation

◆ Active()

template<std::convertible_to< std::optional< std::string > > S = std::optional<std::string>>
MultiAlertInfo ctre::phoenix6::MultiAlertInfo::Active ( PhoenixMultiAlert::Level level,
S && text = std::nullopt )
inlinestatic

Creates new information for an active multi-level alert.

Template Parameters
SType of the text, convertible to std::optional<std::string>
Parameters
levelNew alert urgency level
textNew text to report in the alert, or nullopt to leave the text unchanged
Returns
Information for an active multi-level alert

◆ Inactive()

MultiAlertInfo ctre::phoenix6::MultiAlertInfo::Inactive ( )
inlinestatic

Creates new information for an inactive multi-level alert.

Returns
Information for an inactive multi-level alert

Member Data Documentation

◆ isActive

bool ctre::phoenix6::MultiAlertInfo::isActive {}

Whether the multi-level alert is active.

◆ level

PhoenixMultiAlert::Level ctre::phoenix6::MultiAlertInfo::level {}

The new alert urgency level.

◆ text

std::optional<std::string> ctre::phoenix6::MultiAlertInfo::text {}

The new text to report in the alert, or nullopt to leave the text unchanged.


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