Package lib.custom

Class NamedSendableChooser<T extends Nameable>

java.lang.Object
edu.wpi.first.wpilibj.smartdashboard.SendableChooser<T>
lib.custom.NamedSendableChooser<T>
All Implemented Interfaces:
edu.wpi.first.util.sendable.Sendable, AutoCloseable, Supplier<T>

public class NamedSendableChooser<T extends Nameable> extends edu.wpi.first.wpilibj.smartdashboard.SendableChooser<T> implements Supplier<T>
A sendable chooser for any named object.
  • Constructor Summary

    Constructors
    Constructor
    Description
     
  • Method Summary

    Modifier and Type
    Method
    Description
    void
    addOption(T object)
    Adds an object of the type to the smart dashboard.
    get()
    Wrapper for getSelected() to conform to Supplier
    void
    Adds an object of the type to the smart dashboard as the default object.

    Methods inherited from class edu.wpi.first.wpilibj.smartdashboard.SendableChooser

    addOption, close, getSelected, initSendable, onChange, setDefaultOption

    Methods inherited from class java.lang.Object

    clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
  • Constructor Details

    • NamedSendableChooser

      public NamedSendableChooser()
  • Method Details

    • addOption

      public void addOption(T object)
      Adds an object of the type to the smart dashboard.
    • setDefaultOption

      public void setDefaultOption(T object)
      Adds an object of the type to the smart dashboard as the default object.
    • get

      public T get()
      Wrapper for getSelected() to conform to Supplier
      Specified by:
      get in interface Supplier<T extends Nameable>