Class ToggleableStringSubscriber

java.lang.Object
dev.doglog.internal.tunable.entry.ToggleableStringSubscriber
All Implemented Interfaces:
AutoCloseable, Supplier<String>, org.wpilib.networktables.PubSub, org.wpilib.networktables.StringSubscriber, org.wpilib.networktables.Subscriber

@NullMarked public class ToggleableStringSubscriber extends Object implements org.wpilib.networktables.StringSubscriber
  • Constructor Details

    • ToggleableStringSubscriber

      public ToggleableStringSubscriber(org.wpilib.networktables.StringSubscriber subscriber, String defaultValue, BooleanSupplier useNt)
  • Method Details

    • close

      public void close()
      Specified by:
      close in interface AutoCloseable
      Specified by:
      close in interface org.wpilib.networktables.PubSub
    • exists

      public boolean exists()
      Specified by:
      exists in interface org.wpilib.networktables.Subscriber
    • get

      public String get()
      Specified by:
      get in interface org.wpilib.networktables.StringSubscriber
      Specified by:
      get in interface Supplier<String>
    • get

      public String get(String defaultValue)
      Specified by:
      get in interface org.wpilib.networktables.StringSubscriber
    • getAtomic

      public org.wpilib.networktables.TimestampedString getAtomic()
      Specified by:
      getAtomic in interface org.wpilib.networktables.StringSubscriber
    • getAtomic

      public org.wpilib.networktables.TimestampedString getAtomic(String defaultValue)
      Specified by:
      getAtomic in interface org.wpilib.networktables.StringSubscriber
    • getHandle

      public int getHandle()
      Specified by:
      getHandle in interface org.wpilib.networktables.PubSub
    • getLastChange

      public long getLastChange()
      Specified by:
      getLastChange in interface org.wpilib.networktables.Subscriber
    • getTopic

      public org.wpilib.networktables.StringTopic getTopic()
      Specified by:
      getTopic in interface org.wpilib.networktables.PubSub
      Specified by:
      getTopic in interface org.wpilib.networktables.StringSubscriber
    • isValid

      public boolean isValid()
      Specified by:
      isValid in interface org.wpilib.networktables.PubSub
    • readQueue

      public org.wpilib.networktables.TimestampedString[] readQueue()
      Specified by:
      readQueue in interface org.wpilib.networktables.StringSubscriber
    • readQueueValues

      public String[] readQueueValues()
      Specified by:
      readQueueValues in interface org.wpilib.networktables.StringSubscriber