Class NetworkButton
java.lang.Object
edu.wpi.first.wpilibj2.command.button.Trigger
edu.wpi.first.wpilibj2.command.button.Button
edu.wpi.first.wpilibj2.command.button.NetworkButton
- All Implemented Interfaces:
BooleanSupplier
public class NetworkButton extends Button
A
Button
that uses a NetworkTable
boolean field.
This class is provided by the NewCommands VendorDep
-
Constructor Summary
Constructors Constructor Description NetworkButton(BooleanSubscriber sub)
Creates a NetworkButton that commands can be bound to.NetworkButton(BooleanTopic topic)
Creates a NetworkButton that commands can be bound to.NetworkButton(NetworkTableInstance inst, String table, String field)
Creates a NetworkButton that commands can be bound to.NetworkButton(NetworkTable table, String field)
Creates a NetworkButton that commands can be bound to.NetworkButton(String table, String field)
Creates a NetworkButton that commands can be bound to. -
Method Summary
Methods inherited from class edu.wpi.first.wpilibj2.command.button.Button
cancelWhenPressed, toggleWhenPressed, whenHeld, whenPressed, whenPressed, whenReleased, whenReleased, whileHeld, whileHeld
Methods inherited from class edu.wpi.first.wpilibj2.command.button.Trigger
and, cancelWhenActive, debounce, debounce, getAsBoolean, negate, onFalse, onTrue, or, toggleOnFalse, toggleOnTrue, toggleWhenActive, whenActive, whenActive, whenInactive, whenInactive, whileActiveContinuous, whileActiveContinuous, whileActiveOnce, whileFalse, whileTrue
-
Constructor Details
-
NetworkButton
Creates a NetworkButton that commands can be bound to.- Parameters:
topic
- The boolean topic that contains the value.
-
NetworkButton
Creates a NetworkButton that commands can be bound to.- Parameters:
sub
- The boolean subscriber that provides the value.
-
NetworkButton
Creates a NetworkButton that commands can be bound to.- Parameters:
table
- The table where the networktable value is located.field
- The field that is the value.
-
NetworkButton
Creates a NetworkButton that commands can be bound to.- Parameters:
table
- The table where the networktable value is located.field
- The field that is the value.
-
NetworkButton
Creates a NetworkButton that commands can be bound to.- Parameters:
inst
- The NetworkTable instance to usetable
- The table where the networktable value is located.field
- The field that is the value.
-