[wpilib] Compressor: Rename enabled to isEnabled (#4147)

This is a less confusing name, as enabled() can imply it enables the compressor.
This commit is contained in:
Spud
2022-04-08 21:31:08 -07:00
committed by GitHub
parent 5bf46a9093
commit 975171609e
3 changed files with 33 additions and 4 deletions

View File

@@ -78,11 +78,24 @@ class Compressor : public wpi::Sendable,
/**
* Check if compressor output is active.
* To (re)enable the compressor use EnableDigital() or EnableAnalog(...).
*
* @return true if the compressor is on
* @return true if the compressor is on.
* @deprecated To avoid confusion in thinking this (re)enables the compressor
* use IsEnabled().
*/
WPI_DEPRECATED(
"To avoid confusion in thinking this (re)enables the compressor use "
"IsEnabled()")
bool Enabled() const;
/**
* Returns whether the compressor is active or not.
*
* @return true if the compressor is on - otherwise false.
*/
bool IsEnabled() const;
/**
* Check if the pressure switch is triggered.
*