mirror of
https://github.com/wpilibsuite/allwpilib
synced 2026-06-24 01:31:46 +00:00
[wpilib] Deprecate Timer::HasPeriodPassed() (#3598)
AdvanceIfElapsed() is safer to use, as it has less surprising side effects.
This commit is contained in:
@@ -134,7 +134,9 @@ public class Timer {
|
||||
*
|
||||
* @param period The period to check for (in seconds).
|
||||
* @return Whether the period has passed.
|
||||
* @deprecated Use advanceIfElapsed() instead.
|
||||
*/
|
||||
@Deprecated(since = "2022", forRemoval = true)
|
||||
public boolean hasPeriodPassed(double period) {
|
||||
return advanceIfElapsed(period);
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user