143 std::vector<TimestampedValueType>
ReadQueue();
NetworkTables publisher.
Definition: Topic.h:345
NetworkTables String entry.
Definition: StringTopic.h:211
void Unpublish()
Stops publishing the entry if it's published.
Definition: StringTopic.inc:86
TopicType GetTopic() const
Get the corresponding topic.
Definition: StringTopic.inc:82
StringTopic TopicType
Definition: StringTopic.h:215
NT_Entry GetHandle() const
Gets the native handle for the entry.
Definition: StringTopic.h:247
NetworkTables String publisher.
Definition: StringTopic.h:159
void SetDefault(ParamType value)
Publish a default value.
Definition: StringTopic.inc:69
std::string_view SmallRetType
Definition: StringTopic.h:165
StringPublisher()=default
std::string_view ParamType
Definition: StringTopic.h:163
TopicType GetTopic() const
Get the corresponding topic.
Definition: StringTopic.inc:73
std::string ValueType
Definition: StringTopic.h:162
void Set(ParamType value, int64_t time=0)
Publish a new value.
Definition: StringTopic.inc:64
char SmallElemType
Definition: StringTopic.h:166
NetworkTables String subscriber.
Definition: StringTopic.h:31
StringSubscriber()=default
char SmallElemType
Definition: StringTopic.h:39
ValueType Get() const
Get the last published value.
Definition: StringTopic.inc:18
TopicType GetTopic() const
Get the corresponding topic.
Definition: StringTopic.inc:57
std::string_view ParamType
Definition: StringTopic.h:35
std::string ValueType
Definition: StringTopic.h:34
TimestampedValueType GetAtomic() const
Get the last published value along with its timestamp If no value has been published,...
Definition: StringTopic.inc:35
std::vector< TimestampedValueType > ReadQueue()
Get an array of all value changes since the last call to ReadQueue.
Definition: StringTopic.inc:53
std::string_view SmallRetType
Definition: StringTopic.h:38
NetworkTables String topic.
Definition: StringTopic.h:265
StringTopic(Topic topic)
Construct from a generic topic.
Definition: StringTopic.h:291
SubscriberType SubscribeEx(std::string_view typeString, ParamType defaultValue, const PubSubOptions &options=kDefaultPubSubOptions)
Create a new subscriber to the topic, with specific type string.
Definition: StringTopic.inc:97
PublisherType Publish(const PubSubOptions &options=kDefaultPubSubOptions)
Create a new publisher to the topic.
Definition: StringTopic.inc:105
EntryType GetEntry(ParamType defaultValue, const PubSubOptions &options=kDefaultPubSubOptions)
Create a new entry for the topic.
Definition: StringTopic.inc:118
StringTopic(NT_Topic handle)
Construct from a topic handle; recommended to use NetworkTableInstance::GetStringTopic() instead.
Definition: StringTopic.h:284
static constexpr std::string_view kTypeString
The default type string for this topic type.
Definition: StringTopic.h:274
EntryType GetEntryEx(std::string_view typeString, ParamType defaultValue, const PubSubOptions &options=kDefaultPubSubOptions)
Create a new entry for the topic, with specific type string.
Definition: StringTopic.inc:125
StringPublisher PublisherType
Definition: StringTopic.h:268
SubscriberType Subscribe(ParamType defaultValue, const PubSubOptions &options=kDefaultPubSubOptions)
Create a new subscriber to the topic.
Definition: StringTopic.inc:90
std::string_view ParamType
Definition: StringTopic.h:271
StringSubscriber SubscriberType
Definition: StringTopic.h:267
StringEntry EntryType
Definition: StringTopic.h:269
std::string ValueType
Definition: StringTopic.h:270
PublisherType PublishEx(std::string_view typeString, const wpi::json &properties, const PubSubOptions &options=kDefaultPubSubOptions)
Create a new publisher to the topic, with type string and initial properties.
Definition: StringTopic.inc:111
NetworkTables subscriber.
Definition: Topic.h:290
NT_Subscriber m_subHandle
Definition: Topic.h:341
NetworkTables Topic.
Definition: Topic.h:30
This class consists of common code factored out of the SmallVector class to reduce code duplication b...
Definition: SmallVector.h:557
a class to store JSON values
Definition: json.h:2655
basic_string_view< char > string_view
Definition: core.h:520
NT_Handle NT_Topic
Definition: ntcore_c.h:38
NT_Handle NT_Subscriber
Definition: ntcore_c.h:39
NT_Handle NT_Publisher
Definition: ntcore_c.h:40
NT_Handle NT_Entry
Definition: ntcore_c.h:33
constexpr PubSubOptions kDefaultPubSubOptions
Default publish/subscribe options.
Definition: ntcore_cpp.h:381
::int64_t int64_t
Definition: Meta.h:59
NetworkTables (ntcore) namespace.
Definition: ntcore_cpp.h:35
/file This file defines the SmallVector class.
Definition: AprilTagFieldLayout.h:18
NetworkTables publish/subscribe options.
Definition: ntcore_cpp.h:304
Timestamped String.
Definition: ntcore_cpp_types.h:420
Timestamped String view (for SmallVector-taking functions).
Definition: ntcore_cpp_types.h:445