Interface DoublePublisher

All Superinterfaces:
AutoCloseable, DoubleConsumer, Publisher, PubSub
All Known Subinterfaces:
DoubleEntry

public interface DoublePublisher
extends Publisher, DoubleConsumer
NetworkTables Double publisher.
  • Method Summary

    Modifier and Type Method Description
    default void accept​(double value)  
    DoubleTopic getTopic()
    Get the corresponding topic.
    default void set​(double value)
    Publish a new value using current NT time.
    void set​(double value, long time)
    Publish a new value.
    void setDefault​(double value)
    Publish a default value.

    Methods inherited from interface java.util.function.DoubleConsumer

    andThen

    Methods inherited from interface edu.wpi.first.networktables.PubSub

    close, getHandle, isValid
  • Method Details

    • getTopic

      Get the corresponding topic.
      Specified by:
      getTopic in interface PubSub
      Returns:
      Topic
    • set

      default void set​(double value)
      Publish a new value using current NT time.
      Parameters:
      value - value to publish
    • set

      void set​(double value, long time)
      Publish a new value.
      Parameters:
      value - value to publish
      time - timestamp; 0 indicates current NT time should be used
    • setDefault

      void setDefault​(double value)
      Publish a default value. On reconnect, a default value will never be used in preference to a published value.
      Parameters:
      value - value
    • accept

      default void accept​(double value)
      Specified by:
      accept in interface DoubleConsumer