WPILibC++ 2024.3.2
|
Functions | |
bool | nt::SetBooleanArray (NT_Handle pubentry, std::span< const int > value, int64_t time=0) |
Publish a new value. More... | |
bool | nt::SetDefaultBooleanArray (NT_Handle pubentry, std::span< const int > defaultValue) |
Publish a default value. More... | |
std::vector< int > | nt::GetBooleanArray (NT_Handle subentry, std::span< const int > defaultValue) |
Get the last published value. More... | |
TimestampedBooleanArray | nt::GetAtomicBooleanArray (NT_Handle subentry, std::span< const int > defaultValue) |
Get the last published value along with its timestamp. More... | |
std::vector< TimestampedBooleanArray > | nt::ReadQueueBooleanArray (NT_Handle subentry) |
Get an array of all value changes since the last call to ReadQueue. More... | |
std::vector< std::vector< int > > | nt::ReadQueueValuesBooleanArray (NT_Handle subentry) |
Get an array of all value changes since the last call to ReadQueue. More... | |
std::span< int > | nt::GetBooleanArray (NT_Handle subentry, wpi::SmallVectorImpl< int > &buf, std::span< const int > defaultValue) |
TimestampedBooleanArrayView | nt::GetAtomicBooleanArray (NT_Handle subentry, wpi::SmallVectorImpl< int > &buf, std::span< const int > defaultValue) |
TimestampedBooleanArray nt::GetAtomicBooleanArray | ( | NT_Handle | subentry, |
std::span< const int > | defaultValue | ||
) |
Get the last published value along with its timestamp.
If no value has been published, returns the passed defaultValue and a timestamp of 0.
subentry | subscriber or entry handle |
defaultValue | default value to return if no value has been published |
TimestampedBooleanArrayView nt::GetAtomicBooleanArray | ( | NT_Handle | subentry, |
wpi::SmallVectorImpl< int > & | buf, | ||
std::span< const int > | defaultValue | ||
) |
std::vector< int > nt::GetBooleanArray | ( | NT_Handle | subentry, |
std::span< const int > | defaultValue | ||
) |
Get the last published value.
If no value has been published, returns the passed defaultValue.
subentry | subscriber or entry handle |
defaultValue | default value to return if no value has been published |
std::span< int > nt::GetBooleanArray | ( | NT_Handle | subentry, |
wpi::SmallVectorImpl< int > & | buf, | ||
std::span< const int > | defaultValue | ||
) |
std::vector< TimestampedBooleanArray > nt::ReadQueueBooleanArray | ( | NT_Handle | subentry | ) |
Get an array of all value changes since the last call to ReadQueue.
Also provides a timestamp for each value.
subentry | subscriber or entry handle |
std::vector< std::vector< int > > nt::ReadQueueValuesBooleanArray | ( | NT_Handle | subentry | ) |
Get an array of all value changes since the last call to ReadQueue.
subentry | subscriber or entry handle |
bool nt::SetBooleanArray | ( | NT_Handle | pubentry, |
std::span< const int > | value, | ||
int64_t | time = 0 |
||
) |
Publish a new value.
pubentry | publisher or entry handle |
value | value to publish |
time | timestamp; 0 indicates current NT time should be used |
bool nt::SetDefaultBooleanArray | ( | NT_Handle | pubentry, |
std::span< const int > | defaultValue | ||
) |
Publish a default value.
On reconnect, a default value will never be used in preference to a published value.
pubentry | publisher or entry handle |
defaultValue | default value |