Package com.pocolifo.robobase.control
Class Pressable
- java.lang.Object
-
- com.pocolifo.robobase.control.Pressable
-
public class Pressable extends java.lang.Object
-
-
Constructor Summary
Constructors Constructor Description Pressable(BoolSupplier currentState)
Creates aPressable
.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description boolean
get()
Get the current toggled state.
-
-
-
Constructor Detail
-
Pressable
public Pressable(BoolSupplier currentState)
Creates aPressable
.- Parameters:
currentState
- A method to get the current state of something (like whether a gamepad button is pressed)
-
-
Method Detail
-
get
public boolean get()
Get the current toggled state.- Returns:
- The toggled state of this
Toggleable
-
-