- All Implemented Interfaces:
public class InternalButton extends Button
This class is intended to be used within a program. The programmer can manually set its value. Also includes a setting for whether or not it should invert its value.
This class is provided by the NewCommands VendorDep
Methods inherited from class edu.wpi.first.wpilibj2.command.button.Button
cancelWhenPressed, toggleWhenPressed, toggleWhenPressed, whenHeld, whenHeld, whenPressed, whenPressed, whenPressed, whenReleased, whenReleased, whenReleased, whileHeld, whileHeld, whileHeld
Methods inherited from class edu.wpi.first.wpilibj2.command.button.Trigger
and, cancelWhenActive, debounce, debounce, getAsBoolean, negate, or, toggleWhenActive, toggleWhenActive, whenActive, whenActive, whenActive, whenInactive, whenInactive, whenInactive, whileActiveContinuous, whileActiveContinuous, whileActiveContinuous, whileActiveOnce, whileActiveOnce
public InternalButton()Creates an InternalButton that is not inverted.
public InternalButton(boolean inverted)Creates an InternalButton which is inverted depending on the input.
inverted- if false, then this button is pressed when set to true, otherwise it is pressed when set to false.
public void setInverted(boolean inverted)
public void setPressed(boolean pressed)
public boolean get()Description copied from class:
TriggerReturns whether or not the trigger is active.
This method will be called repeatedly a command is linked to the Trigger.
Functionally identical to