Robot Core Documentation
Public Member Functions | List of all members
edu.wpi.first.wpilibj2.command.WaitUntilCommand Class Reference
Inheritance diagram for edu.wpi.first.wpilibj2.command.WaitUntilCommand:
edu.wpi.first.wpilibj2.command.CommandBase edu.wpi.first.wpilibj2.command.Command

Public Member Functions

 WaitUntilCommand (BooleanSupplier condition)
boolean isFinished ()
boolean runsWhenDisabled ()
- Public Member Functions inherited from edu.wpi.first.wpilibj2.command.CommandBase
final void addRequirements (Subsystem... requirements)
Set< SubsystemgetRequirements ()
- Public Member Functions inherited from edu.wpi.first.wpilibj2.command.Command
default void initialize ()
default void execute ()
default void end (boolean interrupted)
default ParallelRaceGroup withTimeout (double seconds)
default ParallelRaceGroup withInterrupt (BooleanSupplier condition)
default SequentialCommandGroup beforeStarting (Runnable toRun, Subsystem... requirements)
default SequentialCommandGroup andThen (Runnable toRun, Subsystem... requirements)
default SequentialCommandGroup andThen (Command... next)
default ParallelDeadlineGroup deadlineWith (Command... parallel)
default ParallelCommandGroup alongWith (Command... parallel)
default ParallelRaceGroup raceWith (Command... parallel)
default PerpetualCommand perpetually ()
default ProxyScheduleCommand asProxy ()
default void schedule (boolean interruptible)
default void schedule ()
default void cancel ()
default boolean isScheduled ()
default boolean hasRequirement (Subsystem requirement)
default String getName ()

Additional Inherited Members

- Protected Attributes inherited from edu.wpi.first.wpilibj2.command.CommandBase
Set< Subsystemm_requirements = new HashSet<>()

Detailed Description

A command that does nothing but ends after a specified match time or condition. Useful for CommandGroups.

Constructor & Destructor Documentation

◆ WaitUntilCommand()

edu.wpi.first.wpilibj2.command.WaitUntilCommand.WaitUntilCommand ( BooleanSupplier  condition)

Creates a new WaitUntilCommand that ends after a given condition becomes true.

conditionthe condition to determine when to end

Member Function Documentation

◆ isFinished()

boolean edu.wpi.first.wpilibj2.command.WaitUntilCommand.isFinished ( )

Creates a new WaitUntilCommand that ends after a given match time.

NOTE: The match timer used for this command is UNOFFICIAL. Using this command does NOT guarantee that the time at which the action is performed will be judged to be legal by the referees. When in doubt, add a safety factor or time the action manually.

timethe match time after which to end, in seconds

Implements edu.wpi.first.wpilibj2.command.Command.

◆ runsWhenDisabled()

boolean edu.wpi.first.wpilibj2.command.WaitUntilCommand.runsWhenDisabled ( )

Whether the given command should run when the robot is disabled. Override to return true if the command should run when disabled.

whether the command should run when the robot is disabled

Implements edu.wpi.first.wpilibj2.command.Command.

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